summary refs log tree commit diff
path: root/tests/app/test_frontend_proxy.py
diff options
context:
space:
mode:
authorRichard van der Hoff <richard@matrix.org>2020-11-15 22:49:21 +0000
committerRichard van der Hoff <richard@matrix.org>2020-11-16 18:24:08 +0000
commitbe8fa65d0baddcc0a64954e21d38a854e4ee00d7 (patch)
treeaada7d9ac2dac6555cf0cc4513b605d0edab5d5d /tests/app/test_frontend_proxy.py
parentMake `make_request` actually render the request (diff)
downloadsynapse-be8fa65d0baddcc0a64954e21d38a854e4ee00d7.tar.xz
Remove redundant calls to `render()`
Diffstat (limited to 'tests/app/test_frontend_proxy.py')
-rw-r--r--tests/app/test_frontend_proxy.py10
1 files changed, 3 insertions, 7 deletions
diff --git a/tests/app/test_frontend_proxy.py b/tests/app/test_frontend_proxy.py

index 0bac7995e8..40abe9d72d 100644 --- a/tests/app/test_frontend_proxy.py +++ b/tests/app/test_frontend_proxy.py
@@ -15,7 +15,7 @@ from synapse.app.generic_worker import GenericWorkerServer -from tests.server import make_request, render +from tests.server import make_request from tests.unittest import HomeserverTestCase @@ -56,10 +56,8 @@ class FrontendProxyTests(HomeserverTestCase): # Grab the resource from the site that was told to listen self.assertEqual(len(self.reactor.tcpServers), 1) site = self.reactor.tcpServers[0][1] - resource = site.resource.children[b"_matrix"].children[b"client"] - request, channel = make_request(self.reactor, site, "PUT", "presence/a/status") - render(request, resource, self.reactor) + _, channel = make_request(self.reactor, site, "PUT", "presence/a/status") # 400 + unrecognised, because nothing is registered self.assertEqual(channel.code, 400) @@ -78,10 +76,8 @@ class FrontendProxyTests(HomeserverTestCase): # Grab the resource from the site that was told to listen self.assertEqual(len(self.reactor.tcpServers), 1) site = self.reactor.tcpServers[0][1] - resource = site.resource.children[b"_matrix"].children[b"client"] - request, channel = make_request(self.reactor, site, "PUT", "presence/a/status") - render(request, resource, self.reactor) + _, channel = make_request(self.reactor, site, "PUT", "presence/a/status") # 401, because the stub servlet still checks authentication self.assertEqual(channel.code, 401)