[Python-checkins] bpo-39424: Use assertRaisesRegex instead of assertRaisesRegexp. (GH-18277)

damani42 webhook-mailer at python.org
Thu Jan 30 05:26:30 EST 2020


https://github.com/python/cpython/commit/38c878b56cff997de8fb04a586c963039b69b414
commit: 38c878b56cff997de8fb04a586c963039b69b414
branch: master
author: damani42 <56308939+damani42 at users.noreply.github.com>
committer: GitHub <noreply at github.com>
date: 2020-01-30T12:26:22+02:00
summary:

bpo-39424: Use assertRaisesRegex instead of assertRaisesRegexp. (GH-18277)

files:
M Lib/test/test_signal.py

diff --git a/Lib/test/test_signal.py b/Lib/test/test_signal.py
index 5b072b0c60ee3..45553a6a42de7 100644
--- a/Lib/test/test_signal.py
+++ b/Lib/test/test_signal.py
@@ -1289,7 +1289,7 @@ def test_pidfd_send_signal(self):
         self.assertEqual(cm.exception.errno, errno.EBADF)
         my_pidfd = os.open(f'/proc/{os.getpid()}', os.O_DIRECTORY)
         self.addCleanup(os.close, my_pidfd)
-        with self.assertRaisesRegexp(TypeError, "^siginfo must be None$"):
+        with self.assertRaisesRegex(TypeError, "^siginfo must be None$"):
             signal.pidfd_send_signal(my_pidfd, signal.SIGINT, object(), 0)
         with self.assertRaises(KeyboardInterrupt):
             signal.pidfd_send_signal(my_pidfd, signal.SIGINT)



More information about the Python-checkins mailing list