Skip to content

Commit

Permalink
test(app-testing): PR on failure
Browse files Browse the repository at this point in the history
  • Loading branch information
y3rsh committed Dec 19, 2023
1 parent 26b0e84 commit 499f7f7
Showing 1 changed file with 18 additions and 1 deletion.
19 changes: 18 additions & 1 deletion .github/workflows/analyses-snapshot-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ jobs:
run: make setup

- name: Run Test
id: run_test
working-directory: app-testing
run: make snapshot-test

Expand All @@ -54,4 +55,20 @@ jobs:
uses: actions/upload-artifact@v4
with:
name: test-report
path: app-testing/results/
path: app-testing/results/

- name: Handle Test Failure
if: steps.run_test.outcome == 'failure'
working-directory: app-testing
run: make snapshot-test-update

- name: Create Snapshot update Request
if: steps.run_test.outcome == 'failure'
uses: peter-evans/create-pull-request@v5
with:
commit-message: 'fix(app-testing): snapshot failure capture'
title: 'Evaluate Analyses Snapshot Update ${{ env.TARGET }}'
body: 'This PR is an automated snapshot update request. Please review the changes and merge if they are acceptable or find you bug and fix it.'
branch: 'app-testing/${{ env.TARGET }}-from-${{ env.TEST_SOURCE}}'
base: ${{ env.TARGET }}

0 comments on commit 499f7f7

Please sign in to comment.