]> granicus.if.org Git - python/commitdiff
Fix invalid escape sequence: use raw string. (GH-6225)
authorEric V. Smith <ericvsmith@users.noreply.github.com>
Sun, 25 Mar 2018 03:02:21 +0000 (23:02 -0400)
committerGitHub <noreply@github.com>
Sun, 25 Mar 2018 03:02:21 +0000 (23:02 -0400)
Lib/test/test_dataclasses.py

index 8aff8ae140a5cd1c20f630b06dff51504fe7197e..75e3cffc4a5e1822f06e478cbe63900b1182fd1d 100755 (executable)
@@ -2667,7 +2667,7 @@ class TestSlots(unittest.TestCase):
         # There was a bug where a variable in a slot was assumed
         #  to also have a default value (of type types.MemberDescriptorType).
         with self.assertRaisesRegex(TypeError,
-                                    "__init__\(\) missing 1 required positional argument: 'x'"):
+                                    r"__init__\(\) missing 1 required positional argument: 'x'"):
             C()
 
         # We can create an instance, and assign to x.