fixing deprecation warnings for pytest

This commit is contained in:
Florian Klien
2018-10-08 23:25:23 +02:00
committed by Emmanuel Gil Peyrot
parent 809c500002
commit d33366badd
22 changed files with 131 additions and 132 deletions

View File

@@ -17,13 +17,13 @@ class TestAdHocCommandStanzas(SlixTest):
iq['command']['node'] = 'foo'
iq['command']['action'] = 'execute'
self.failUnless(iq['command']['action'] == 'execute')
self.assertTrue(iq['command']['action'] == 'execute')
iq['command']['action'] = 'complete'
self.failUnless(iq['command']['action'] == 'complete')
self.assertTrue(iq['command']['action'] == 'complete')
iq['command']['action'] = 'cancel'
self.failUnless(iq['command']['action'] == 'cancel')
self.assertTrue(iq['command']['action'] == 'cancel')
def testSetActions(self):
"""Test setting next actions in a command stanza."""
@@ -98,7 +98,7 @@ class TestAdHocCommandStanzas(SlixTest):
('error', "I can't let you do that")]
iq['command']['notes'] = notes
self.failUnless(iq['command']['notes'] == notes,
self.assertTrue(iq['command']['notes'] == notes,
"Notes don't match: %s %s" % (notes, iq['command']['notes']))
self.check(iq, """