From 497dc15371d295a6c87ebf3ca3c0e0d6ed5c1a7a Mon Sep 17 00:00:00 2001 From: Shwetha Gururaj Date: Tue, 15 Jul 2025 15:52:35 -0400 Subject: [PATCH 1/2] Skip integration tests workflow for dependabot PRs --- .github/workflows/tests-integration.yml | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/.github/workflows/tests-integration.yml b/.github/workflows/tests-integration.yml index 71cd296e941..3649ababbd0 100644 --- a/.github/workflows/tests-integration.yml +++ b/.github/workflows/tests-integration.yml @@ -33,6 +33,7 @@ on: jobs: get-sha: runs-on: ubuntu-latest + if: github.actor != 'dependabot[bot]' outputs: gitRef: ${{steps.calculate.outputs.ref}} steps: @@ -85,7 +86,7 @@ jobs: - create-cf-env outputs: env-name: ${{ steps.set-name.outputs.env-name }} - if: always() + if: ${{ always() && github.actor != 'dependabot[bot]' }} steps: - name: set env name id: set-name @@ -101,7 +102,11 @@ jobs: needs: - get-sha - set-env-name - if: ${{ always() && (github.event_name != 'workflow_dispatch' || inputs.workflow == 'all' || inputs.workflow == 'run-integration-tests-cf-env') }} + if: > + ${{ always() && + needs.set-env-name.result == 'success' && + (github.event_name != 'workflow_dispatch' || inputs.workflow == 'all' || + inputs.workflow == 'run-integration-tests-cf-env') }} uses: ./.github/workflows/tests-integration-reusable.yml with: name: Integration @@ -115,7 +120,11 @@ jobs: needs: - get-sha - set-env-name - if: ${{ always() && (github.event_name != 'workflow_dispatch' || inputs.workflow == 'all' || inputs.workflow == 'run-integration-tests-cf-env-with-client-creds') }} + if: > + ${{ always() && + needs.set-env-name.result == 'success' && + (github.event_name != 'workflow_dispatch' || inputs.workflow == 'all' || + inputs.workflow == 'run-integration-tests-cf-env-with-client-creds') }} uses: ./.github/workflows/tests-integration-reusable.yml with: name: Integration client creds @@ -126,7 +135,7 @@ jobs: delete-env: name: Unclaim environment - if: ${{ always() && inputs.env-name == '' }} + if: ${{ always() && inputs.env-name == '' && needs.set-env-name.result == 'success' }} needs: - set-env-name - run-integration-tests-cf-env From ed3cce348707b11882970e1aa16108e1e10cdf6b Mon Sep 17 00:00:00 2001 From: Shwetha Gururaj Date: Tue, 15 Jul 2025 16:01:19 -0400 Subject: [PATCH 2/2] Fix syntax --- .github/workflows/tests-integration.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/tests-integration.yml b/.github/workflows/tests-integration.yml index 3649ababbd0..683da25d76b 100644 --- a/.github/workflows/tests-integration.yml +++ b/.github/workflows/tests-integration.yml @@ -33,7 +33,7 @@ on: jobs: get-sha: runs-on: ubuntu-latest - if: github.actor != 'dependabot[bot]' + if: ${{ github.actor != 'dependabot[bot]' }} outputs: gitRef: ${{steps.calculate.outputs.ref}} steps: