@@ -118,75 +118,18 @@ jobs:
118
118
sha : ${{ github.event.pull_request.head.sha || github.sha }}
119
119
120
120
test :
121
+ # Don't run tests on PRs from forks.
121
122
if : github.event_name == 'repository_dispatch' ||
122
123
github.event.pull_request.head.repo.full_name == github.repository
123
- name : test
124
+ uses : ./.github/workflows/ test.yml
124
125
needs :
125
126
- prerequisites
126
127
- build_provider
127
128
- build_sdk
128
- permissions :
129
- contents : read
130
- id-token : write
131
- runs-on : ubuntu-latest
132
- env :
133
- PROVIDER_VERSION : ${{ needs.prerequisites.outputs.version }}
134
- steps :
135
- - name : Checkout Repo
136
- uses : actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
137
- with :
138
- ref : ${{ env.PR_COMMIT_SHA }}
139
- persist-credentials : false
140
- - name : Checkout p/examples
141
- if : matrix.testTarget == 'pulumiExamples'
142
- uses : actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
143
- with :
144
- repository : pulumi/examples
145
- path : p-examples
146
- - name : Setup tools
147
- uses : ./.github/actions/setup-tools
148
- with :
149
- tools : pulumictl, pulumicli, ${{ matrix.language }}
150
- - name : Prepare local workspace
151
- run : make prepare_local_workspace
152
- - name : Download bin
153
- uses : ./.github/actions/download-bin
154
- - name : Download SDK
155
- uses : ./.github/actions/download-sdk
156
- with :
157
- language : ${{ matrix.language }}
158
- - name : Restore makefile progress
159
- run : make --touch provider schema build_${{ matrix.language }}
160
- - name : Update path
161
- run : echo "${{ github.workspace }}/bin" >> "$GITHUB_PATH"
162
- - name : Install Python deps
163
- if : matrix.language == 'python'
164
- run : |-
165
- pip3 install virtualenv==20.0.23
166
- pip3 install pipenv
167
- - name : Install dependencies
168
- run : make install_${{ matrix.language}}_sdk
169
- - name : Install gotestfmt
170
- uses : GoTestTools/gotestfmt-action@v2
171
- with :
172
- token : ${{ secrets.GITHUB_TOKEN }}
173
- version : v2.5.0
174
- - name : Run tests
175
- if : matrix.testTarget == 'local'
176
- run : cd examples && go test -v -count=1 -cover -timeout 2h -tags=${{ matrix.language }} -skip TestPulumiExamples -parallel 4 .
177
- - name : Run pulumi/examples tests
178
- if : matrix.testTarget == 'pulumiExamples'
179
- run : cd examples && go test -v -count=1 -cover -timeout 2h -tags=${{ matrix.language }} -run TestPulumiExamples -parallel 4 .
180
- strategy :
181
- fail-fast : false
182
- matrix :
183
- language :
184
- - nodejs
185
- - python
186
- - dotnet
187
- - go
188
- - java
189
- testTarget : [local]
129
+ secrets : inherit
130
+ with :
131
+ version : ${{ needs.prerequisites.outputs.version }}
132
+
190
133
license_check :
191
134
name : License Check
192
135
uses : ./.github/workflows/license.yml
0 commit comments