diff --git a/Lib/test/test_peg_generator/test_c_parser.py b/Lib/test/test_peg_generator/test_c_parser.py index a5d88501f77a..f9935258c861 100644 --- a/Lib/test/test_peg_generator/test_c_parser.py +++ b/Lib/test/test_peg_generator/test_c_parser.py @@ -365,8 +365,8 @@ def test_syntax_error_for_string(self) -> None: start: expr+ NEWLINE? ENDMARKER expr: NAME """ - test_source = """ - for text in ("a b 42 b a", "名 名 42 名 名"): + test_source = r""" + for text in ("a b 42 b a", "\u540d \u540d 42 \u540d \u540d"): try: parse.parse_string(text, mode=0) except SyntaxError as e: