summary refs log tree commit diff
path: root/tests
diff options
context:
space:
mode:
authorMark Haines <mark.haines@matrix.org>2015-10-12 16:54:58 +0100
committerMark Haines <mark.haines@matrix.org>2015-10-12 16:54:58 +0100
commit586beb8318bd259581918a8b47f5981f0b90b7e9 (patch)
tree63243401ccb90702d886180da92165b9ad146b86 /tests
parentMerge branch 'markjh/presence_races' into markjh/v2_sync_api (diff)
downloadsynapse-586beb8318bd259581918a8b47f5981f0b90b7e9.tar.xz
Update the filters to match the latest spec.
Apply the filter the 'timeline' and 'ephemeral' keys of rooms.
Apply the filter to the 'presence' key of a sync response.
Diffstat (limited to 'tests')
-rw-r--r--tests/api/test_filtering.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/tests/api/test_filtering.py b/tests/api/test_filtering.py
index 65b2f590c8..6942cdac51 100644
--- a/tests/api/test_filtering.py
+++ b/tests/api/test_filtering.py
@@ -345,9 +345,9 @@ class FilteringTestCase(unittest.TestCase):
         )
 
     @defer.inlineCallbacks
-    def test_filter_public_user_data_match(self):
+    def test_filter_presence_match(self):
         user_filter_json = {
-            "public_user_data": {
+            "presence": {
                 "types": ["m.*"]
             }
         }
@@ -368,13 +368,13 @@ class FilteringTestCase(unittest.TestCase):
             filter_id=filter_id,
         )
 
-        results = user_filter.filter_public_user_data(events=events)
+        results = user_filter.filter_presence(events=events)
         self.assertEquals(events, results)
 
     @defer.inlineCallbacks
-    def test_filter_public_user_data_no_match(self):
+    def test_filter_presence_no_match(self):
         user_filter_json = {
-            "public_user_data": {
+            "presence": {
                 "types": ["m.*"]
             }
         }
@@ -395,7 +395,7 @@ class FilteringTestCase(unittest.TestCase):
             filter_id=filter_id,
         )
 
-        results = user_filter.filter_public_user_data(events=events)
+        results = user_filter.filter_presence(events=events)
         self.assertEquals([], results)
 
     @defer.inlineCallbacks