All of lore.kernel.org
 help / color / mirror / Atom feed
From: Justin Tobler <jltobler@gmail.com>
To: Patrick Steinhardt <ps@pks.im>
Cc: git@vger.kernel.org
Subject: Re: [PATCH 5/5] gitlab-ci: handle failed tests on MSVC+Meson job
Date: Mon, 9 Feb 2026 12:33:50 -0600	[thread overview]
Message-ID: <aYolvOd4erKFhSUE@denethor> (raw)
In-Reply-To: <20260209-b4-pks-ci-meson-improvements-v1-5-38444dec4874@pks.im>

On 26/02/09 05:56PM, Patrick Steinhardt wrote:
> The MSVC+Meson job does not currently have any logic to print failing
> tests, nor does it upload the failed test artifacts. Backfill this logic
> to make help debugging efforts in case any of its jobs has failed.
> 
> GitHub already knows to do this, so we don't need an equivalent change
> over there.
> 
> Signed-off-by: Patrick Steinhardt <ps@pks.im>
> ---
>  .gitlab-ci.yml | 14 +++++++++++++-
>  1 file changed, 13 insertions(+), 1 deletion(-)
> 
> diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
> index 04857b479d..71b8a6e642 100644
> --- a/.gitlab-ci.yml
> +++ b/.gitlab-ci.yml
> @@ -157,6 +157,8 @@ test:mingw64:
>    parallel: 10
>  
>  .msvc-meson:
> +  variables:
> +    TEST_OUTPUT_DIRECTORY: "C:/Git-Test"
>    tags:
>      - saas-windows-medium-amd64
>    before_script:
> @@ -164,12 +166,13 @@ test:mingw64:
>      - choco install -y git meson ninja rust-ms
>      - Import-Module $env:ChocolateyInstall\helpers\chocolateyProfile.psm1
>      - refreshenv
> +    - New-Item -Path $env:TEST_OUTPUT_DIRECTORY -ItemType Directory

Before the script starts we create the test output directory.

>  build:msvc-meson:
>    extends: .msvc-meson
>    stage: build
>    script:
> -    - meson setup build --vsenv -Dperl=disabled -Dbackend_max_links=1 -Dcredential_helpers=wincred
> +    - meson setup build --vsenv -Dperl=disabled -Dbackend_max_links=1 -Dcredential_helpers=wincred -Dtest_output_directory="$TEST_OUTPUT_DIRECTORY"

Now we set the test output directory build option accordingly.

>      - meson compile -C build
>    artifacts:
>      paths:
> @@ -185,10 +188,19 @@ test:msvc-meson:
>    script:
>      - |
>        & "C:/Program Files/Git/usr/bin/bash.exe" -l -c 'ci/run-test-slice-meson.sh build $CI_NODE_INDEX $CI_NODE_TOTAL'
> +  after_script:
> +    - |
> +      if ($env:CI_JOB_STATUS -ne "success") {
> +        & "C:/Program Files/Git/usr/bin/bash.exe" -l -c 'ci/print-test-failures.sh'
> +        Move-Item -Path "$env:TEST_OUTPUT_DIRECTORY/failed-test-artifacts" -Destination t/
> +      }

Here we print any failures and move them so they are stored as a CI
artifact.

>    parallel: 10
>    artifacts:
> +    paths:
> +      - t/failed-test-artifacts
>      reports:
>        junit: build/meson-logs/testlog.junit.xml
> +    when: on_failure

This patch also looks good.

-Justin

      reply	other threads:[~2026-02-09 18:33 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-02-09 16:56 [PATCH 0/5] Some assorted fixes for GitLab CI Patrick Steinhardt
2026-02-09 16:56 ` [PATCH 1/5] ci: handle failures of test-slice helper Patrick Steinhardt
2026-02-09 16:56 ` [PATCH 2/5] ci: don't skip smallest test slice in GitLab Patrick Steinhardt
2026-02-09 18:07   ` Justin Tobler
2026-02-09 16:56 ` [PATCH 3/5] ci: make test slicing consistent across Meson/Make Patrick Steinhardt
2026-02-09 18:19   ` Justin Tobler
2026-02-10  5:34     ` Patrick Steinhardt
2026-02-10 22:15   ` Junio C Hamano
2026-02-10 22:54     ` Jeff King
2026-02-11  6:33       ` Patrick Steinhardt
2026-02-09 16:56 ` [PATCH 4/5] gitlab-ci: use "run-test-slice-meson.sh" Patrick Steinhardt
2026-02-09 16:56 ` [PATCH 5/5] gitlab-ci: handle failed tests on MSVC+Meson job Patrick Steinhardt
2026-02-09 18:33   ` Justin Tobler [this message]

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=aYolvOd4erKFhSUE@denethor \
    --to=jltobler@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=ps@pks.im \
    /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.