Ignore:
Timestamp:
Aug 21, 2009, 2:46:18 PM (13 years ago)
Author:
Ralph Meijer <ralphm@…>
Branch:
wokkel-muc-client-support-24
Message:

More renames.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • wokkel/test/test_muc.py

    r131 r132  
    8888
    8989        def userPresence(room, user):
    90             self.failUnless(room.roomIdentifier==self.test_room, 'Wrong room name')
    91             self.failUnless(room.inRoster(user), 'User not in roster')
     90            self.assertEqual(self.test_room, room.roomIdentifier,
     91                             'Wrong room name')
     92            self.assertTrue(room.inRoster(user), 'User not in roster')
    9293
    9394
     
    122123
    123124        def cb(room):
    124             self.assertEquals(self.test_room, room.roomIdentifier)
     125            self.assertEqual(self.test_room, room.roomIdentifier)
    125126
    126127        d = self.protocol.join(self.test_srv, self.test_room, self.test_nick)
     
    468469
    469470        def cb(room):
    470             self.assertEquals(self.test_room, room.roomIdentifier)
    471             self.assertEquals(test_nick, room.nick)
     471            self.assertEqual(self.test_room, room.roomIdentifier)
     472            self.assertEqual(test_nick, room.nick)
    472473
    473474        d = self.protocol.nick(self.room_jid, test_nick)
     
    519520
    520521        def cb(room):
    521             self.assertEquals(self.test_room, room.roomIdentifier)
     522            self.assertEqual(self.test_room, room.roomIdentifier)
    522523            user = room.getUser(self.room_jid.resource)
    523             self.failUnless(user is not None, 'User not found')
    524             self.failUnless(user.status == 'testing MUC', 'Wrong status')
    525             self.failUnless(user.show == 'xa', 'Wrong show')
     524            self.assertNotIdentical(None, user, 'User not found')
     525            self.assertEqual('testing MUC', user.status, 'Wrong status')
     526            self.assertEqual('xa', user.show, 'Wrong show')
    526527
    527528        d = self.protocol.status(self.room_jid, 'xa', 'testing MUC')
     
    530531        prs = self.stub.output[-1]
    531532
    532         self.failUnless(prs.name=='presence', "Need to be presence")
    533         self.failUnless(getattr(prs, 'x', None), 'No muc x element')
     533        self.assertEqual('presence', prs.name, "Need to be presence")
     534        self.assertTrue(getattr(prs, 'x', None), 'No muc x element')
    534535
    535536        # send back user presence, they joined
     
    546547            self.assertEqual(1, len(members))
    547548            user = members[0]
    548             self.assertEquals(JID(u'hag66@shakespeare.lit'), user.entity)
    549             self.assertEquals(u'thirdwitch', user.nick)
    550             self.assertEquals(u'participant', user.role)
     549            self.assertEqual(JID(u'hag66@shakespeare.lit'), user.entity)
     550            self.assertEqual(u'thirdwitch', user.nick)
     551            self.assertEqual(u'participant', user.role)
    551552
    552553        self._createRoom()
     
    558559        query = iq.query
    559560        self.assertNotIdentical(None, query)
    560         self.assertEquals(NS_MUC_ADMIN, query.uri)
     561        self.assertEqual(NS_MUC_ADMIN, query.uri)
    561562
    562563        response = toResponse(iq, 'result')
Note: See TracChangeset for help on using the changeset viewer.