mirror of
https://github.com/python/cpython.git
synced 2025-07-23 03:05:38 +00:00
gh-127949: fix resource warnings in test_tasks.py
(#128172)
This commit is contained in:
parent
228f275737
commit
b66a4ad9fc
1 changed files with 8 additions and 8 deletions
|
@ -2698,7 +2698,7 @@ class BaseTaskTests:
|
|||
initial_refcount = sys.getrefcount(obj)
|
||||
|
||||
coro = coroutine_function()
|
||||
loop = asyncio.new_event_loop()
|
||||
with contextlib.closing(asyncio.EventLoop()) as loop:
|
||||
task = asyncio.Task.__new__(asyncio.Task)
|
||||
|
||||
for _ in range(5):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue