Explicitly check is_redirect in simple test case (#208)
This commit is contained in:
parent
e51b2125c9
commit
bebedcbd5d
@ -135,11 +135,13 @@ async def test_disallow_redirects():
|
||||
)
|
||||
assert response.status_code == codes.SEE_OTHER
|
||||
assert response.url == URL("https://example.org/redirect_303")
|
||||
assert response.is_redirect is True
|
||||
assert len(response.history) == 0
|
||||
|
||||
response = await response.next()
|
||||
assert response.status_code == codes.OK
|
||||
assert response.url == URL("https://example.org/")
|
||||
assert response.is_redirect is False
|
||||
assert len(response.history) == 1
|
||||
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user