Skip to content

Commit

Permalink
Tidy up the assert_response helper function
Browse files Browse the repository at this point in the history
Co-authored-by: Linus Huzell <[email protected]>
  • Loading branch information
DevL and linus-funnel committed Feb 29, 2024
1 parent c3984e0 commit 474f85f
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions tests/test_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,15 @@ def assertions(request, **kwargs):


def assert_response(
response, json=None, reason=None, status_code=200, text=None, url=None, headers={}
response,
json=None,
reason=None,
status_code=200,
text=None,
url=None,
headers={},
):
assert type(response) == Response
assert isinstance(response, Response)
assert response.status_code == status_code
assert response.reason == reason
assert response.url == url
Expand Down

0 comments on commit 474f85f

Please sign in to comment.