1515name : Build e2e tests
1616
1717on :
18- workflow_run :
19- workflows :
20- - Trigger build
21- types :
22- - completed
18+ push :
19+ branches : [ develop, release/** ]
20+ pull_request :
21+ branches : [ develop, release/** ]
22+ types : [opened, synchronize, reopened, labeled]
2323
2424jobs :
2525 build :
2929 outputs :
3030 version : ${{ steps.version.outputs.version }}
3131 steps :
32- # Pinned 1.0.0 version
33- - uses : haya14busa/action-workflow_run-status@967ed83efa565c257675ed70cfe5231f062ddd94
3432 - uses : actions/checkout@v3
3533 with :
3634 repository : data-integrations/google-cloud
3937 uses : actions/checkout@v3
4038 with :
4139 path : e2e
42- ref : ${{ github.event.workflow_run.head_sha }}
4340 - name : Cache
4441 uses : actions/cache@v3
4542 with :
@@ -48,10 +45,10 @@ jobs:
4845 restore-keys : |
4946 ${{ runner.os }}-maven-${{ github.workflow }}
5047 - name : Run required e2e tests
51- if : ${{ github.event.workflow_run.event != 'workflow_dispatch' && github.event.workflow_run.event != 'push' }}
48+ if : ${{ github.event_name != 'workflow_dispatch' && github.event_name != 'push' }}
5249 run : python3 e2e/src/main/scripts/run_e2e_test.py --testRunner TestRunnerRequired.java --framework yes
5350 - name : Run all e2e tests
54- if : ${{ github.event.workflow_run.event == 'workflow_dispatch' || github.event.workflow_run.event == 'push' }}
51+ if : ${{ github.event_name == 'workflow_dispatch' || github.event_name == 'push' }}
5552 run : python3 e2e/src/main/scripts/run_e2e_test.py --framework yes
5653 - name : Upload report
5754 uses : actions/upload-artifact@v3
@@ -71,18 +68,10 @@ jobs:
7168 with :
7269 path : ./plugin/target/cucumber-reports
7370 destination : e2e-tests-cucumber-reports/${{ github.event.repository.name }}/${{ github.ref }}
74- - name : github-status-action
75- uses : Sibz/github-status-action@67af1f4042a5a790681aad83c44008ca6cfab83d
76- if : always()
77- with :
78- authToken : ${{ secrets.GITHUB_TOKEN }}
79- state : success
80- context : Cucumber report
81- sha : ${{ github.event.workflow_run.head_sha }}
8271
8372 maven-deploy :
84- if : ${{ github.event.workflow_run.event == 'push' }}
73+ if : ${{ github.event_name == 'push' }}
8574# needs: build TODO: once build is fixed
8675 uses : ./.github/workflows/deploy.yml
8776 with :
88- ref : ${{ github.event.workflow_run.head_sha }}
77+ ref : ${{ github.sha }}
0 commit comments