diff --git a/.github/workflows/test_backend.yml b/.github/workflows/test_backend.yml index bc5bec70a..22ccffaa0 100644 --- a/.github/workflows/test_backend.yml +++ b/.github/workflows/test_backend.yml @@ -1,15 +1,12 @@ name: Backend Test on: - push: - branches: - - test workflow_dispatch: inputs: deployment: required: true type: choice - default: "z6b8d2f7a-zca4a4c45-gtw.z937eb260.rustrocks.fr" + default: "govtool.cardanoapi.io/api" options: - "sanchogov.tools/api" - "staging.govtool.byron.network/api" @@ -26,10 +23,14 @@ on: - "preview" - "mainnet" - "preprod" + workflow_run: + workflows: ["Build and deploy GovTool test stack"] + types: [completed] jobs: backend-tests: runs-on: ubuntu-latest + if: ${{ github.event_name == 'workflow_dispatch' || github.event.workflow_run.conclusion == 'success' }} steps: - name: Checkout code uses: actions/checkout@v4 @@ -68,7 +69,7 @@ jobs: publish-report: runs-on: ubuntu-latest - if: always() + if: always() && needs.backend-tests.result != 'skipped' needs: backend-tests steps: - uses: actions/checkout@v4 diff --git a/.github/workflows/test_integration_playwright.yml b/.github/workflows/test_integration_playwright.yml index 4c99c6bf2..b00cee48f 100644 --- a/.github/workflows/test_integration_playwright.yml +++ b/.github/workflows/test_integration_playwright.yml @@ -1,15 +1,12 @@ name: Integration Test [Playwright] on: - push: - branches: - - test workflow_dispatch: inputs: deployment: required: true type: choice - default: "preview.gov.tools" + default: "govtool.cardanoapi.io" options: - "sanchogov.tools" - "staging.govtool.byron.network" @@ -27,12 +24,13 @@ on: - "preprod" workflow_run: - workflows: ["Build and deploy GovTool to TEST server"] + workflows: ["Build and deploy GovTool test stack"] types: [completed] jobs: integration-tests: runs-on: ubuntu-latest + if: ${{ github.event_name == 'workflow_dispatch' || github.event.workflow_run.conclusion == 'success' }} defaults: run: working-directory: tests/govtool-frontend/playwright @@ -111,7 +109,7 @@ jobs: publish-report: runs-on: ubuntu-latest - if: always() + if: always() && needs.integration-tests.result != 'skipped' needs: integration-tests steps: - uses: actions/checkout@v4