Skip to content

Commit

Permalink
use integrationTestProvider instead of custom preTest action
Browse files Browse the repository at this point in the history
  • Loading branch information
iwahbe committed Jan 9, 2025
1 parent dc36807 commit ac05889
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 9 deletions.
6 changes: 1 addition & 5 deletions .ci-mgmt.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,6 @@ plugins:
version: "1.0.17"
kind: converter
goBuildParallelism: 2
actions:
preTest:
- name: Run provider tests
run: |
cd provider && go test -v -count=1 -cover -timeout 2h -tags=${{ matrix.language }} -parallel 4 .
# Use `pulumi convert` for translating examples from TF to Pulumi.
pulumiConvert: 1
integrationTestProvider: true
2 changes: 1 addition & 1 deletion .github/workflows/prerequisites.yml
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ jobs:
schema-tools compare -r github://api.github.com/pulumi -p gcp -o "${{ inputs.default_branch }}" -n --local-path=provider/cmd/pulumi-resource-gcp/schema.json;
echo "$EOF";
} >> "$GITHUB_ENV"
- if: inputs.is_pr && inputs.is_automated == false
- if: inputs.is_pr && inputs.is_automated == false && github.actor != 'dependabot[bot]'
name: Comment on PR with Details of Schema Check
uses: thollander/actions-comment-pull-request@24bffb9b452ba05a4f3f77933840a6a841d1b32b # v3.0.1
with:
Expand Down
5 changes: 3 additions & 2 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -98,8 +98,9 @@ jobs:
token: ${{ secrets.GITHUB_TOKEN }}
version: v2.5.0
- name: Run provider tests
run: |
cd provider && go test -v -count=1 -cover -timeout 2h -tags=${{ matrix.language }} -parallel 4 .
if: matrix.testTarget == 'local'
working-directory: provider
run: go test -v -count=1 -cover -timeout 2h -tags=${{ matrix.language }} -parallel 4 .
- name: Run tests
if: matrix.testTarget == 'local'
run: cd examples && go test -v -count=1 -cover -timeout 2h -tags=${{ matrix.language }} -skip TestPulumiExamples -parallel 4 .
Expand Down
2 changes: 1 addition & 1 deletion provider/gcp_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ func TestPreConfigureCallbackWarningWhenNoProject(t *testing.T) {
expectedLogs := &expectLogs{t, []string{noProjectErr}}
defer expectedLogs.assertDone()

t.Setenv("PULUMI_GCP_DISABLE_GLOBAL_PROJECT_WARNING", "")
t.Setenv("GOOGLE_PROJECT", "")

ctx := testutil.InitLogging(t, context.Background(), expectedLogs)
callback := preConfigureCallbackWithLogger(new(atomic.Bool), nil)
Expand Down

0 comments on commit ac05889

Please sign in to comment.