mirror of
https://github.com/element-hq/synapse.git
synced 2024-12-19 01:21:09 +03:00
Slightly simplify some tests whilst reducing 'Any'-typing
This commit is contained in:
parent
98876d342f
commit
d216a956b6
1 changed files with 2 additions and 3 deletions
|
@ -392,8 +392,7 @@ class WrapHtmlRequestHandlerTests(unittest.TestCase):
|
|||
)
|
||||
|
||||
self.assertEqual(channel.code, 301)
|
||||
headers = channel.result["headers"]
|
||||
location_headers = headers.getRawHeaders(b"Location", [])
|
||||
location_headers = channel.headers.getRawHeaders(b"Location", [])
|
||||
self.assertEqual(location_headers, [b"/look/an/eagle"])
|
||||
|
||||
def test_redirect_exception_with_cookie(self) -> None:
|
||||
|
@ -415,7 +414,7 @@ class WrapHtmlRequestHandlerTests(unittest.TestCase):
|
|||
)
|
||||
|
||||
self.assertEqual(channel.code, 304)
|
||||
headers = channel.result["headers"]
|
||||
headers = channel.headers
|
||||
location_headers = headers.getRawHeaders(b"Location", [])
|
||||
self.assertEqual(location_headers, [b"/no/over/there"])
|
||||
cookies_headers = headers.getRawHeaders(b"Set-Cookie", [])
|
||||
|
|
Loading…
Reference in a new issue