Method: PresenceTest#test_error

Defined in:
lib/vendor/xmpp4r/test/tc_presence.rb

#test_errorObject



101
102
103
104
105
106
107
108
109
# File 'lib/vendor/xmpp4r/test/tc_presence.rb', line 101

def test_error
  x = Presence.new()
  e = REXML::Element.new('error')
  x.add(e)
  x2 = Presence.new.import(x)
  # test if, after an import, the error element is successfully changed
  # into an ErrorResponse object.
  assert_equal(ErrorResponse, x2.first_element('error').class)
end