File tree Expand file tree Collapse file tree 1 file changed +28
-2
lines changed
Expand file tree Collapse file tree 1 file changed +28
-2
lines changed Original file line number Diff line number Diff line change 1111 - name : Checkout code
1212 uses : actions/checkout@v4
1313
14+ - name : Setup .NET
15+ uses : actions/setup-dotnet@v3
16+ with :
17+ dotnet-version : ' 8.0.x'
18+
1419 - name : Build project
20+ working-directory : src
1521 run : dotnet build --configuration Release
1622
17- - name : Run tests
18- run : dotnet test --configuration Release
23+ - name : Run tests with coverage
24+ working-directory : src
25+ run : dotnet test --configuration Release --collect:"XPlat Code Coverage" --results-directory ./coverage
26+
27+ - name : Generate coverage report
28+ uses :
danielpalme/[email protected] 29+ with :
30+ reports : ' coverage/**/coverage.cobertura.xml'
31+ targetdir : ' coverage-report'
32+ reporttypes : ' Html;Cobertura'
33+
34+ - name : Upload coverage to Codecov
35+ uses : codecov/codecov-action@v3
36+ with :
37+ files : ./coverage/**/coverage.cobertura.xml
38+ fail_ci_if_error : false
39+
40+ - name : Publish coverage report as artifact
41+ uses : actions/upload-artifact@v3
42+ with :
43+ name : coverage-report
44+ path : coverage-report/
You can’t perform that action at this time.
0 commit comments