Corrected test errors.

There was a bug in the XML compare method.
This commit is contained in:
Lance Stout
2010-10-07 19:42:28 -04:00
parent 42bfca1c87
commit e02ffe8547
6 changed files with 23 additions and 9 deletions

View File

@@ -30,11 +30,13 @@ class TestErrorStanzas(SleekTest):
self.failUnless(msg['error']['condition'] == 'item-not-found', "Error condition doesn't match.")
del msg['error']['condition']
msg['error']['condition'] = 'resource-constraint'
self.check_message(msg, """
<message type="error">
<error type="cancel" />
<error type="cancel">
<resource-constraint xmlns="urn:ietf:params:xml:ns:xmpp-stanzas" />
</error>
</message>
""")
@@ -52,6 +54,6 @@ class TestErrorStanzas(SleekTest):
<text xmlns="urn:ietf:params:xml:ns:xmpp-stanzas">Error!</text>
</error>
</message>
""")
""", use_values=False)
suite = unittest.TestLoader().loadTestsFromTestCase(TestErrorStanzas)