From: "Daniel P. Berrangé" <berrange@redhat.com>
To: qemu-devel@nongnu.org
Cc: "Kevin Wolf" <kwolf@redhat.com>,
"Wainer dos Santos Moschetta" <wainersm@redhat.com>,
"Hanna Reitz" <hreitz@redhat.com>,
"Thomas Huth" <thuth@redhat.com>,
qemu-block@nongnu.org, "Philippe Mathieu-Daudé" <f4bug@amsat.org>,
"Beraldo Leal" <bleal@redhat.com>,
"Alex Bennée" <alex.bennee@linaro.org>,
"Daniel P. Berrangé" <berrange@redhat.com>
Subject: [PATCH 1/2] tests/qemu-iotests: print intent to run a test in TAP mode
Date: Mon, 9 May 2022 13:41:33 +0100 [thread overview]
Message-ID: <20220509124134.867431-2-berrange@redhat.com> (raw)
In-Reply-To: <20220509124134.867431-1-berrange@redhat.com>
When running I/O tests using TAP output mode, we get a single TAP test
with a sub-test reported for each I/O test that is run. The output looks
something like this:
1..123
ok qcow2 011
ok qcow2 012
ok qcow2 013
ok qcow2 217
...
If everything runs or fails normally this is fine, but periodically we
have been seeing the test harness abort early before all 123 tests have
been run, just leaving a fairly useless message like
TAP parsing error: Too few tests run (expected 123, got 107)
we have no idea which tests were running at the time the test harness
abruptly exited. This change causes us to print a message about our
intent to run each test, so we have a record of what is active at the
time the harness exits abnormally.
1..123
# running qcow2 011
ok qcow2 011
# running qcow2 012
ok qcow2 012
# running qcow2 013
ok qcow2 013
# running qcow2 217
ok qcow2 217
...
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
---
tests/qemu-iotests/testrunner.py | 3 +++
1 file changed, 3 insertions(+)
diff --git a/tests/qemu-iotests/testrunner.py b/tests/qemu-iotests/testrunner.py
index aae70a8341..dc871b7caf 100644
--- a/tests/qemu-iotests/testrunner.py
+++ b/tests/qemu-iotests/testrunner.py
@@ -361,6 +361,9 @@ def run_test(self, test: str,
starttime=start,
lasttime=last_el,
end = '\n' if mp else '\r')
+ else:
+ testname = os.path.basename(test)
+ print(f'# running {self.env.imgfmt} {testname}')
res = self.do_run_test(test, mp)
--
2.35.1
next prev parent reply other threads:[~2022-05-09 12:47 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-05-09 12:41 [PATCH 0/2] ci: improve debuggability of I/O tests Daniel P. Berrangé
2022-05-09 12:41 ` Daniel P. Berrangé [this message]
2022-05-09 12:48 ` [PATCH 1/2] tests/qemu-iotests: print intent to run a test in TAP mode Thomas Huth
2022-05-09 12:41 ` [PATCH 2/2] .gitlab-ci.d: export meson testlog.txt as an artifact Daniel P. Berrangé
2022-05-09 12:51 ` Thomas Huth
2022-05-09 20:22 ` Philippe Mathieu-Daudé via
2022-05-12 10:28 ` [PATCH 0/2] ci: improve debuggability of I/O tests Kevin Wolf
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220509124134.867431-2-berrange@redhat.com \
--to=berrange@redhat.com \
--cc=alex.bennee@linaro.org \
--cc=bleal@redhat.com \
--cc=f4bug@amsat.org \
--cc=hreitz@redhat.com \
--cc=kwolf@redhat.com \
--cc=qemu-block@nongnu.org \
--cc=qemu-devel@nongnu.org \
--cc=thuth@redhat.com \
--cc=wainersm@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).