From 3bb632a293a0443b7fb838889cd3150e21310c5d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ivan=20Vu=C4=8Dica?= Date: Tue, 17 Sep 2024 18:53:22 +0000 Subject: [PATCH] .github/workflows: Also add junit test reports in the main job. --- .github/workflows/ci-bazel.yml | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/.github/workflows/ci-bazel.yml b/.github/workflows/ci-bazel.yml index aa71b0ad..91115cb4 100644 --- a/.github/workflows/ci-bazel.yml +++ b/.github/workflows/ci-bazel.yml @@ -119,6 +119,16 @@ jobs: name: junit-test-logs-regular-${{ matrix.name }} path: 'bazel-testlogs/**/test.log' + # This fails unless there's write permission in the token. Hence the attempt + # to run as triggered by these workflows in another job, which might then + # work on pull requests as well. This needs further investigation. + - name: Publish Test Report + uses: mikepenz/action-junit-report@v4 + if: success() || failure() # always run even if the previous step fails + with: + commit: ${{github.event.workflow_run.head_sha}} # remove if we don't use separate workflow + report_paths: 'bazel-testlogs/**/test.xml' + continue-on-error: true bazel_build_buildbuddy: runs-on: ubuntu-latest @@ -228,3 +238,14 @@ jobs: - name: print ldd run: ldd bazel-bin/util_test continue-on-error: true + + # This fails unless there's write permission in the token. Hence the attempt + # to run as triggered by these workflows in another job, which might then + # work on pull requests as well. This needs further investigation. + - name: Publish Test Report + uses: mikepenz/action-junit-report@v4 + if: success() || failure() # always run even if the previous step fails + with: + commit: ${{github.event.workflow_run.head_sha}} # remove if we don't use separate workflow + report_paths: 'bazel-testlogs/**/test.xml' + continue-on-error: true