From 2352644377f0d2febc226ba30c94046e4cc50130 Mon Sep 17 00:00:00 2001 From: Andrew Svetlov Date: Sun, 19 Dec 2021 20:12:24 +0200 Subject: [PATCH] Fix test error about deprecation warning (#30205) --- Lib/test/test_asyncio/test_locks.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Lib/test/test_asyncio/test_locks.py b/Lib/test/test_asyncio/test_locks.py index cfb6421b38f6..b9aae360384e 100644 --- a/Lib/test/test_asyncio/test_locks.py +++ b/Lib/test/test_asyncio/test_locks.py @@ -770,7 +770,8 @@ class ConditionTests(unittest.IsolatedAsyncioTestCase): ValueError, "loop argument must agree with lock" ): - asyncio.Condition(lock, loop=loop) + with self.assertWarns(DeprecationWarning): + asyncio.Condition(lock, loop=loop) await wrong_loop_in_lock() await wrong_loop_in_cond() -- 2.47.3