summaryrefslogtreecommitdiff
path: root/sleekxmpp/test
diff options
context:
space:
mode:
authorLance Stout <lancestout@gmail.com>2011-05-20 17:42:40 -0400
committerLance Stout <lancestout@gmail.com>2011-05-20 17:42:40 -0400
commitc49a8e91142121251ccb2cacd3b3f0d5cd78db97 (patch)
treeeb48fa075fd45993e4ee97c303eb4a5c2710bd2f /sleekxmpp/test
parentd3bd9cd31d3cbf99d02539ecf4d3de20eafb8c8a (diff)
downloadslixmpp-c49a8e91142121251ccb2cacd3b3f0d5cd78db97.tar.gz
slixmpp-c49a8e91142121251ccb2cacd3b3f0d5cd78db97.tar.bz2
slixmpp-c49a8e91142121251ccb2cacd3b3f0d5cd78db97.tar.xz
slixmpp-c49a8e91142121251ccb2cacd3b3f0d5cd78db97.zip
Save progress
Diffstat (limited to 'sleekxmpp/test')
-rw-r--r--sleekxmpp/test/sleektest.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/sleekxmpp/test/sleektest.py b/sleekxmpp/test/sleektest.py
index e478e3a7..92f467fc 100644
--- a/sleekxmpp/test/sleektest.py
+++ b/sleekxmpp/test/sleektest.py
@@ -16,7 +16,8 @@ import sleekxmpp
from sleekxmpp import ClientXMPP, ComponentXMPP
from sleekxmpp.stanza import Message, Iq, Presence
from sleekxmpp.test import TestSocket, TestLiveSocket
-from sleekxmpp.xmlstream import StanzaBase, ET, register_stanza_plugin
+from sleekxmpp.xmlstream import ET, register_stanza_plugin
+from sleekxmpp.xmlstream import ElementBase, StanzaBase
from sleekxmpp.xmlstream.tostring import tostring
from sleekxmpp.xmlstream.matcher import StanzaPath, MatcherId
from sleekxmpp.xmlstream.matcher import MatchXMLMask, MatchXPath
@@ -227,7 +228,7 @@ class SleekTest(unittest.TestCase):
"Stanza:\n%s" % str(stanza))
else:
stanza_class = stanza.__class__
- if isinstance(criteria, str):
+ if not isinstance(criteria, ElementBase):
xml = self.parse_xml(criteria)
else:
xml = criteria.xml
@@ -632,7 +633,7 @@ class SleekTest(unittest.TestCase):
self.fail("Stanza data was sent: %s" % sent)
if sent is None:
self.fail("No stanza was sent.")
-
+
xml = self.parse_xml(sent)
self.fix_namespaces(xml, 'jabber:client')
sent = self.xmpp._build_stanza(xml, 'jabber:client')