diff --git a/Lib/test/test_enum.py b/Lib/test/test_enum.py index fb3d5ad970f..b6082cf02b1 100644 --- a/Lib/test/test_enum.py +++ b/Lib/test/test_enum.py @@ -1478,7 +1478,7 @@ class TestSpecial(unittest.TestCase): class EvenMoreColor(Color, IntEnum): chartruese = 7 # - with self.assertRaisesRegex(ValueError, "\(.Foo., \(.pink., .black.\)\) is not a valid .*Color"): + with self.assertRaisesRegex(ValueError, r"\(.Foo., \(.pink., .black.\)\) is not a valid .*Color"): Color('Foo', ('pink', 'black')) def test_exclude_methods(self):