Fix test. get_joined_hosts_for_room get's called multiple times
This commit is contained in:
parent
5c4c591c61
commit
d100ac8c82
|
@ -140,9 +140,11 @@ class RoomMemberHandlerTestCase(unittest.TestCase):
|
||||||
joined = ["red", "green"]
|
joined = ["red", "green"]
|
||||||
|
|
||||||
self.state_handler.handle_new_event.return_value = defer.succeed(True)
|
self.state_handler.handle_new_event.return_value = defer.succeed(True)
|
||||||
self.datastore.get_joined_hosts_for_room.return_value = (
|
|
||||||
defer.succeed(joined)
|
def get_joined(*args):
|
||||||
)
|
return defer.succeed(joined)
|
||||||
|
|
||||||
|
self.datastore.get_joined_hosts_for_room.side_effect = get_joined
|
||||||
|
|
||||||
store_id = "store_id_fooo"
|
store_id = "store_id_fooo"
|
||||||
self.datastore.persist_event.return_value = defer.succeed(store_id)
|
self.datastore.persist_event.return_value = defer.succeed(store_id)
|
||||||
|
|
Loading…
Reference in New Issue