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

Websocket subprotocol #1887

Merged
merged 11 commits into from
Jul 29, 2020

Conversation

darkvariantdivine
Copy link
Contributor

Fix for issue #1878, @ahopkins for your review

Copy link
Member

@ahopkins ahopkins left a comment

Choose a reason for hiding this comment

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

Thanks for this. Looks good. Just a couple small points.

Also, to fix the broken Travis build, you can run make black to fix the linting issue.

sanic/websocket.py Outdated Show resolved Hide resolved
tests/test_asgi.py Outdated Show resolved Hide resolved
@codecov
Copy link

codecov bot commented Jul 15, 2020

Codecov Report

Merging #1887 into master will increase coverage by 0.19%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1887      +/-   ##
==========================================
+ Coverage   92.06%   92.26%   +0.19%     
==========================================
  Files          27       27              
  Lines        3089     3090       +1     
  Branches      552      553       +1     
==========================================
+ Hits         2844     2851       +7     
+ Misses        171      167       -4     
+ Partials       74       72       -2     
Impacted Files Coverage Δ
sanic/asgi.py 93.01% <100.00%> (ø)
sanic/websocket.py 88.76% <100.00%> (+0.12%) ⬆️
sanic/server.py 80.19% <0.00%> (+1.14%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 5ee8ee7...821767c. Read the comment docs.

@darkvariantdivine
Copy link
Contributor Author

@ahopkins I fixed all the linter errors and made all the changes you requested :)

Copy link
Member

@ahopkins ahopkins left a comment

Choose a reason for hiding this comment

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

Looks good. Thank you.

In future, these tests can be combined into a single with @pytest-mark-parametrize. But that can be a separate PR. Let's get this in.

https://docs.pytest.org/en/latest/parametrize.html#pytest-mark-parametrize-parametrizing-test-functions

@ahopkins ahopkins merged commit 5d5ed10 into sanic-org:master Jul 29, 2020
@ahopkins ahopkins mentioned this pull request Sep 30, 2020
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