Skip to content
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Update test_tasks.py
  • Loading branch information
Dreamsorcerer authored Sep 3, 2021
commit cdaa9c87ff4152d0b5d2ce6c2eea85d46105dfff
4 changes: 2 additions & 2 deletions Lib/test/test_asyncio/test_tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -1026,15 +1026,15 @@ def gen():

def test_wait_for_does_not_suppress_cancellation(self):
async def inner():
await asyncio.sleep(0)
await asyncio.sleep(.1)

async def with_for_coro():
await wait_for(inner(), timeout=1)
assert False, 'End of with_for_coro. Should not be reached!'

async def main():
task = asyncio.create_task(with_for_coro())
await asyncio.sleep(0)
await asyncio.sleep(.1)
self.assertFalse(task.done())
task.cancel()
with self.assertRaises(asyncio.CancelledError):
Expand Down