diff options
| author | Patrick Steinhardt <ps@pks.im> | 2025-02-27 08:23:20 +0100 |
|---|---|---|
| committer | Eli Schwartz <eschwartz93@gmail.com> | 2025-02-27 15:25:57 -0500 |
| commit | de7d8f9e48b7801659c15f03489d1b5a2fbe7d50 (patch) | |
| tree | e3aeaa0e96262c83a53c83116c800d23bc0d874d /mesonbuild/mtest.py | |
| parent | 7fd17ab12854ff5339f3309156cd9b705f517fd0 (diff) | |
| download | meson-de7d8f9e48b7801659c15f03489d1b5a2fbe7d50.tar.gz | |
test: fix hang when running tests that need parsing with `--interactive`
When running tests with `--interactive` we don't redirect stdin, stdout
or stderr and instead pass them on to the user's console. This redirect
causes us to hang in case the test in question needs parsing, like it is
the case for TAP output, because we cannot read the process's stdout.
Fix this hang by not parsing output when running in interactive mode.
Signed-off-by: Patrick Steinhardt <ps@pks.im>
Diffstat (limited to 'mesonbuild/mtest.py')
| -rw-r--r-- | mesonbuild/mtest.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mesonbuild/mtest.py b/mesonbuild/mtest.py index 5a5d25758..673f433fd 100644 --- a/mesonbuild/mtest.py +++ b/mesonbuild/mtest.py @@ -1621,7 +1621,7 @@ class SingleTestRunner: env=self.runobj.env, cwd=self.test.workdir) - if self.runobj.needs_parsing: + if self.runobj.needs_parsing and self.console_mode is not ConsoleUser.INTERACTIVE: parse_coro = self.runobj.parse(harness, p.stdout_lines()) parse_task = asyncio.ensure_future(parse_coro) else: |
