-
Notifications
You must be signed in to change notification settings - Fork 37
46 lines (43 loc) · 1.37 KB
/
test-reporter.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
---
## Workflow to process the JUnit test results and add a report to the checks.
name: test-reporter
on:
workflow_run:
workflows:
- test
types:
- completed
permissions:
contents: read
actions: read
checks: write
pull-requests: write
jobs:
report:
runs-on: ubuntu-latest
steps:
- uses: elastic/oblt-actions/test-report@v1
with:
artifact: /test-results(.*)/ # artifact name pattern
name: JUnit Tests # Name of the check run which will be created
path: "**/elastic-serverless-forwarder-junit.xml" # Path to test results (inside artifact .zip)
reporter: java-junit # Format of test results
output-to: step-summary # Write summary in the PR
coverage:
if: ${{ github.event.workflow_run.event == 'pull_request' }}
runs-on: ubuntu-latest
steps:
- uses: actions/download-artifact@v4
with:
pattern: test-results*
merge-multiple: true
run-id: ${{ github.event.workflow_run.id }}
- uses: 5monkeys/cobertura-action@ee5787cc56634acddedc51f21c7947985531e6eb
with:
path: "**/coverage.xml"
skip_covered: false
minimum_coverage: 100
fail_below_threshold: true
show_line: true
show_branch: true
show_missing: true