File tree Expand file tree Collapse file tree 1 file changed +52
-0
lines changed
Expand file tree Collapse file tree 1 file changed +52
-0
lines changed Original file line number Diff line number Diff line change 1+ # ###########################################################################
2+ #
3+ # Workflow Description:
4+ # Upload the testing coverage reports to Codacy.
5+ #
6+ # Workflow input parameters:
7+ # * General arguments:
8+ # * download_path: The path to download testing coverage reports via 'actions/download-artifact@v3'.
9+ #
10+ # * Secret arguments:
11+ # * codacy_token: The API token for uploading testing coverage report to Codacy.
12+ #
13+ # Workflow running output:
14+ # No and do nothing.
15+ #
16+ # ###########################################################################
17+
18+ name : Upload code detail report to Codacy
19+
20+ on :
21+ workflow_call :
22+ inputs :
23+ download_path :
24+ description : " The path to download testing coverage reports via 'actions/download-artifact@v3'."
25+ required : true
26+ type : string
27+
28+ secrets :
29+ codacy_token :
30+ description : " The API token for uploading testing coverage report to Codacy."
31+ required : true
32+
33+
34+ jobs :
35+ upload_code_to_codacy_check_quality :
36+ runs-on : ubuntu-latest
37+ steps :
38+ - name : Download testing coverage report
39+ uses : actions/download-artifact@v3
40+ with :
41+ name : project_coverage_report
42+ path : ${{ inputs.download_path }}
43+
44+ - name : Generate testing report for Codacy
45+ run : mv ./coverage.xml ./cobertura.xml
46+
47+ - name : Upload testing report to Codacy
48+ uses : codacy/codacy-coverage-reporter-action@v1
49+ with :
50+ project-token : ${{ secrets.codacy_token }}
51+ coverage-reports : cobertura.xml
52+
You can’t perform that action at this time.
0 commit comments