-
Notifications
You must be signed in to change notification settings - Fork 86
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
aioresponses ignores custom response_class provided to aiohttp.ClientSession constructor #243
Comments
Had the same problem and resolved it by adding response_class like below:
|
@p2vvel So you mean: Adding the response class to the actual request instead of to the session is a workaround, right? |
Yes, I managed to use custom |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I'm using the following code, which preserves the response body in case
raise_for_status=True
.I copied it from aio-libs/aiohttp#4600 (comment) and it works in reality but not when testing with aioresponses:
I cannot point my finger on it. Might be my test setup is wrong but I feel like this is an error/missing feature of aioresponses, because, as I said, it works with a real server but not with a mocked one.
The text was updated successfully, but these errors were encountered: