darrenburns / ward

Ward is a modern test framework for Python with a focus on productivity and readability.
https://ward.readthedocs.io
MIT License
1.21k stars 53 forks source link

make async library configurable with support for asyncio/curio/trio #357

Open logileifs opened 1 year ago

logileifs commented 1 year ago

This merge request adds support to run tests using an async library other than the standard asyncio. This can be configured globally for all tests by setting async-library in the project's pyproject.toml or per test by setting async_library in the test decorator.
Example: @test('my test that uses curio', async_library="curio")

codecov[bot] commented 1 year ago

Codecov Report

Base: 84.93% // Head: 84.90% // Decreases project coverage by -0.02% :warning:

Coverage data is based on head (8dff097) compared to base (67e197d). Patch coverage: 90.32% of modified lines in pull request are covered.

:exclamation: Current head 8dff097 differs from pull request most recent head 90dacbc. Consider uploading reports for the commit 90dacbc to get more accurate results

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #357 +/- ## ========================================== - Coverage 84.93% 84.90% -0.03% ========================================== Files 21 21 Lines 1845 1862 +17 Branches 284 287 +3 ========================================== + Hits 1567 1581 +14 - Misses 236 238 +2 - Partials 42 43 +1 ``` | [Impacted Files](https://codecov.io/gh/darrenburns/ward/pull/357?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Darren+Burns) | Coverage Δ | | |---|---|---| | [ward/testing.py](https://codecov.io/gh/darrenburns/ward/pull/357/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Darren+Burns#diff-d2FyZC90ZXN0aW5nLnB5) | `95.75% <88.46%> (-0.77%)` | :arrow_down: | | [ward/\_collect.py](https://codecov.io/gh/darrenburns/ward/pull/357/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Darren+Burns#diff-d2FyZC9fY29sbGVjdC5weQ==) | `85.81% <100.00%> (ø)` | | | [ward/\_run.py](https://codecov.io/gh/darrenburns/ward/pull/357/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Darren+Burns#diff-d2FyZC9fcnVuLnB5) | `85.71% <100.00%> (+0.12%)` | :arrow_up: | | [ward/config.py](https://codecov.io/gh/darrenburns/ward/pull/357/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Darren+Burns#diff-d2FyZC9jb25maWcucHk=) | `100.00% <100.00%> (ø)` | | | [ward/models.py](https://codecov.io/gh/darrenburns/ward/pull/357/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Darren+Burns#diff-d2FyZC9tb2RlbHMucHk=) | `100.00% <100.00%> (ø)` | | Help us with your feedback. Take ten seconds to tell us [how you rate us](https://about.codecov.io/nps?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Darren+Burns). Have a feature suggestion? [Share it here.](https://app.codecov.io/gh/feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Darren+Burns)

:umbrella: View full report at Codecov.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.