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 ] 
23+   workflow_dispatch :
2324
2425jobs :
2526  build :
2627    runs-on : k8s-runner-e2e 
27- 
28-     if : ${{ github.event.workflow_run.conclusion != 'skipped' }} 
28+     #  We allow builds:
29+     #  1) When triggered manually
30+     #  2) When it's a merge into a branch
31+     #  3) For PRs that are labeled as build and
32+     #   - It's a code change
33+     #   - A build label was just added
34+     #  A bit complex, but prevents builds when other labels are manipulated
35+     if : > 
36+       github.event_name == 'workflow_dispatch' 
37+       || github.event_name == 'push' 
38+       || (contains(github.event.pull_request.labels.*.name, 'build') 
39+           && (github.event.action != 'labeled' || github.event.label.name == 'build') 
40+           ) 
2941
3042steps :
31-       #  Pinned 1.0.0 version
32-       - uses : haya14busa/action-workflow_run-status@967ed83efa565c257675ed70cfe5231f062ddd94 
33-       - uses : actions/checkout@v3 
43+       - uses : actions/checkout@v4 
3444        with :
3545          path : plugin 
36-           ref : ${{ github.event.workflow_run.head_sha }} 
3746
3847      - name : Checkout e2e test repo 
39-         uses : actions/checkout@v3  
48+         uses : actions/checkout@v4  
4049        with :
4150          repository : cdapio/cdap-e2e-tests 
4251          path : e2e 
52+           ref : release/6.11 
4353
4454      - name : Cache 
45-         uses : actions/cache@v3  
55+         uses : actions/cache@v4  
4656        with :
4757          path : ~/.m2/repository 
4858          key : ${{ runner.os }}-maven-${{ github.workflow }}-${{ hashFiles('**/pom.xml') }} 
5161
5262name : Get Secrets from GCP Secret Manager 
5363        id : ' secrets' 
54-         uses : ' google-github-actions/get-secretmanager-secrets@v0 ' 
64+         uses : ' google-github-actions/get-secretmanager-secrets@v2 ' 
5565        with :
5666          secrets : |- 
5767            SALESFORCE_USERNAME:cdapio-github-builds/SALESFORCE_USERNAME 
@@ -69,33 +79,21 @@ jobs:
6979          SALESFORCE_CONSUMER_KEY : ${{ steps.secrets.outputs.SALESFORCE_CONSUMER_KEY }} 
7080          SALESFORCE_CONSUMER_SECRET : ${{ steps.secrets.outputs.SALESFORCE_CONSUMER_SECRET }} 
7181
72-       - name : Upload report 
73-         uses : actions/upload-artifact@v3 
74-         if : always() 
75-         with :
76-           name : Cucumber report 
77-           path : ./plugin/target/cucumber-reports 
78- 
7982      - name : Upload debug files 
80-         uses : actions/upload-artifact@v3  
83+         uses : actions/upload-artifact@v4  
8184        if : always() 
8285        with :
8386          name : Debug files 
8487          path : ./**/target/e2e-debug 
8588
8689      - name : Upload reports to GCS 
87-         uses : google-github-actions/upload-cloud-storage@v0  
90+         uses : google-github-actions/upload-cloud-storage@v2  
8891        if : always() 
8992        with :
9093          path : ./plugin/target/cucumber-reports 
9194          destination : e2e-tests-cucumber-reports/${{ github.event.repository.name }}/${{ github.ref }} 
9295
93-       - name : github-status-action 
94-         uses : Sibz/github-status-action@67af1f4042a5a790681aad83c44008ca6cfab83d 
96+       - name : Cucumber Report URL 
9597        if : always() 
96-         with :
97-           authToken : ${{ secrets.GITHUB_TOKEN }} 
98-           state : success 
99-           context : Cucumber report 
100-           sha : ${{github.event.pull_request.head.sha || github.sha}} 
98+         run : echo "https://storage.googleapis.com/e2e-tests-cucumber-reports/${{ github.event.repository.name }}/${{ github.ref }}/cucumber-reports/advanced-reports/cucumber-html-reports/overview-features.html" 
10199
0 commit comments