[Python-checkins] gh-93247: Fix assert function in asyncio locks test (GH-93248)

miss-islington webhook-mailer at python.org
Sun Jun 5 21:42:32 EDT 2022


https://github.com/python/cpython/commit/fd247db57a536d62902b296af599505298fd1e70
commit: fd247db57a536d62902b296af599505298fd1e70
branch: 3.10
author: Miss Islington (bot) <31488909+miss-islington at users.noreply.github.com>
committer: miss-islington <31488909+miss-islington at users.noreply.github.com>
date: 2022-06-05T18:42:21-07:00
summary:

gh-93247: Fix assert function in asyncio locks test (GH-93248)

(cherry picked from commit 9081bbd036934ab435291db9d32d02fd42282951)

Co-authored-by: Cyker Way <cykerway at gmail.com>

files:
M Lib/test/test_asyncio/test_locks.py

diff --git a/Lib/test/test_asyncio/test_locks.py b/Lib/test/test_asyncio/test_locks.py
index c5e3fdcbc955a..167ae700e5c07 100644
--- a/Lib/test/test_asyncio/test_locks.py
+++ b/Lib/test/test_asyncio/test_locks.py
@@ -866,7 +866,7 @@ async def c4(result):
         self.assertTrue(t1.result())
         race_tasks = [t2, t3, t4]
         done_tasks = [t for t in race_tasks if t.done() and t.result()]
-        self.assertTrue(2, len(done_tasks))
+        self.assertEqual(2, len(done_tasks))
 
         # cleanup locked semaphore
         sem.release()



More information about the Python-checkins mailing list