File tree 2 files changed +39
-0
lines changed
2 files changed +39
-0
lines changed Original file line number Diff line number Diff line change @@ -11,3 +11,6 @@ end_of_line = lf
11
11
charset = utf-8
12
12
trim_trailing_whitespace = true
13
13
insert_final_newline = true
14
+
15
+ [* .{yml,yaml} ]
16
+ indent_size = 2
Original file line number Diff line number Diff line change
1
+ name : Unit Test Results
2
+ on :
3
+ workflow_run :
4
+ workflows : [ "CI" ]
5
+ types :
6
+ - completed
7
+
8
+ jobs :
9
+ unit-test-results :
10
+ name : Unit Test Results
11
+ runs-on : ubuntu-latest
12
+ if : github.event.workflow_run.conclusion != 'skipped'
13
+
14
+ steps :
15
+ - name : Download and Extract Artifacts
16
+ env :
17
+ GITHUB_TOKEN : ${{secrets.GITHUB_TOKEN}}
18
+ run : |
19
+ mkdir -p artifacts && cd artifacts
20
+
21
+ artifacts_url=${{ github.event.workflow_run.artifacts_url }}
22
+
23
+ gh api "$artifacts_url" -q '.artifacts[] | [.name, .archive_download_url] | @tsv' | while read artifact
24
+ do
25
+ IFS=$'\t' read name url <<< "$artifact"
26
+ gh api $url > "$name.zip"
27
+ unzip -d "$name" "$name.zip"
28
+ done
29
+
30
+ - name : Publish Unit Test Results
31
+ uses : EnricoMi/publish-unit-test-result-action@v1
32
+ with :
33
+ commit : ${{ github.event.workflow_run.head_sha }}
34
+ event_file : artifacts/Event File/event.json
35
+ event_name : ${{ github.event.workflow_run.event }}
36
+ files : " artifacts/**/*.xml"
You can’t perform that action at this time.
0 commit comments