File tree Expand file tree Collapse file tree 3 files changed +3
-7120
lines changed Expand file tree Collapse file tree 3 files changed +3
-7120
lines changed Original file line number Diff line number Diff line change @@ -119,14 +119,10 @@ jobs:
119119 - name : Build PF
120120 run : cd pkg/pf && make build
121121 - name : Shard tests
122- run : echo "SHARD_CMD=$(go run github.com/pulumi/sharder@828907542fdc6628c49e5139d35fa1f427570550 --total ${{ env.TOTAL_SHARDS }} --index ${{ matrix.shard }} --output test-timings.jsonl --format make)" >> $GITHUB_ENV
123- if : ${{ matrix.platform == 'ubuntu-latest' }}
124- - name : Test
125- run : make VERBOSE=true test_shard
122+ run : echo "RUN_TEST_CMD=$(go run github.com/pulumi/shard@5b6297aaffa0c06291fb8231968d7a9f4e6832e6 --total ${{ env.TOTAL_SHARDS }} --index ${{ matrix.shard }} --seed 42)" >> $GITHUB_ENV
126123 if : ${{ matrix.platform == 'ubuntu-latest' }}
127124 - name : Test
128125 run : make test
129- if : ${{ matrix.platform != 'ubuntu-latest' }}
130126 - name : Upload coverage reports to Codecov
131127 # If we have a CODECOV_TOKEN secret, then we upload it to get a coverage report.
132128 #
Original file line number Diff line number Diff line change @@ -27,27 +27,12 @@ lint:
2727lint_fix :
2828 go run scripts/build.go fix-lint
2929
30+ RUN_TEST_CMD ?= ./...
3031test :: install_plugins
3132 @mkdir -p bin
3233 go build -o bin ./internal/testing/pulumi-terraform-bridge-test-provider
3334 PULUMI_TERRAFORM_BRIDGE_TEST_PROVIDER=$(shell pwd) /bin/pulumi-terraform-bridge-test-provider \
34- go test -count=1 -coverprofile=" coverage.txt" -coverpkg=./... -timeout 2h -parallel ${TESTPARALLELISM} ./...
35-
36- # Run a single shard of tests. This is a make target for use in CI. It assumes the shard arguments are provided in SHARD_CMD
37- test_shard :: install_plugins
38- @mkdir -p bin
39- go build -o bin ./internal/testing/pulumi-terraform-bridge-test-provider
40- PULUMI_TERRAFORM_BRIDGE_TEST_PROVIDER=$(shell pwd) /bin/pulumi-terraform-bridge-test-provider \
41- go test -count=1 -coverprofile=" coverage.txt" -coverpkg=./... -timeout 2h -parallel ${TESTPARALLELISM} ./... ${SHARD_CMD}
42-
43- # Run the tests and record profiling data. This is used for partitioning tests into shards for CI.
44- test_profile :: install_plugins
45- @mkdir -p bin
46- go build -o bin ./internal/testing/pulumi-terraform-bridge-test-provider
47- rm -f test-timings.jsonl
48- PULUMI_TERRAFORM_BRIDGE_TEST_PROVIDER=$(shell pwd) /bin/pulumi-terraform-bridge-test-provider \
49- go test -count=1 -timeout 2h -parallel ${TESTPARALLELISM} ./... -json | \
50- jq -c -r ' select((.Action == "pass" or .Action == "fail") and .Test != null)' | tee test-timings.jsonl
35+ go test -count=1 -coverprofile=" coverage.txt" -coverpkg=./... -timeout 2h -parallel ${TESTPARALLELISM} $(value RUN_TEST_CMD)
5136
5237# Run tests while accepting current output as expected output "golden"
5338# tests. In case where system behavior changes intentionally this can
You can’t perform that action at this time.
0 commit comments