From c697a513786ae1cae0c9063a718636ed4b06e0df Mon Sep 17 00:00:00 2001 From: Nipunn Koorapati Date: Thu, 25 Aug 2022 04:25:26 -0700 Subject: [PATCH] Support tests/mypy_test.py [package] (#8610) Currently, the testsuite early exits if it's filtering on a single package. With this change, it will correctly complete. For example `tests/mypy_test.py protobuf` --- tests/mypy_test.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tests/mypy_test.py b/tests/mypy_test.py index 9518d8ad0..ed84a9da3 100755 --- a/tests/mypy_test.py +++ b/tests/mypy_test.py @@ -341,6 +341,9 @@ def test_third_party_distribution(distribution: str, args: TestConfig) -> TestRe seen_dists: set[str] = set() add_third_party_files(distribution, files, args, configurations, seen_dists) + if not files and args.filter: + return TestResults(0, 0) + print(f"testing {distribution} ({len(files)} files)... ", end="") if not files: