Serve test server in thread#292
Merged
Merged
Conversation
2b51aff to
4998709
Compare
4998709 to
313c76d
Compare
Contributor
Author
|
Thanks @sethmlarson, I'll merge once the build passes. :-) |
florimondmanca
commented
Aug 29, 2019
| assert (await stream.read(8192, timeout)).startswith(b"HTTP/1.1 200 OK\r\n") | ||
|
|
||
| finally: | ||
| await stream.close() |
Contributor
Author
There was a problem hiding this comment.
For the record, I had to add this .close() call otherwise uvicorn would wait for the connection to terminate indefinitely and not shut down. In general I think it's best to make sure we do use the async with or .close() API on the objects manipulated in tests when possible, as we do in the core package.
florimondmanca
added a commit
that referenced
this pull request
Aug 29, 2019
Kludex
referenced
this pull request
in pydantic/httpx2
May 11, 2026
Bumps [trustme](https://github.com/python-trio/trustme) from 0.6.0 to 0.7.0. - [Release notes](https://github.com/python-trio/trustme/releases) - [Commits](python-trio/trustme@v0.6.0...v0.7.0) Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Florimond Manca <florimond.manca@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Following #276 (comment) cc @tomchristie