From 5a3515aa5e4a7eb2afd07b8c05bed495b57bc4bb Mon Sep 17 00:00:00 2001 From: Anze Staric Date: Tue, 21 Mar 2023 14:07:50 +0100 Subject: [PATCH] test_pipelines: ignore empty lines somehow stderr includes an empty line when run on pypy --- tests/test_pipelines.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/test_pipelines.py b/tests/test_pipelines.py index 80a849497..3973f5ae9 100644 --- a/tests/test_pipelines.py +++ b/tests/test_pipelines.py @@ -79,9 +79,9 @@ def get_output_with_iter_lines(cmd: BaseCommand) -> Tuple[List[str], List[str]]: stderr, stdout = [], [] proc = cmd.popen() for stdout_line, stderr_line in proc.iter_lines(retcode=[0, None]): - if stderr_line is not None: + if stderr_line: stderr.append(stderr_line) - if stdout_line is not None: + if stdout_line: stdout.append(stdout_line) proc.wait() return stdout, stderr