From 1f709cac3f8c06d452a89765f054a2efc5daaf59 Mon Sep 17 00:00:00 2001 From: Bas van Beek Date: Fri, 26 Nov 2021 15:21:47 +0100 Subject: TST: Strip overload/protocol suggestions from reported mypy errors --- numpy/typing/tests/test_typing.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'numpy') diff --git a/numpy/typing/tests/test_typing.py b/numpy/typing/tests/test_typing.py index ff0940302..bb3914434 100644 --- a/numpy/typing/tests/test_typing.py +++ b/numpy/typing/tests/test_typing.py @@ -136,7 +136,7 @@ def test_fail(path: str) -> None: output_mypy = OUTPUT_MYPY assert path in output_mypy for error_line in output_mypy[path]: - error_line = _strip_filename(error_line) + error_line = _strip_filename(error_line).split("\n", 1)[0] match = re.match( r"(?P\d+): (error|note): .+$", error_line, -- cgit v1.2.1