Skip to content

Commit fc9bcf1

Browse files
committed
Fix
1 parent 88befb6 commit fc9bcf1

2 files changed

Lines changed: 4 additions & 4 deletions

File tree

setup.cfg

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,8 +83,6 @@ filterwarnings =
8383
ignore:datetime.*utcnow\(\) is deprecated and scheduled for removal:DeprecationWarning:freezegun.api
8484
# Weird issue in Python 3.13+ triggered in test_multipart.py
8585
ignore:coroutine method 'aclose' of 'BodyPartReader._decode_content_async' was never awaited:RuntimeWarning
86-
# To ease migration to pytest-asyncio
87-
ignore:.*requested an async fixture 'event_loop'
8886
junit_suite_name = aiohttp_test_suite
8987
norecursedirs = dist docs build .tox .eggs
9088
minversion = 3.8.2

tests/conftest.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -253,8 +253,10 @@ def assert_sock_fits(sock_path: str) -> None:
253253

254254

255255
@pytest.fixture
256-
async def event_loop() -> asyncio.AbstractEventLoop:
257-
return asyncio.get_running_loop()
256+
def event_loop() -> asyncio.AbstractEventLoop:
257+
loop = asyncio.new_event_loop()
258+
yield loop
259+
loop.close()
258260

259261

260262
def pytest_asyncio_loop_factories(config, item):

0 commit comments

Comments
 (0)