diff --git a/tests/test_main.py b/tests/test_main.py index 836ef71..63dae5a 100644 --- a/tests/test_main.py +++ b/tests/test_main.py @@ -84,8 +84,7 @@ async def test_worker_ignore_fields(httpserver: HTTPServer): task = asyncio.create_task( worker(requests, results, session, worker_id, url, ignore_fields) ) - async with asyncio.timeout(10): - await requests.join() + await asyncio.wait_for(requests.join(), timeout=10) assert results.qsize() == 1 result = await results.get() assert result == {"request": dummy_request, "response": dummy_data}