mirror of
https://github.com/python/cpython.git
synced 2025-09-26 18:29:57 +00:00
asyncio: Fix test_sleep_cancel(): call_later() mock has no self parameter
This commit is contained in:
parent
293f3f526d
commit
1690ed397a
1 changed files with 2 additions and 2 deletions
|
@ -993,9 +993,9 @@ class TaskTests(test_utils.TestCase):
|
||||||
handle = None
|
handle = None
|
||||||
orig_call_later = loop.call_later
|
orig_call_later = loop.call_later
|
||||||
|
|
||||||
def call_later(self, delay, callback, *args):
|
def call_later(delay, callback, *args):
|
||||||
nonlocal handle
|
nonlocal handle
|
||||||
handle = orig_call_later(self, delay, callback, *args)
|
handle = orig_call_later(delay, callback, *args)
|
||||||
return handle
|
return handle
|
||||||
|
|
||||||
loop.call_later = call_later
|
loop.call_later = call_later
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue