diff options
author | Lance Stout <lancestout@gmail.com> | 2010-08-05 20:23:07 -0400 |
---|---|---|
committer | Lance Stout <lancestout@gmail.com> | 2010-08-05 20:23:07 -0400 |
commit | 58f77d898f82ab108fa17d562a32c68d3ea35306 (patch) | |
tree | 441530e8518726fb55b2056340fa5ea03bec7638 /tests/test_iqstanzas.py | |
parent | c54466596f3dcc7a35a41c49fff0d057d4a8ed8f (diff) | |
download | slixmpp-58f77d898f82ab108fa17d562a32c68d3ea35306.tar.gz slixmpp-58f77d898f82ab108fa17d562a32c68d3ea35306.tar.bz2 slixmpp-58f77d898f82ab108fa17d562a32c68d3ea35306.tar.xz slixmpp-58f77d898f82ab108fa17d562a32c68d3ea35306.zip |
Updated tests to use a relative import for SleekTest to please Python3.
Fixed some tabs/spaces issues.
Diffstat (limited to 'tests/test_iqstanzas.py')
-rw-r--r-- | tests/test_iqstanzas.py | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/tests/test_iqstanzas.py b/tests/test_iqstanzas.py index 9ae59297..98a01a26 100644 --- a/tests/test_iqstanzas.py +++ b/tests/test_iqstanzas.py @@ -1,4 +1,4 @@ -from sleektest import * +from . sleektest import * from sleekxmpp.xmlstream.stanzabase import ET @@ -18,7 +18,7 @@ class TestIqStanzas(SleekTest): self.checkIq(iq, """ <iq id="0" /> """) - + def testPayload(self): """Test setting Iq stanza payload.""" iq = self.Iq() @@ -38,10 +38,10 @@ class TestIqStanzas(SleekTest): </iq> """) - iq = self.Iq() + iq = self.Iq() iq['id'] = 'test' - iq['error']['condition'] = 'feature-not-implemented' - iq['error']['text'] = 'No handlers registered for this request.' + iq['error']['condition'] = 'feature-not-implemented' + iq['error']['text'] = 'No handlers registered for this request.' self.streamSendIq(iq, """ <iq id="test" type="error"> @@ -72,21 +72,21 @@ class TestIqStanzas(SleekTest): </iq> """) - self.failUnless(iq['query'] == 'query_ns2', "Query namespace doesn't match") + self.failUnless(iq['query'] == 'query_ns2', "Query namespace doesn't match") - del iq['query'] - self.checkIq(iq, """ + del iq['query'] + self.checkIq(iq, """ <iq id="0" /> """) def testReply(self): """Test setting proper result type in Iq replies.""" iq = self.Iq() - iq['to'] = 'user@localhost' - iq['type'] = 'get' + iq['to'] = 'user@localhost' + iq['type'] = 'get' iq.reply() - self.checkIq(iq, """ + self.checkIq(iq, """ <iq id="0" type="result" /> """) |