summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_asyncio/test_tasks.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/test/test_asyncio/test_tasks.py')
-rw-r--r--Lib/test/test_asyncio/test_tasks.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/Lib/test/test_asyncio/test_tasks.py b/Lib/test/test_asyncio/test_tasks.py
index 1282a98..d95c98f 100644
--- a/Lib/test/test_asyncio/test_tasks.py
+++ b/Lib/test/test_asyncio/test_tasks.py
@@ -2131,15 +2131,15 @@ class BaseTaskTests:
time = 0
while True:
time += 0.05
- await asyncio.gather(asyncio.sleep(0.05),
+ await asyncio.gather(asyncio.sleep(0.05, loop=loop),
return_exceptions=True,
loop=loop)
if time > 1:
return
async def main():
- qwe = asyncio.Task(test())
- await asyncio.sleep(0.2)
+ qwe = self.new_task(loop, test())
+ await asyncio.sleep(0.2, loop=loop)
qwe.cancel()
try:
await qwe