Skip to content

Commit

Permalink
Fix tests
Browse files Browse the repository at this point in the history
TODO: this mock test will be removed in favor of real Nextjs instance
in near future.
  • Loading branch information
danialkeimasi committed Aug 9, 2023
1 parent f73ed58 commit c2874fc
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion tests/test_render.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,4 +77,6 @@ async def test_render_nextjs_page(rf: RequestFactory):

args, kwargs = mock_session.call_args
assert "csrftoken" in kwargs["cookies"]
assert kwargs["headers"] == {"user-agent": "", "x-real-ip": "127.0.0.1", "extra": "headers"}
assert kwargs["headers"]["user-agent"] == ""
assert kwargs["headers"]["x-real-ip"] == "127.0.0.1"
assert kwargs["headers"]["extra"] == "headers"

0 comments on commit c2874fc

Please sign in to comment.