|
10 | 10 | env: |
11 | 11 | retention_days: 3 |
12 | 12 |
|
| 13 | +permissions: |
| 14 | + checks: write |
| 15 | + contents: read |
| 16 | + pull-requests: write |
| 17 | + security-events: write # required for SARIF upload |
| 18 | + actions: read |
| 19 | + |
13 | 20 | jobs: |
14 | 21 | tests: |
15 | 22 | runs-on: ubuntu-latest |
@@ -103,34 +110,24 @@ jobs: |
103 | 110 | retention-days: ${{ env.retention_days }} |
104 | 111 | # displays in summary page |
105 | 112 | - name: Publish Test Report |
106 | | - uses: mikepenz/action-junit-report@v3 |
107 | | - if: always() # always run even if the previous step fails |
108 | | - with: |
109 | | - report_paths: 'junit.xml' |
110 | | - # more in depth junit in console and annotations on failures |
111 | | - - uses: ashley-taylor/junit-report-annotations-action@1.3 |
112 | 113 | if: always() |
| 114 | + uses: EnricoMi/publish-unit-test-result-action@v2 |
113 | 115 | with: |
114 | | - access-token: ${{ secrets.GITHUB_TOKEN }} |
115 | | - path: junit.xml |
| 116 | + files: junit.xml |
| 117 | + check_name: Test Results |
116 | 118 | - run: npm run test:coverage |
117 | 119 | - name: upload code coverage |
118 | 120 | uses: actions/upload-artifact@v4 |
119 | 121 | with: |
120 | 122 | name: Report-CodeCoverage |
121 | 123 | path: coverage |
122 | 124 | retention-days: ${{ env.retention_days }} |
123 | | - # adds coverage comment to pr |
124 | | - - name: parse coverage |
125 | | - uses: danhunsaker/clover-reporter-action@v0.2.17-clover |
126 | | - with: |
127 | | - github-token: ${{ secrets.GITHUB_TOKEN }} |
128 | | - clover-file: ./coverage/clover.xml |
| 125 | + |
129 | 126 |
|
130 | 127 | automerge: |
131 | 128 | needs: tests |
132 | 129 | name: Auto-merge PR if tests pass |
133 | | - if: (github.actor == 'dependabot[bot]' || github.actor == 'imgbot[bot]') && needs.tests.result == 'success' |
| 130 | + if: (github.actor == 'dependabot[bot]' || github.actor == 'dependabot-preview[bot]' || github.actor == 'imgbot[bot]') && needs.tests.result == 'success' |
134 | 131 | runs-on: ubuntu-latest |
135 | 132 | steps: |
136 | 133 | - name: Merge PR |
|
0 commit comments