Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Synchronize async fixtures dynamically #668

Closed
seifertm opened this issue Nov 10, 2023 · 0 comments · Fixed by #906
Closed

Synchronize async fixtures dynamically #668

seifertm opened this issue Nov 10, 2023 · 0 comments · Fixed by #906
Milestone

Comments

@seifertm
Copy link
Contributor

Asynchronous fixtures are currently synchronized as part of the pytest_pycollect_makeitem hook. This forces pytest-asyncio to provide a separate code path for fixtures. That involves different synchronization wrappers for coroutines and async generators as well as custom code for fixture rebinding.

To simplify the future maintenance of pytest-asyncio, fixtures should be synchronized dynamically when a test requests them.

# for free to join this conversation on GitHub. Already have an account? # to comment
Projects
None yet
1 participant