summary refs log tree commit diff
path: root/tests/test_federation.py
diff options
context:
space:
mode:
authorPatrick Cloke <clokep@users.noreply.github.com>2021-04-14 12:32:20 -0400
committerGitHub <noreply@github.com>2021-04-14 12:32:20 -0400
commitcc51aaaa7adb0ec2235e027b5184ebda9b660ec4 (patch)
tree39fe178b6fb07577d7ec84744f6155ccbf05a37e /tests/test_federation.py
parentExperimental Federation Speedup (#9702) (diff)
downloadsynapse-cc51aaaa7adb0ec2235e027b5184ebda9b660ec4.tar.xz
Check for space membership during a remote join of a restricted room. (#9763)
When receiving a /send_join request for a room with join rules set to 'restricted',
check if the user is a member of the spaces defined in the 'allow' key of the join
rules.
    
This only applies to an experimental room version, as defined in MSC3083.
Diffstat (limited to 'tests/test_federation.py')
-rw-r--r--tests/test_federation.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/tests/test_federation.py b/tests/test_federation.py
index 86a44a13da..0a3a996ec1 100644
--- a/tests/test_federation.py
+++ b/tests/test_federation.py
@@ -75,8 +75,10 @@ class MessageAcceptTests(unittest.HomeserverTestCase):
         )
 
         self.handler = self.homeserver.get_federation_handler()
-        self.handler.do_auth = lambda origin, event, context, auth_events: succeed(
-            context
+        self.handler._check_event_auth = (
+            lambda origin, event, context, state, auth_events, backfilled: succeed(
+                context
+            )
         )
         self.client = self.homeserver.get_federation_client()
         self.client._check_sigs_and_hash_and_fetch = lambda dest, pdus, **k: succeed(