Skip to content

Commit

Permalink
Implemented fix for the #122 regression
Browse files Browse the repository at this point in the history
  • Loading branch information
petarmaric committed Feb 14, 2024
1 parent 9ea81af commit 587d00b
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/pook/interceptors/_httpx.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,12 @@ def _get_httpx_response(self, httpx_request, mock_response):
request=httpx_request,
)

# Allow to read the response on client side
res.is_stream_consumed = False
res.is_closed = False
if hasattr(res, "_content"):
del res._content

return res


Expand Down

0 comments on commit 587d00b

Please sign in to comment.