@@ -13,10 +13,12 @@ concurrency:
13
13
cancel-in-progress : true
14
14
15
15
env :
16
- ALLURE_REPORT_PATH : allure-report
17
- COVERAGE_REPORT_PATH : coverage-report
16
+ ALLURE_REPORT_FOLDER : allure-report
17
+ COVERAGE_REPORT_FOLDER : coverage-report
18
18
REPORT_EXT : .junit-report.xml
19
- COVERAGE_EXT : .info
19
+ COVERAGE_EXT : .coverage.info
20
+ REPO_BASE_PATH : catalyst-libs/
21
+
20
22
21
23
jobs :
22
24
generate-test-reports :
@@ -73,10 +75,10 @@ jobs:
73
75
74
76
- name : Setup Allure report
75
77
run : |
76
- mkdir -p ${{ env.ALLURE_REPORT_PATH }}
78
+ mkdir -p ${{ env.ALLURE_REPORT_FOLDER }}
77
79
shopt -s globstar
78
- cp **/*${{ env.REPORT_EXT }} ${{ env.ALLURE_REPORT_PATH }}
79
- ls ${{ env.ALLURE_REPORT_PATH }}
80
+ cp **/*${{ env.REPORT_EXT }} ${{ env.ALLURE_REPORT_FOLDER }}
81
+ ls ${{ env.ALLURE_REPORT_FOLDER }}
80
82
81
83
- name : Checkout gh-pages
82
84
uses : actions/checkout@v4
90
92
with :
91
93
report_id : " test-report"
92
94
gh_pages : " gh-pages-dir"
93
- report_dir : ${{ env.ALLURE_REPORT_PATH }}
95
+ report_dir : ${{ env.ALLURE_REPORT_FOLDER }}
94
96
95
97
- name : Git push to gh-pages
96
98
uses : mgrybyk/git-commit-pull-push-action@v1
@@ -105,7 +107,7 @@ jobs:
105
107
with :
106
108
message : |
107
109
${{ steps.allure.outputs.test_result_icon }} [Test Report](${{ steps.allure.outputs.report_url }}) | ${\color{lightgreen}Pass: ${{ steps.allure.outputs.test_result_passed }}/${{ steps.allure.outputs.test_result_total }}}$ | ${\color{red}Fail: ${{ steps.allure.outputs.test_result_failed }}/${{ steps.allure.outputs.test_result_total }}}$ |
108
- mode : upsert
110
+ comment-tag : test_report
109
111
110
112
generate-coverage-report :
111
113
name : Generate coverage report
@@ -120,35 +122,21 @@ jobs:
120
122
121
123
- name : Collect coverage report
122
124
run : |
123
- mkdir -p ${{ env.COVERAGE_REPORT_PATH }}
125
+ mkdir -p ${{ env.COVERAGE_REPORT_FOLDER }}
124
126
shopt -s globstar
125
- cp **/*${{ env.COVERAGE_EXT }} ${{ env.COVERAGE_REPORT_PATH }}
126
- ls ${{ env.COVERAGE_REPORT_PATH }}
127
+ cp **/*${{ env.COVERAGE_EXT }} ${{ env.COVERAGE_REPORT_FOLDER }}
128
+ ls ${{ env.COVERAGE_REPORT_FOLDER }}
127
129
128
130
- name : Normalize coverage report paths
129
131
run : |
130
- sed -i -e 's/SF:\/root\/build/SF:rust/g' ${{ env.COVERAGE_REPORT_PATH }}/cat-libs.coverage.info
132
+ sed -i -e 's/SF:\/root\/build/SF:rust/g' ${{ env.COVERAGE_REPORT_FOLDER }}/cat-libs${{ env.COVERAGE_EXT }}
131
133
132
134
- name : Coveralls
133
135
env :
134
136
GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
135
137
uses : coverallsapp/github-action@v2
136
138
with :
137
- path-to-lcov : " ${{ env.COVERAGE_REPORT_PATH }}/cat-libs.coverage.info "
139
+ path-to-lcov : " ${{ env.COVERAGE_REPORT_FOLDER }}/cat-libs${{ env.COVERAGE_EXT }} "
138
140
allow-empty : true
139
141
debug : true
140
142
flag-name : rust-unit-test
141
- base-path : " /home/runner/work/catalyst-libs/catalyst-libs/"
142
- parallel : true
143
-
144
- upload-coverage-report :
145
- name : Upload coverage report
146
- needs : [generate-coverage-report]
147
- if : ${{ always() }}
148
- runs-on : ubuntu-latest
149
- steps :
150
- - name : Coveralls Finished
151
- uses : coverallsapp/github-action@v2
152
- with :
153
- parallel-finished : true
154
- carryforward : " rust-unit-test"
0 commit comments