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

Allow overriding the scheme used in websocket_connect to support wss #48

Merged
merged 2 commits into from
Dec 30, 2021

Conversation

shevron
Copy link
Contributor

@shevron shevron commented Dec 28, 2021

This is my fix for #47. It allows passing scheme= to a websocket connection. I also took the liberty of passing any arguments to websocket_connect down to the WebSocketSession constructor, similar to how all the other get, post etc. method just pass arguments to open.

Happy to fix if there is any feedback.

@codecov-commenter
Copy link

codecov-commenter commented Dec 28, 2021

Codecov Report

Merging #48 (9821cb8) into master (0e92f98) will increase coverage by 0.03%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master      #48      +/-   ##
==========================================
+ Coverage   87.53%   87.56%   +0.03%     
==========================================
  Files           6        6              
  Lines         409      410       +1     
==========================================
+ Hits          358      359       +1     
  Misses         51       51              
Impacted Files Coverage Δ
async_asgi_testclient/testing.py 89.04% <100.00%> (ø)
async_asgi_testclient/websocket.py 74.41% <100.00%> (+0.30%) ⬆️

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 0e92f98...9821cb8. Read the comment docs.

@shevron
Copy link
Contributor Author

shevron commented Dec 28, 2021

Note that the formatting changes are caused by running the latest black (couldn't get the version specified in test-requirements.txt to run with Python 3.9.9). I ran it because otherwise Travis wouldn't pass.

@masipcat masipcat merged commit 56779ef into vinissimus:master Dec 30, 2021
@masipcat
Copy link
Contributor

Thank you for your contribution! Right now I'm on holidays so I'll do the release when I come back (in a couple of weeks)

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.

3 participants