Skip to content

Commit 6894bb5

Browse files
eli-schwartzxclaesse
authored andcommitted
mtest: avoid meddling with stdout by default
The original point of specifying Optional was to default to None... oops. The practical effect of this change is that the testsuite no longer repeatedly logs "No tests defined." in between more meaningful output.
1 parent 46586c7 commit 6894bb5

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎mesonbuild/mtest.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1933,7 +1933,7 @@ def tests_from_args(self, tests: T.List[TestSerialisation]) -> T.Generator[TestS
19331933
# succeed on an invalid pattern.
19341934
raise MesonException(f'{arg} test name does not match any test')
19351935

1936-
def get_tests(self, errorfile: T.Optional[T.IO] = sys.stdout) -> T.List[TestSerialisation]:
1936+
def get_tests(self, errorfile: T.Optional[T.IO] = None) -> T.List[TestSerialisation]:
19371937
if not self.tests:
19381938
print('No tests defined.', file=errorfile)
19391939
return []

0 commit comments

Comments
 (0)