From: Anthony PERARD <anthony@xenproject.org>
To: "Marek Marczykowski-Górecki" <marmarek@invisiblethingslab.com>
Cc: xen-devel@lists.xenproject.org,
Andrew Cooper <andrew.cooper3@citrix.com>,
Anthony PERARD <anthony.perard@vates.tech>,
Doug Goldstein <cardoe@cardoe.com>,
Stefano Stabellini <sstabellini@kernel.org>
Subject: Re: [XEN PATCH v2 1/3] CI: Rework run-tools-test exit path
Date: Wed, 13 Aug 2025 14:38:29 +0200 [thread overview]
Message-ID: <aJyHRQJTcmIlUVWD@l14> (raw)
In-Reply-To: <aJd1yaBFSjTx_wsl@mail-itl>
On Sat, Aug 09, 2025 at 06:22:33PM +0200, Marek Marczykowski-Górecki wrote:
> On Wed, Jul 30, 2025 at 05:26:00PM +0200, Anthony PERARD wrote:
> > From: Anthony PERARD <anthony.perard@vates.tech>
> >
> > The main script expect to find the string "$passed" or it just timeout
> > and doesn't try to download the junit file in this case. So we ignore
> > the return value of run-tools-test to always print "$passed" and
> > instead look for failure in the generated junit file. If the junit
> > report is incomplete, this will also result in a failure of the job.
> >
> > Signed-off-by: Anthony PERARD <anthony.perard@vates.tech>
> > ---
> >
> > Notes:
> > Changes in v2:
> > - This squash both patch "CI: Ignore run-tools-test return value" and
> > "CI: Have the gitlab job fail on tools/tests failure"
> > - grep for '<failure type="failure"' instead of '</failure>'
> >
> > automation/scripts/qubes-x86-64.sh | 13 +++++++++++--
> > 1 file changed, 11 insertions(+), 2 deletions(-)
> >
> > diff --git a/automation/scripts/qubes-x86-64.sh b/automation/scripts/qubes-x86-64.sh
> > index 2750d24eba..21dcd9b063 100755
> > --- a/automation/scripts/qubes-x86-64.sh
> > +++ b/automation/scripts/qubes-x86-64.sh
> > @@ -135,10 +135,11 @@ done
> > ### tests: tools-tests-pv, tools-tests-pvh
> > "tools-tests-pv"|"tools-tests-pvh")
> > retrieve_xml=1
> > - passed="test passed"
> > + passed="run-tools-test over"
> > domU_check=""
> > dom0_check="
> > -/root/run-tools-tests /usr/lib/xen/tests /tmp/tests-junit.xml && echo \"${passed}\"
> > +/root/run-tools-tests /usr/lib/xen/tests /tmp/tests-junit.xml ||:
> > +echo \"${passed}\"
> > nc -l -p 8080 < /tmp/tests-junit.xml >/dev/null &
> > "
> > if [ "${test_variant}" = "tools-tests-pvh" ]; then
> > @@ -297,6 +298,14 @@ TEST_RESULT=$?
> >
> > if [ -n "$retrieve_xml" ]; then
> > nc -w 10 "$SUT_ADDR" 8080 > tests-junit.xml </dev/null
> > + # Findout if one of the test failed
> > + if ! grep -q '</testsuites>' tests-junit.xml; then
> > + echo "ERROR: tests-junit.xml is incomplete or missing."
> > + TEST_RESULT=1
> > + # Only match "type=failure" to allow to "tolerable" for example.
> > + elif grep -q '<failure type="failure"' tests-junit.xml; then
>
> Maybe drop -q here, or add some message? Otherwise it's not obvious why it failed. See for example:
> https://gitlab.com/xen-project/people/marmarek/xen/-/jobs/10968674458
>
> Yes, you can click "Test summary" link, but it isn't obvious by looking
> at the final part of the log. Alternatively, this can be combined with
> my "CI: list failed tests at the end of tools job" patch (already
> reviewed by Andrew), but I had an impression this series is supposed to
> be included instead of that one.
Dropping "-q" sounds good here, it mean in your pipeline example we
would have the following in the logs:
<failure type="failure" message="binary /usr/lib/xen/tests/test_vpci exited with code 134">
Which should be could enough for now.
Thanks,
--
Anthony PERARD
next prev parent reply other threads:[~2025-08-13 12:38 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-07-30 15:25 [XEN PATCH v2 0/3] CI: Fixes for tools/tests and junit and other Anthony PERARD
2025-07-30 15:26 ` [XEN PATCH v2 1/3] CI: Rework run-tools-test exit path Anthony PERARD
2025-08-09 16:22 ` Marek Marczykowski-Górecki
2025-08-13 12:38 ` Anthony PERARD [this message]
2025-07-30 15:26 ` [XEN PATCH v2 2/3] CI: Upload junit result as artefact Anthony PERARD
2025-08-09 16:23 ` Marek Marczykowski-Górecki
2025-07-30 15:26 ` [XEN PATCH v2 3/3] CI: Workaround extra content in junit Anthony PERARD
2025-08-09 16:25 ` Marek Marczykowski-Górecki
2025-08-13 12:46 ` Anthony PERARD
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=aJyHRQJTcmIlUVWD@l14 \
--to=anthony@xenproject.org \
--cc=andrew.cooper3@citrix.com \
--cc=anthony.perard@vates.tech \
--cc=cardoe@cardoe.com \
--cc=marmarek@invisiblethingslab.com \
--cc=sstabellini@kernel.org \
--cc=xen-devel@lists.xenproject.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.