]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
gh-110088: Fix asyncio test_prompt_cancellation() (#110157)
authorVictor Stinner <vstinner@python.org>
Sat, 30 Sep 2023 20:40:10 +0000 (22:40 +0200)
committerGitHub <noreply@github.com>
Sat, 30 Sep 2023 20:40:10 +0000 (22:40 +0200)
Don't measure the CI performance: don't test the maximum elapsed
time. The check failed on a slow CI.

Lib/test/test_asyncio/test_events.py

index 3ee6565b2b65ada0f4154ede7c76f6942c5c53ba..b25c0975736e20ebf9e03eb963568d0992fbdb02 100644 (file)
@@ -1693,12 +1693,9 @@ class EventLoopTestsMixin:
                 self.loop.stop()
             return res
 
-        start = time.monotonic()
         t = self.loop.create_task(main())
         self.loop.run_forever()
-        elapsed = time.monotonic() - start
 
-        self.assertLess(elapsed, 0.1)
         self.assertEqual(t.result(), 'cancelled')
         self.assertRaises(asyncio.CancelledError, f.result)
         if ov is not None: