You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When a user wants to run all tests in a session-scoped event loop, the documentation suggests implementing a pytest_collection_modifyitems hook.
In auto mode the hook causes duplicate asyncio markers to be attached to test items. This is a cosmetic issue, but creates additional noise when debugging item markers.
In strict mode the behavior of the hook rules out manual overrides of the asyncio mark.
A configuration option for the default loop scope as suggested in #705 (comment) would eliminate duplicate asyncio markers in auto mode and allow overriding the default loop scope with explicit markers in strict mode.
The text was updated successfully, but these errors were encountered:
0.24 adds essentially this option for fixtures in asyncio_default_fixture_loop_scope. It seems logical to me to add an equivalent for tests as well at the same time. The modifyitems approach definitely works, but is more complex, and having this option only for fixtures makes it all the more tantalizing to not have it for the tests themselves.
When a user wants to run all tests in a session-scoped event loop, the documentation suggests implementing a pytest_collection_modifyitems hook.
In auto mode the hook causes duplicate asyncio markers to be attached to test items. This is a cosmetic issue, but creates additional noise when debugging item markers.
In strict mode the behavior of the hook rules out manual overrides of the asyncio mark.
A configuration option for the default loop scope as suggested in #705 (comment) would eliminate duplicate asyncio markers in auto mode and allow overriding the default loop scope with explicit markers in strict mode.
The text was updated successfully, but these errors were encountered: