diff options
author | Miss Islington (bot) <31488909+miss-islington@users.noreply.github.com> | 2022-09-27 00:00:53 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-09-27 00:00:53 (GMT) |
commit | 9a9bf88898b1558915405edb538513be425d39c4 (patch) | |
tree | 3c14ea791e7de5aa43b28960a45a20a3589305fe /Lib/test/test_asyncio | |
parent | 82932b3ec99955ff81080baf8b248210ab026454 (diff) | |
download | cpython-9a9bf88898b1558915405edb538513be425d39c4.zip cpython-9a9bf88898b1558915405edb538513be425d39c4.tar.gz cpython-9a9bf88898b1558915405edb538513be425d39c4.tar.bz2 |
gh-97545: Make Semaphore run faster. (GH-97549)
(cherry picked from commit 68c46ae68b6e0c36a12e37285fff9ce0782ed01e)
Co-authored-by: Cyker Way <cykerway@gmail.com>
Diffstat (limited to 'Lib/test/test_asyncio')
-rw-r--r-- | Lib/test/test_asyncio/test_locks.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/Lib/test/test_asyncio/test_locks.py b/Lib/test/test_asyncio/test_locks.py index 4b9d166..c20ec94 100644 --- a/Lib/test/test_asyncio/test_locks.py +++ b/Lib/test/test_asyncio/test_locks.py @@ -844,10 +844,9 @@ class SemaphoreTests(unittest.IsolatedAsyncioTestCase): sem.release() sem.release() - self.assertEqual(2, sem._value) + self.assertEqual(0, sem._value) await asyncio.sleep(0) - await asyncio.sleep(0) self.assertEqual(0, sem._value) self.assertEqual(3, len(result)) self.assertTrue(sem.locked()) |