Skip to content

Commit 9018224

Browse files
fix a string backslash usages mistake, which also exposes the whitespace problem in the test
1 parent 19697af commit 9018224

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

mypy/test/meta/test_update_data.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ def test_update_data(self) -> None:
2121
# Note: We test multiple testcases rather than 'test case per test case'
2222
# so we could also exercise rewriting multiple testcases at once.
2323
result = _run_pytest_update_data(
24-
"""
24+
r"""
2525
[case testCorrect]
2626
s: str = 42 # E: Incompatible types in assignment (expression has type "int", variable has type "str")
2727
@@ -79,7 +79,7 @@ def test_update_data(self) -> None:
7979

8080
# Assert
8181
expected = dedent_docstring(
82-
"""
82+
r"""
8383
[case testCorrect]
8484
s: str = 42 # E: Incompatible types in assignment (expression has type "int", variable has type "str")
8585
@@ -93,7 +93,7 @@ def test_update_data(self) -> None:
9393
s: str = 42 # E: Incompatible types in assignment (expression has type "int", variable has type "str")
9494
9595
[case testMissingMultiline]
96-
s: str = 42; i: int = 'foo' # E: Incompatible types in assignment (expression has type "int", variable has type "str") \\
96+
s: str = 42; i: int = 'foo' # E: Incompatible types in assignment (expression has type "int", variable has type "str") \
9797
# E: Incompatible types in assignment (expression has type "str", variable has type "int")
9898
9999
[case testExtraneous]

0 commit comments

Comments
 (0)