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

Add a test case for #7859 #7866

Closed
wants to merge 2 commits into from
Closed

Conversation

xiaohuanshu
Copy link

What do these changes do?

Add a test for #7859

Are there changes in behavior for the user?

no

Related issue number

#7859

Checklist

  • I think the code is well written
  • Unit tests for the changes exist
  • Documentation reflects the changes
  • If you provide code modification, please add yourself to CONTRIBUTORS.txt
    • The format is <Name> <Surname>.
    • Please keep alphabetical order, the file is sorted by names.
  • Add a new news fragment into the CHANGES folder
    • name it <issue_id>.<type> for example (588.bugfix)
    • if you don't have an issue_id change it to the pr id after creating the pr
    • ensure type is one of the following:
      • .feature: Signifying a new feature.
      • .bugfix: Signifying a bug fix.
      • .doc: Signifying a documentation improvement.
      • .removal: Signifying a deprecation or removal of public API.
      • .misc: A ticket has been closed, but it is not of interest to users.
    • Make sure to use full sentences with correct case and punctuation, for example: "Fix issue with non-ascii contents in doctest text files."

Comment on lines +121 to +130
== b"\xc1)\xec\xd0\x81\x10\x00\x00\x00\x03!\xd7\xf7\x87\x98\xc7\xae\x10*\x0c"
b"\x180`\xc0\x80\x01\x03\x06\x0c\x180`\xc0\x80\x01\x03\x06\x0c\x18\xb8\x1d"
b"\x18\x00"
)
for result in writer.transport.write.call_args_list[1:]:
assert (
result[0][0]
== b"\xc1&\xec\xd0\x81\x0c\x00\x00\x00\xc0 \x7f\xeb{|\x85\x10\x06\x0c"
b"\x180`\xc0\x80\x01\x03\x06\x0c\x180`\xc0\x80\x01\x03\x06\x0c\x8c"
b"\x07\x02"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Rather than depending on the compressed bytes, which is rather hard to evaluate, can we test that reading/decompressing gives the expected output?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think bdraco has already got this covered actually: https://github.com/aio-libs/aiohttp/pull/7865/files#diff-c82db6bac3cc2b13785c62de3180bef31a0dc1046cdc7655ca7d873d6c220eb4R114

So, we can probably close this one.

Co-authored-by: Sam Bull <aa6bs0@sambull.org>
@Dreamsorcerer
Copy link
Member

Superseded by #7865.

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.

2 participants