summary refs log tree commit diff
path: root/tests/rest/client/v1/utils.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/rest/client/v1/utils.py')
-rw-r--r--tests/rest/client/v1/utils.py16
1 files changed, 5 insertions, 11 deletions
diff --git a/tests/rest/client/v1/utils.py b/tests/rest/client/v1/utils.py
index 040a92d6f0..b58768675b 100644
--- a/tests/rest/client/v1/utils.py
+++ b/tests/rest/client/v1/utils.py
@@ -27,7 +27,7 @@ from twisted.web.server import Site
 
 from synapse.api.constants import Membership
 
-from tests.server import FakeSite, make_request, render
+from tests.server import FakeSite, make_request
 
 
 @attr.s
@@ -52,14 +52,13 @@ class RestHelper:
         if tok:
             path = path + "?access_token=%s" % tok
 
-        request, channel = make_request(
+        _, channel = make_request(
             self.hs.get_reactor(),
             self.site,
             "POST",
             path,
             json.dumps(content).encode("utf8"),
         )
-        render(request, self.site.resource, self.hs.get_reactor())
 
         assert channel.result["code"] == b"%d" % expect_code, channel.result
         self.auth_user_id = temp_id
@@ -129,7 +128,7 @@ class RestHelper:
         data = {"membership": membership}
         data.update(extra_data)
 
-        request, channel = make_request(
+        _, channel = make_request(
             self.hs.get_reactor(),
             self.site,
             "PUT",
@@ -137,8 +136,6 @@ class RestHelper:
             json.dumps(data).encode("utf8"),
         )
 
-        render(request, self.site.resource, self.hs.get_reactor())
-
         assert int(channel.result["code"]) == expect_code, (
             "Expected: %d, got: %d, resp: %r"
             % (expect_code, int(channel.result["code"]), channel.result["body"])
@@ -166,14 +163,13 @@ class RestHelper:
         if tok:
             path = path + "?access_token=%s" % tok
 
-        request, channel = make_request(
+        _, channel = make_request(
             self.hs.get_reactor(),
             self.site,
             "PUT",
             path,
             json.dumps(content).encode("utf8"),
         )
-        render(request, self.site.resource, self.hs.get_reactor())
 
         assert int(channel.result["code"]) == expect_code, (
             "Expected: %d, got: %d, resp: %r"
@@ -223,12 +219,10 @@ class RestHelper:
         if body is not None:
             content = json.dumps(body).encode("utf8")
 
-        request, channel = make_request(
+        _, channel = make_request(
             self.hs.get_reactor(), self.site, method, path, content
         )
 
-        render(request, self.site.resource, self.hs.get_reactor())
-
         assert int(channel.result["code"]) == expect_code, (
             "Expected: %d, got: %d, resp: %r"
             % (expect_code, int(channel.result["code"]), channel.result["body"])