summary refs log tree commit diff
path: root/tests/rest/test_presence.py
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2014-09-29 15:35:57 +0100
committerErik Johnston <erik@matrix.org>2014-09-29 15:35:57 +0100
commitd96cb61f26fa5ed3f0aab9b4c461e9656d986194 (patch)
tree279d3b8efd4c9ec32d55703cee8b659f4792fa10 /tests/rest/test_presence.py
parentUpdate docstring (diff)
downloadsynapse-d96cb61f26fa5ed3f0aab9b4c461e9656d986194.tar.xz
Unbreak tests after changing storage API
Diffstat (limited to 'tests/rest/test_presence.py')
-rw-r--r--tests/rest/test_presence.py12
1 files changed, 10 insertions, 2 deletions
diff --git a/tests/rest/test_presence.py b/tests/rest/test_presence.py
index 1b3e6759c2..e2dc3dec81 100644
--- a/tests/rest/test_presence.py
+++ b/tests/rest/test_presence.py
@@ -67,7 +67,11 @@ class PresenceStateTestCase(unittest.TestCase):
         self.datastore.get_presence_list = get_presence_list
 
         def _get_user_by_token(token=None):
-            return hs.parse_userid(myid)
+            return {
+                "user": hs.parse_userid(myid),
+                "admin": False,
+                "device_id": None,
+            }
 
         hs.get_auth().get_user_by_token = _get_user_by_token
 
@@ -151,7 +155,11 @@ class PresenceListTestCase(unittest.TestCase):
         self.datastore.has_presence_state = has_presence_state
 
         def _get_user_by_token(token=None):
-            return hs.parse_userid(myid)
+            return {
+                "user": hs.parse_userid(myid),
+                "admin": False,
+                "device_id": None,
+            }
 
         room_member_handler = hs.handlers.room_member_handler = Mock(
             spec=[