Mercurial > libervia-backend
comparison src/plugins/plugin_misc_room_game.py @ 857:3c270d691e56
test: fix the tests for plugin room game
author | souliane <souliane@mailoo.org> |
---|---|
date | Thu, 20 Feb 2014 17:51:51 +0100 |
parents | c5a8f602662b |
children | 386ab96af575 |
comparison
equal
deleted
inserted
replaced
856:7ea7053dda88 | 857:3c270d691e56 |
---|---|
302 players_jids = [JID(player) for player in other_players] | 302 players_jids = [JID(player) for player in other_players] |
303 self.invitations[room_jid_s].append((time(), [player.userhost() for player in players_jids])) | 303 self.invitations[room_jid_s].append((time(), [player.userhost() for player in players_jids])) |
304 nicks = [] | 304 nicks = [] |
305 for player_jid in [player.userhostJID() for player in players_jids]: | 305 for player_jid in [player.userhostJID() for player in players_jids]: |
306 # TODO: find a way to make it secure | 306 # TODO: find a way to make it secure |
307 other_nick = self.host.plugins["XEP-0045"].getRoomNickOfUser(room, player_jid, secure=False) | 307 other_nick = self.host.plugins["XEP-0045"].getRoomNickOfUser(room, player_jid, secure=self.testing) |
308 if other_nick is None: | 308 if other_nick is None: |
309 self.host.plugins["XEP-0249"].invite(player_jid, room_jid, {"game": self.name}, profile) | 309 self.host.plugins["XEP-0249"].invite(player_jid, room_jid, {"game": self.name}, profile) |
310 else: | 310 else: |
311 nicks.append(other_nick) | 311 nicks.append(other_nick) |
312 return nicks | 312 return nicks |