bpo-35283: Add pending deprecation warning for Thread.isAlive (GH-11604)
Add a pending deprecated warning for the threading.Thread.isAlive() method.
diff --git a/Lib/test/test_threading.py b/Lib/test/test_threading.py
index 8160a5a..27f328d 100644
--- a/Lib/test/test_threading.py
+++ b/Lib/test/test_threading.py
@@ -415,7 +415,8 @@
t.setDaemon(True)
t.getName()
t.setName("name")
- t.isAlive()
+ with self.assertWarnsRegex(PendingDeprecationWarning, 'use is_alive()'):
+ t.isAlive()
e = threading.Event()
e.isSet()
threading.activeCount()