From ed0e050bc5c0f4b4664ceabb96fc06c59da43d2b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Th=C3=A9ophile=20Diot?= Date: Fri, 3 May 2024 11:13:06 +0200 Subject: [PATCH] Update UI tests workflow to prepare tests before running --- .github/workflows/ui.yml | 25 +++++++++++++++++++++++-- 1 file changed, 23 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ui.yml b/.github/workflows/ui.yml index dd2a33a6f..fd4be55ff 100644 --- a/.github/workflows/ui.yml +++ b/.github/workflows/ui.yml @@ -63,13 +63,34 @@ jobs: security-events: write # UI tests + prepare-tests-ui: + runs-on: ubuntu-latest + steps: + - name: Checkout repository + uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + - id: set-matrix + run: | + tests=$(find ./tests/ui/ -name "*_page.py" -type f -printf "%f\n" | jq -c --raw-input --slurp 'split("\n")| .[0:-1]') + echo "tests=$tests" >> $GITHUB_OUTPUT + outputs: + tests: ${{ steps.set-matrix.outputs.tests }} tests-ui: - needs: [codeql, build-containers] + needs: [prepare-tests-ui, build-containers] + strategy: + fail-fast: false + matrix: + test: ${{ fromJson(needs.prepare-tests-ui.outputs.tests) }} uses: ./.github/workflows/tests-ui.yml with: + TEST: ${{ matrix.test }} RELEASE: ui tests-ui-linux: - needs: [codeql, build-packages] + needs: [prepare-tests-ui, build-packages] + strategy: + fail-fast: false + matrix: + test: ${{ fromJson(needs.prepare-tests-ui.outputs.tests) }} uses: ./.github/workflows/tests-ui-linux.yml with: + TEST: ${{ matrix.test }} RELEASE: ui