From 072f4a473e861c6c987650f08990c0ed1f76715f Mon Sep 17 00:00:00 2001 From: Irit Katriel <1055913+iritkatriel@users.noreply.github.com> Date: Tue, 25 Jan 2022 23:52:43 +0000 Subject: [PATCH] bpo-46431: use raw string for regex in test (GH-30901) --- Lib/test/test_exception_group.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Lib/test/test_exception_group.py b/Lib/test/test_exception_group.py index bbfce944c17658..b7b53bb2f0ecef 100644 --- a/Lib/test/test_exception_group.py +++ b/Lib/test/test_exception_group.py @@ -22,7 +22,7 @@ def test_exception_group_is_generic_type(self): class BadConstructorArgs(unittest.TestCase): def test_bad_EG_construction__too_many_args(self): - MSG = 'BaseExceptionGroup.__new__\(\) takes exactly 2 arguments' + MSG = r'BaseExceptionGroup.__new__\(\) takes exactly 2 arguments' with self.assertRaisesRegex(TypeError, MSG): ExceptionGroup('no errors') with self.assertRaisesRegex(TypeError, MSG):