Skip to content

Commit 41c645b

Browse files
committed
fix: Correct warning message when redefining the event_loop fixture.
The message new refers to the "loop_scope" keyword argument, rather than "scope".
1 parent 2fd10f8 commit 41c645b

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

docs/reference/changelog.rst

+1
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ Changelog
66
===================
77
- Fixes an issue that caused a broken event loop when a function-scoped test was executed in between two tests with wider loop scope `#950 <https://github.com/pytest-dev/pytest-asyncio/issues/950>`_
88
- Improves test collection speed in auto mode `#1020 <https://github.com/pytest-dev/pytest-asyncio/pull/1020>`_
9+
- Corrects the warning that is emitted upon redefining the event_loop fixture
910

1011

1112
0.25.0 (2024-12-13)

pytest_asyncio/plugin.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -794,7 +794,7 @@ def _temporary_event_loop_policy(policy: AbstractEventLoopPolicy) -> Iterator[No
794794
Replacing the event_loop fixture with a custom implementation is deprecated
795795
and will lead to errors in the future.
796796
If you want to request an asyncio event loop with a scope other than function
797-
scope, use the "scope" argument to the asyncio mark when marking the tests.
797+
scope, use the "loop_scope" argument to the asyncio mark when marking the tests.
798798
If you want to return different types of event loops, use the event_loop_policy
799799
fixture.
800800
"""

0 commit comments

Comments
 (0)