26
26
uses : actions/checkout@v2
27
27
with :
28
28
fetch-depth : 0
29
- - name : Set UploadCoverageReport environment variable to true
30
- if : matrix.os == 'macos-latest'
31
- run : echo "UploadCoverageReport=true" >> $GITHUB_ENV
32
29
- name : Retrieve cached NuGet packages
33
30
uses : actions/cache@v2
34
31
with :
53
50
with :
54
51
name : TestResults-${{ runner.os }}
55
52
path : TestResults-${{ runner.os }}.html
53
+ - name : Upload coverage report to Codecov
54
+ if : matrix.os == 'macos-latest'
55
+ uses : codecov/codecov-action@v2
56
+ with :
57
+ files : ${{ steps.dotnet-test.outputs.coverage-reports }}
58
+ - name : Upload coverage report to Codacy
59
+ if : matrix.os == 'macos-latest'
60
+ uses : codacy/codacy-coverage-reporter-action@v1
61
+ with :
62
+ project-token : ${{ secrets.CODACY_PROJECT_TOKEN }}
63
+ coverage-reports : ${{ steps.dotnet-test.outputs.coverage-reports }}
56
64
- name : Run mutation tests and upload report to Stryker dashboard
57
65
if : matrix.os == 'macos-latest'
58
66
# Once https://github.com/stryker-mutator/stryker-net/pull/1663 is merged and Stryker.NET v1.0 is released
@@ -62,18 +70,12 @@ jobs:
62
70
cd tests
63
71
dotnet tool restore
64
72
dotnet tool run dotnet-stryker --reporters '["progress","dashboard"]' --dashboard-project github.com/serilog-contrib/serilog-formatting-log4net --dashboard-version ${GITHUB_REF#refs/heads/} --dashboard-api-key ${{ secrets.STRYKER_DASHBOARD_API_KEY }}
65
- - name : Upload coverage report to Codacy
66
- uses : codacy/codacy-coverage-reporter-action@v1
67
- if : matrix.os == 'macos-latest'
68
- with :
69
- project-token : ${{ secrets.CODACY_PROJECT_TOKEN }}
70
- coverage-reports : ${{ steps.dotnet-test.outputs.coverage-reports }}
71
73
- name : Create NuGet package
72
74
run : dotnet pack --no-build --output .
73
75
id : dotnet-pack
74
76
- name : Upload NuGet package artifact
75
- uses : actions/upload-artifact@v2
76
77
if : matrix.os == 'macos-latest'
78
+ uses : actions/upload-artifact@v2
77
79
with :
78
80
name : ${{ steps.dotnet-pack.outputs.nupkg-filename }}
79
81
path : ${{ steps.dotnet-pack.outputs.nupkg-filename }}
0 commit comments