67
67
runs-on : ubuntu-20.04
68
68
69
69
env :
70
- EXTRA_BEHAVE_ARGS : " --tags=~@knative --tags=~@openshift --tags=~@examples --tags=~@supported-operator --tags=~@optional-annotations --tags=~@disable-github-actions"
70
+ EXTRA_BEHAVE_ARGS : " --tags=~@knative --tags=~@openshift --tags=~@examples --tags=~@supported-operator --tags=~@optional-annotations --tags=~@workload-resource-mapping --tags=~@ disable-github-actions"
71
71
TEST_RUN : Acceptance_tests_Kubernetes_with_OLM
72
72
73
73
steps :
@@ -116,7 +116,7 @@ jobs:
116
116
make SKIP_REGISTRY_LOGIN=true -o registry-login test-acceptance-with-bundle
117
117
118
118
- name : Collect Kube resources
119
- if : ${{ steps.check-skip-acceptance.outputs.can_skip != 'true' }}
119
+ if : ${{ steps.check-skip-acceptance.outputs.can_skip != 'true' && always() }}
120
120
continue-on-error : true
121
121
uses : ./.github/actions/collect-kube-resources
122
122
with :
@@ -137,7 +137,7 @@ jobs:
137
137
testspace [${{ env.TEST_RUN }}]${{ env.TEST_RESULTS }}/TEST*.xml
138
138
139
139
- uses : actions/upload-artifact@v2
140
- if : ${{ steps.check-skip-acceptance.outputs.can_skip != 'true' }}
140
+ if : ${{ steps.check-skip-acceptance.outputs.can_skip != 'true' && always() }}
141
141
with :
142
142
name : kubernetes-with-olm-test-results
143
143
path : ${{ env.TEST_RESULTS }}
@@ -196,7 +196,7 @@ jobs:
196
196
make SKIP_REGISTRY_LOGIN=true -o registry-login test-acceptance-with-bundle
197
197
198
198
- name : Collect Kube resources
199
- if : ${{ steps.check-skip-acceptance.outputs.can_skip != 'true' }}
199
+ if : ${{ steps.check-skip-acceptance.outputs.can_skip != 'true' && always() }}
200
200
continue-on-error : true
201
201
uses : ./.github/actions/collect-kube-resources
202
202
with :
@@ -217,12 +217,11 @@ jobs:
217
217
testspace [${{ env.TEST_RUN }}]${{ env.TEST_RESULTS }}/TEST*.xml
218
218
219
219
- uses : actions/upload-artifact@v2
220
- if : ${{ steps.check-skip-acceptance.outputs.can_skip != 'true' }}
220
+ if : ${{ steps.check-skip-acceptance.outputs.can_skip != 'true' && always() }}
221
221
with :
222
- name : supported-operators-kubernetes
222
+ name : optional-annotations
223
223
path : ${{ env.TEST_RESULTS }}
224
224
225
-
226
225
acceptance-supported-operators :
227
226
name : Supported Operators Acceptance Tests with Kubernetes and using OLM
228
227
runs-on : ubuntu-20.04
@@ -277,7 +276,7 @@ jobs:
277
276
make SKIP_REGISTRY_LOGIN=true -o registry-login test-acceptance-with-bundle
278
277
279
278
- name : Collect Kube resources
280
- if : ${{ steps.check-skip-acceptance.outputs.can_skip != 'true' }}
279
+ if : ${{ steps.check-skip-acceptance.outputs.can_skip != 'true' && always() }}
281
280
continue-on-error : true
282
281
uses : ./.github/actions/collect-kube-resources
283
282
with :
@@ -298,11 +297,91 @@ jobs:
298
297
testspace [${{ env.TEST_RUN }}]${{ env.TEST_RESULTS }}/TEST*.xml
299
298
300
299
- uses : actions/upload-artifact@v2
301
- if : ${{ steps.check-skip-acceptance.outputs.can_skip != 'true' }}
300
+ if : ${{ steps.check-skip-acceptance.outputs.can_skip != 'true' && always() }}
302
301
with :
303
302
name : supported-operators-kubernetes
304
303
path : ${{ env.TEST_RESULTS }}
305
304
305
+ acceptance-workload-resource-mapping :
306
+ name : Workload Resource Mapping Acceptance Tests with Kubernetes and using OLM
307
+ runs-on : ubuntu-20.04
308
+
309
+ env :
310
+ EXTRA_BEHAVE_ARGS : " --tags=@workload-resource-mapping --tags=~@disable-github-actions"
311
+ TEST_RUN : Workload_Resource_Mapping_Acceptance_tests_Kubernetes_with_OLM
312
+
313
+ steps :
314
+ - name : Checkout Git Repository
315
+ uses : actions/checkout@v2
316
+
317
+ - name : Check if acceptance tests can be skipped
318
+ id : check-skip-acceptance
319
+ uses : ./.github/actions/check-skip-acceptance-tests
320
+
321
+ - name : Set up Python
322
+ if : ${{ steps.check-skip-acceptance.outputs.can_skip != 'true' }}
323
+ uses : actions/setup-python@v2
324
+ with :
325
+ python-version : " 3.7"
326
+ architecture : " x64"
327
+
328
+ - name : Setup-cli
329
+ if : ${{ steps.check-skip-acceptance.outputs.can_skip != 'true' }}
330
+ uses : ./.github/actions/setup-cli
331
+ with :
332
+ start-minikube : true
333
+
334
+ - name : Wait for push
335
+ if : ${{ steps.check-skip-acceptance.outputs.can_skip != 'true' }}
336
+ uses : lewagon/wait-on-check-action@1b1630e169116b58a4b933d5ad7effc46d3d312d
337
+ with :
338
+ ref : ${{ github.event.pull_request.head.sha }}
339
+ check-name : " Push operator images (PR)"
340
+ repo-token : ${{ secrets.GITHUB_TOKEN }}
341
+ wait-interval : 60
342
+
343
+ - name : Extract image references
344
+ if : ${{ steps.check-skip-acceptance.outputs.can_skip != 'true' }}
345
+ uses :
marcofaggian/[email protected]
346
+ with :
347
+ names : operator-refs-${{github.event.pull_request.number}}-${{github.event.pull_request.head.sha}}
348
+
349
+ - name : Acceptance tests
350
+ if : ${{ steps.check-skip-acceptance.outputs.can_skip != 'true' }}
351
+ timeout-minutes : 60
352
+ run : |
353
+ source ./operator.refs
354
+ export CATSRC_NAME=sbo-pr-checks
355
+
356
+ make SKIP_REGISTRY_LOGIN=true -o registry-login test-acceptance-with-bundle
357
+
358
+ - name : Collect Kube resources
359
+ if : ${{ steps.check-skip-acceptance.outputs.can_skip != 'true' && always() }}
360
+ continue-on-error : true
361
+ uses : ./.github/actions/collect-kube-resources
362
+ with :
363
+ operator-namespace : operators
364
+ olm-namespace : olm
365
+ test-namespace-file : out/test-namespace
366
+ output-path : ${{env.TEST_RESULTS}}
367
+
368
+ - name : Setup Testspace
369
+ if : ${{ steps.check-skip-acceptance.outputs.can_skip != 'true' }}
370
+ uses : testspace-com/setup-testspace@v1
371
+ with :
372
+ domain : ${{ github.repository_owner }}
373
+
374
+ - name : Publish tests results to Testspace
375
+ if : ${{ steps.check-skip-acceptance.outputs.can_skip != 'true' }}
376
+ run : |
377
+ testspace [${{ env.TEST_RUN }}]${{ env.TEST_RESULTS }}/TEST*.xml
378
+
379
+ - uses : actions/upload-artifact@v2
380
+ if : ${{ steps.check-skip-acceptance.outputs.can_skip != 'true' && always() }}
381
+ with :
382
+ name : workload-resource-mapping
383
+ path : ${{ env.TEST_RESULTS }}
384
+
306
385
acceptance_without_olm :
307
386
name : Acceptance tests running on Kubernetes without using OLM
308
387
runs-on : ubuntu-20.04
@@ -374,7 +453,7 @@ jobs:
374
453
make TEST_ACCEPTANCE_START_SBO=remote test-acceptance
375
454
376
455
- name : Collect Kube resources
377
- if : ${{ steps.check-skip-acceptance.outputs.can_skip != 'true' }}
456
+ if : ${{ steps.check-skip-acceptance.outputs.can_skip != 'true' && always() }}
378
457
continue-on-error : true
379
458
uses : ./.github/actions/collect-kube-resources
380
459
with :
@@ -394,7 +473,7 @@ jobs:
394
473
testspace [${{ env.TEST_RUN }}]${{ env.TEST_RESULTS }}/TEST*.xml
395
474
396
475
- uses : actions/upload-artifact@v2
397
- if : ${{ steps.check-skip-acceptance.outputs.can_skip != 'true' }}
476
+ if : ${{ steps.check-skip-acceptance.outputs.can_skip != 'true' && always() }}
398
477
with :
399
478
name : kubernetes-without-olm-test-results
400
479
path : ${{ env.TEST_RESULTS }}
0 commit comments