27
27
description : Matrix of SLES distros, versions, and architectures to run the tests on
28
28
required : false
29
29
type : string
30
+ windows_matrix :
31
+ description : Matrix of Windows distros, versions, and architectures to run the tests on
32
+ required : false
33
+ type : string
30
34
linux_test_report_name :
31
35
description : Linux test report name
32
36
required : false
62
66
description : Matrix of SLES distros, versions, and architectures to run the tests on
63
67
required : false
64
68
type : string
69
+ windows_matrix :
70
+ description : Matrix of Windows distros, versions, and architectures to run the tests on
71
+ required : false
72
+ type : string
65
73
linux_test_report_name :
66
74
description : Linux test report name
67
75
required : false
@@ -102,14 +110,14 @@ jobs:
102
110
secrets : inherit
103
111
104
112
build_suse_packages :
105
- needs : [spin_up_suse ]
113
+ needs : [ spin_up_suse ]
106
114
uses : ./.github/workflows/run_task.yml
107
115
with :
108
116
container_make_target : " ansible/build-fb-suse/run PRE_RELEASE_NAME=${{ inputs.pre_release_name }}"
109
117
secrets : inherit
110
118
111
119
tear_down_suse :
112
- needs : [build_suse_packages ]
120
+ needs : [ build_suse_packages ]
113
121
if : always()
114
122
uses : ./.github/workflows/run_task.yml
115
123
with :
@@ -144,10 +152,12 @@ jobs:
144
152
run :
145
153
gh release upload ${{ inputs.pre_release_name }} packages/* --clobber
146
154
147
-
148
155
provision_and_execute_tests_linux :
149
- name : Provision instances and run tests for linux
150
- needs : [spin_up_test_executor_instances, sign_suse_packages, tear_down_suse]
156
+ name : Provision instances and run tests for linux
157
+ needs : [ spin_up_test_executor_instances, sign_suse_packages, tear_down_suse ]
158
+ if : ${{ always() && !failure() && !cancelled()
159
+ && (needs.spin_up_test_executor_instances.result == 'success' || needs.spin_up_test_executor_instances.result == 'skipped')
160
+ && (needs.sign_suse_packages.result == 'success' || needs.sign_suse_packages.result == 'skipped')}}
151
161
uses : ./.github/workflows/run_task.yml
152
162
with :
153
163
container_make_target : " ansible/provision-and-execute-tests/${{ inputs.infra_agent_env }}-linux PRE_RELEASE_NAME=${{ inputs.gh_release_name }} TEST_REPORT_NAME=${{ inputs.linux_test_report_name }}"
@@ -156,15 +166,17 @@ jobs:
156
166
provision_and_execute_tests_windows :
157
167
name : Provision instances and run tests for windows
158
168
needs : spin_up_test_executor_instances
169
+ if : ${{ (needs.spin_up_test_executor_instances.result == 'success' || needs.spin_up_test_executor_instances.result == 'skipped') && ( inputs.windows_matrix != '[]' ) }}
159
170
uses : ./.github/workflows/run_task.yml
160
171
with :
161
172
container_make_target : " ansible/provision-and-execute-tests/${{ inputs.infra_agent_env }}-windows PRE_RELEASE_NAME=${{ inputs.gh_release_name }} TEST_REPORT_NAME=${{ inputs.windows_test_report_name }}"
162
173
secrets : inherit
163
174
164
175
report_linux_test_results :
165
- name : Report results
176
+ name : Report results linux
166
177
runs-on : ubuntu-20.04
167
178
needs : [ provision_and_execute_tests_linux ]
179
+ if : ${{ always() && !failure() && !cancelled() && (needs.provision_and_execute_tests_linux.result == 'success')}}
168
180
env :
169
181
GH_TOKEN : ${{ github.token }}
170
182
steps :
@@ -190,9 +202,10 @@ jobs:
190
202
${{ inputs.linux_test_report_name }}
191
203
192
204
report_windows_test_results :
193
- name : Report results
205
+ name : Report results windows
194
206
runs-on : ubuntu-20.04
195
- needs : [provision_and_execute_tests_windows ]
207
+ needs : [ provision_and_execute_tests_windows ]
208
+ if : ${{ inputs.windows_matrix != '[]' }}
196
209
env :
197
210
GH_TOKEN : ${{ github.token }}
198
211
steps :
@@ -220,7 +233,7 @@ jobs:
220
233
tear_down_test_executor_instances :
221
234
name : Tear down test executor instances
222
235
if : always()
223
- needs : [report_windows_test_results, report_linux_test_results]
236
+ needs : [ report_windows_test_results, report_linux_test_results ]
224
237
uses : ./.github/workflows/run_task.yml
225
238
with :
226
239
container_make_target : " terraform/ec2-test-executors/clean PRE_RELEASE_NAME=${{ inputs.gh_release_name }}"
0 commit comments