Skip to content
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

Fix test_gzip_ignored_for_responses_with_encoding_set w/ brotli #1962

Merged
merged 1 commit into from
Nov 23, 2022

Conversation

mgorny
Copy link
Contributor

@mgorny mgorny commented Nov 22, 2022

Use a fake "text" Content-Encoding instead of "br" for test_gzip_ignored_for_responses_with_encoding_set. The latter currently fails if an implementation of brotli is actually installed, since the test uses fake content that is not valid Brotli stream. Rather than forcing a dependency on Brotli decoder, just use a custom Content-Encoding that should not yield any implicit processing.

Closes #1957

Use a fake "text" Content-Encoding instead of "br"
for test_gzip_ignored_for_responses_with_encoding_set.  The latter
currently fails if an implementation of brotli is actually installed,
since the test uses fake content that is not valid Brotli stream.
Rather than forcing a dependency on Brotli decoder, just use a custom
Content-Encoding that should not yield any implicit processing.

Closes encode#1597
@mgorny
Copy link
Contributor Author

mgorny commented Nov 22, 2022

It might also be a good idea to add separate variants with and without brotlicffi installed to the test matrix. However, I don't have a good idea how to integrate it with the scripts/* model.

@Kludex
Copy link
Member

Kludex commented Nov 23, 2022

I'd say this is good enough. We are testing that, if we set the Content-Encoding, then we don't apply the GZipMidldeware.

@Kludex
Copy link
Member

Kludex commented Nov 23, 2022

Thanks @mgorny !

@mgorny
Copy link
Contributor Author

mgorny commented Nov 23, 2022

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

test_gzip_ignored_for_responses_with_encoding_set fails if brotlicffi is installed
2 participants