We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 47e064f commit 04bd65eCopy full SHA for 04bd65e
Lib/test/test_asyncio/test_base_events.py
@@ -476,7 +476,7 @@ def test_run_until_complete_loop(self):
476
other_loop.run_until_complete, task)
477
478
def test_run_until_complete_loop_orphan_future_close_loop(self):
479
- class ShowStopper(BaseException):
+ class ShowStopper(SystemExit):
480
pass
481
482
async def foo(delay):
@@ -487,10 +487,8 @@ def throw():
487
488
self.loop._process_events = mock.Mock()
489
self.loop.call_soon(throw)
490
- try:
+ with self.assertRaises(ShowStopper):
491
self.loop.run_until_complete(foo(0.1))
492
- except ShowStopper:
493
- pass
494
495
# This call fails if run_until_complete does not clean up
496
# done-callback for the previous future.
0 commit comments