diff options
author | Patrick Cloke <clokep@users.noreply.github.com> | 2022-10-20 11:32:47 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-10-20 11:32:47 -0400 |
commit | 755bfeee3a1ac7077045ab9e5a994b6ca89afba3 (patch) | |
tree | 470b311d29d49a5b3910a9fa06f81c033f6abe71 /tests | |
parent | Stop returning `unsigned.invite_room_state` in `PUT /_matrix/federation/v2/in... (diff) | |
download | synapse-755bfeee3a1ac7077045ab9e5a994b6ca89afba3.tar.xz |
Use servlets for /key/ endpoints. (#14229)
To fix the response for unknown endpoints under that prefix. See MSC3743.
Diffstat (limited to 'tests')
-rw-r--r-- | tests/app/test_openid_listener.py | 2 | ||||
-rw-r--r-- | tests/rest/key/v2/test_remote_key_resource.py | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/tests/app/test_openid_listener.py b/tests/app/test_openid_listener.py index c7dae58eb5..8d03da7f96 100644 --- a/tests/app/test_openid_listener.py +++ b/tests/app/test_openid_listener.py @@ -79,7 +79,7 @@ class FederationReaderOpenIDListenerTests(HomeserverTestCase): self.assertEqual(channel.code, 401) -@patch("synapse.app.homeserver.KeyApiV2Resource", new=Mock()) +@patch("synapse.app.homeserver.KeyResource", new=Mock()) class SynapseHomeserverOpenIDListenerTests(HomeserverTestCase): def make_homeserver(self, reactor, clock): hs = self.setup_test_homeserver( diff --git a/tests/rest/key/v2/test_remote_key_resource.py b/tests/rest/key/v2/test_remote_key_resource.py index ac0ac06b7e..7f1fba1086 100644 --- a/tests/rest/key/v2/test_remote_key_resource.py +++ b/tests/rest/key/v2/test_remote_key_resource.py @@ -26,7 +26,7 @@ from twisted.web.resource import NoResource, Resource from synapse.crypto.keyring import PerspectivesKeyFetcher from synapse.http.site import SynapseRequest -from synapse.rest.key.v2 import KeyApiV2Resource +from synapse.rest.key.v2 import KeyResource from synapse.server import HomeServer from synapse.storage.keys import FetchKeyResult from synapse.types import JsonDict @@ -46,7 +46,7 @@ class BaseRemoteKeyResourceTestCase(unittest.HomeserverTestCase): def create_test_resource(self) -> Resource: return create_resource_tree( - {"/_matrix/key/v2": KeyApiV2Resource(self.hs)}, root_resource=NoResource() + {"/_matrix/key/v2": KeyResource(self.hs)}, root_resource=NoResource() ) def expect_outgoing_key_request( |