From 3f81dc3f1f9b9bb8b0cac1cf8b8792370af22957 Mon Sep 17 00:00:00 2001 From: Bart Louwers Date: Mon, 17 Jul 2023 11:56:24 +0200 Subject: [PATCH] Fix Linux render test CI failure showing up as pass (#1384) --- .github/workflows/linux-ci.yml | 3 ++- .github/workflows/pr-render-test-result.yml | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/linux-ci.yml b/.github/workflows/linux-ci.yml index 74ad2a842..6ff6ef7a8 100644 --- a/.github/workflows/linux-ci.yml +++ b/.github/workflows/linux-ci.yml @@ -160,17 +160,18 @@ jobs: - run: chmod +x ./mbgl-render-test-runner - name: Run render test - continue-on-error: true id: render_test run: xvfb-run -a ./mbgl-render-test-runner --manifestPath=metrics/linux-gcc8-release-style.json - name: Save PR number + if: always() && steps.render_test.outcome != 'failure' env: PR_NUMBER: ${{ github.event.number }} run: | echo $PR_NUMBER > ./pr_number - name: Upload render test result + if: always() && steps.render_test.outcome != 'failure' uses: actions/upload-artifact@v3 with: name: render-test-result diff --git a/.github/workflows/pr-render-test-result.yml b/.github/workflows/pr-render-test-result.yml index 3ea6f737a..9c1da49c9 100644 --- a/.github/workflows/pr-render-test-result.yml +++ b/.github/workflows/pr-render-test-result.yml @@ -13,11 +13,11 @@ on: jobs: upload-render-test-result: runs-on: ubuntu-22.04 - if: github.event.workflow_run.event == 'pull_request' + if: github.event.workflow_run.event == 'pull_request' && github.event.workflow_run.conclusion == 'failure' steps: - uses: actions/checkout@v3 - - uses: .github/actions/download-workflow-run-artifact + - uses: ./.github/actions/download-workflow-run-artifact with: artifact-name: render-test-result expect-files: "./pr_number, metrics/linux-gcc8-release-style.html"