summary refs log tree commit diff
path: root/tests/test_server.py
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--tests/test_server.py14
1 files changed, 7 insertions, 7 deletions
diff --git a/tests/test_server.py b/tests/test_server.py
index 08fb3fe02f..da29ae92ce 100644
--- a/tests/test_server.py
+++ b/tests/test_server.py
@@ -69,8 +69,8 @@ class JsonResourceTests(unittest.TestCase):
         )
         render(request, res, self.reactor)
 
-        self.assertEqual(request.args, {b'a': [u"\N{SNOWMAN}".encode('utf8')]})
-        self.assertEqual(got_kwargs, {u"room_id": u"\N{SNOWMAN}"})
+        self.assertEqual(request.args, {b"a": ["\N{SNOWMAN}".encode("utf8")]})
+        self.assertEqual(got_kwargs, {"room_id": "\N{SNOWMAN}"})
 
     def test_callback_direct_exception(self):
         """
@@ -87,7 +87,7 @@ class JsonResourceTests(unittest.TestCase):
         request, channel = make_request(self.reactor, b"GET", b"/_matrix/foo")
         render(request, res, self.reactor)
 
-        self.assertEqual(channel.result["code"], b'500')
+        self.assertEqual(channel.result["code"], b"500")
 
     def test_callback_indirect_exception(self):
         """
@@ -110,7 +110,7 @@ class JsonResourceTests(unittest.TestCase):
         request, channel = make_request(self.reactor, b"GET", b"/_matrix/foo")
         render(request, res, self.reactor)
 
-        self.assertEqual(channel.result["code"], b'500')
+        self.assertEqual(channel.result["code"], b"500")
 
     def test_callback_synapseerror(self):
         """
@@ -127,7 +127,7 @@ class JsonResourceTests(unittest.TestCase):
         request, channel = make_request(self.reactor, b"GET", b"/_matrix/foo")
         render(request, res, self.reactor)
 
-        self.assertEqual(channel.result["code"], b'403')
+        self.assertEqual(channel.result["code"], b"403")
         self.assertEqual(channel.json_body["error"], "Forbidden!!one!")
         self.assertEqual(channel.json_body["errcode"], "M_FORBIDDEN")
 
@@ -148,7 +148,7 @@ class JsonResourceTests(unittest.TestCase):
         request, channel = make_request(self.reactor, b"GET", b"/_matrix/foobar")
         render(request, res, self.reactor)
 
-        self.assertEqual(channel.result["code"], b'400')
+        self.assertEqual(channel.result["code"], b"400")
         self.assertEqual(channel.json_body["error"], "Unrecognized request")
         self.assertEqual(channel.json_body["errcode"], "M_UNRECOGNIZED")
 
@@ -180,7 +180,7 @@ class SiteTestCase(unittest.HomeserverTestCase):
         # Make a resource and a Site, the resource will hang and allow us to
         # time out the request while it's 'processing'
         base_resource = Resource()
-        base_resource.putChild(b'', HangingResource())
+        base_resource.putChild(b"", HangingResource())
         site = SynapseSite("test", "site_tag", {}, base_resource, "1.0")
 
         server = site.buildProtocol(None)