8000
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent bb43976 commit 940bb36Copy full SHA for 940bb36
pytest_asyncio/plugin.py
@@ -685,15 +685,6 @@ def _temporary_event_loop_policy(policy: AbstractEventLoopPolicy) -> Iterator[No
685
yield
686
finally:
687
asyncio.set_event_loop_policy(old_loop_policy)
688
- # When a test uses both a scoped event loop and the event_loop fixture,
689
- # the "_provide_clean_event_loop" finalizer of the event_loop fixture
690
- # will already have installed a fresh event loop, in order to shield
691
- # subsequent tests from side-effects. We close this loop before restoring
692
- # the old loop to avoid ResourceWarnings.
693
- try:
694
- _get_event_loop_no_warn().close()
695
- except RuntimeError:
696
- pass
697
asyncio.set_event_loop(old_loop)
698
699
0 commit comments