diff options
author | David Baker <dbkr@matrix.org> | 2014-12-02 13:50:05 +0000 |
---|---|---|
committer | David Baker <dbkr@matrix.org> | 2014-12-02 13:50:05 +0000 |
commit | 7642d95d5e90bab130b33dc27f10e347072e0294 (patch) | |
tree | 08c618bc5daeceb90bb8a47e3800b88c12d83427 /tests/handlers/test_room.py | |
parent | More work on pushers. Attempt to do HTTP pokes. Not sure if the actual HTTP p... (diff) | |
parent | Add non-working jitsi meet bridge (diff) | |
download | synapse-7642d95d5e90bab130b33dc27f10e347072e0294.tar.xz |
Merge branch 'develop' into pushers
Diffstat (limited to 'tests/handlers/test_room.py')
-rw-r--r-- | tests/handlers/test_room.py | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/tests/handlers/test_room.py b/tests/handlers/test_room.py index cbe591ab90..0279ab703a 100644 --- a/tests/handlers/test_room.py +++ b/tests/handlers/test_room.py @@ -120,7 +120,7 @@ class RoomMemberHandlerTestCase(unittest.TestCase): self.datastore.get_room_member.return_value = defer.succeed(None) - event.state_events = { + event.old_state_events = { (RoomMemberEvent.TYPE, "@alice:green"): self._create_member( user_id="@alice:green", room_id=room_id, @@ -129,9 +129,11 @@ class RoomMemberHandlerTestCase(unittest.TestCase): user_id="@bob:red", room_id=room_id, ), - (RoomMemberEvent.TYPE, target_user_id): event, } + event.state_events = event.old_state_events + event.state_events[(RoomMemberEvent.TYPE, target_user_id)] = event + # Actual invocation yield self.room_member_handler.change_membership(event) @@ -187,6 +189,16 @@ class RoomMemberHandlerTestCase(unittest.TestCase): (RoomMemberEvent.TYPE, user_id): event, } + event.old_state_events = { + (RoomMemberEvent.TYPE, "@alice:green"): self._create_member( + user_id="@alice:green", + room_id=room_id, + ), + } + + event.state_events = event.old_state_events + event.state_events[(RoomMemberEvent.TYPE, user_id)] = event + # Actual invocation yield self.room_member_handler.change_membership(event) |