From ed1fc09cbaa6b3b7ca1275e0b2ff34565faa59bc Mon Sep 17 00:00:00 2001 From: Pulumi Bot Date: Tue, 27 Feb 2024 06:46:37 +0000 Subject: [PATCH] [internal] Update GitHub Actions workflow files --- .github/workflows/run-acceptance-tests.yml | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/.github/workflows/run-acceptance-tests.yml b/.github/workflows/run-acceptance-tests.yml index 8d6d1315..a97399dd 100644 --- a/.github/workflows/run-acceptance-tests.yml +++ b/.github/workflows/run-acceptance-tests.yml @@ -282,6 +282,7 @@ jobs: run: exit 1 - name: Workflow is a success run: echo "🎉🎈🎉🎈🎉" + test: if: github.event_name == 'repository_dispatch' || github.event.pull_request.head.repo.full_name == github.repository @@ -302,6 +303,12 @@ jobs: path: ci-scripts repository: pulumi/scripts ref: deca2c5c6015ad7aaea6f572a1c2b198ca323592 + - name: Checkout p/examples + if: matrix.testTarget == 'pulumiExamples' + uses: actions/checkout@v4 + with: + repository: pulumi/examples + path: p-examples - name: Unshallow clone for tags run: git fetch --prune --unshallow --tags - name: Install Go @@ -385,15 +392,20 @@ jobs: token: ${{ secrets.GITHUB_TOKEN }} version: v2.5.0 - name: Run tests + if: matrix.testTarget == 'local' run: cd examples && go test -v -json -count=1 -cover -timeout 2h -tags=${{ - matrix.language }} -parallel 4 . 2>&1 | tee /tmp/gotest.log | gotestfmt - - if: failure() && github.event_name == 'push' + matrix.language }} -skip TestPulumiExamples -parallel 4 . 2>&1 | tee /tmp/gotest.log | gotestfmt + - if: failure() && github.event_name == 'push' && matrix.testTarget == 'local' name: Notify Slack uses: 8398a7/action-slack@v3 with: author_name: Failure in running ${{ matrix.language }} tests fields: repo,commit,author,action status: ${{ job.status }} + - name: Run pulumi/examples tests + if: matrix.testTarget == 'pulumiExamples' + run: cd examples && go test -v -json -count=1 -cover -timeout 2h -tags=${{ + matrix.language }} -run TestPulumiExamples -parallel 4 . 2>&1 | tee /tmp/gotest.log | gotestfmt strategy: fail-fast: false matrix: @@ -403,6 +415,7 @@ jobs: - dotnet - go - java + testTarget: [local] license_check: name: License Check uses: ./.github/workflows/license.yml