summary refs log tree commit diff
path: root/tests/rest/client/v1
diff options
context:
space:
mode:
authorRichard van der Hoff <1389908+richvdh@users.noreply.github.com>2020-11-16 15:22:40 +0000
committerGitHub <noreply@github.com>2020-11-16 15:22:40 +0000
commitbebfb9a97b4e6a5cc840dc6906e4aaebd5d7d30d (patch)
tree307ea9eba33d0301b39b79e0e0f9c2913b1418b0 /tests/rest/client/v1
parentchangelog (diff)
parentRename `create_test_json_resource` to `create_test_resource` (#8759) (diff)
downloadsynapse-bebfb9a97b4e6a5cc840dc6906e4aaebd5d7d30d.tar.xz
Merge branch 'develop' into rav/pass_site_to_make_request
Diffstat (limited to 'tests/rest/client/v1')
-rw-r--r--tests/rest/client/v1/utils.py4
1 files changed, 1 insertions, 3 deletions
diff --git a/tests/rest/client/v1/utils.py b/tests/rest/client/v1/utils.py
index 60e4b9b846..900852f85b 100644
--- a/tests/rest/client/v1/utils.py
+++ b/tests/rest/client/v1/utils.py
@@ -317,9 +317,7 @@ class RestHelper:
             path,
             content=image_data,
             access_token=tok,
-        )
-        request.requestHeaders.addRawHeader(
-            b"Content-Length", str(image_length).encode("UTF-8")
+            custom_headers=[(b"Content-Length", str(image_length))],
         )
         request.render(resource)
         self.hs.get_reactor().pump([100])