-
-
Notifications
You must be signed in to change notification settings - Fork 1
45 lines (35 loc) · 984 Bytes
/
coverage.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
name: Code Coverage
on: [workflow_dispatch]
jobs:
build:
name: Build and Test
runs-on: windows-latest
steps:
- name: Checkout Tests
uses: actions/checkout@v4
- name: Setup .NET 9.0.x
uses: actions/setup-dotnet@v4
with:
dotnet-version: '9.0.x'
- name: Restore .NET Tools
run: dotnet tool restore
- name: Coverage All Tests
run: dotnet dotcover test --dcXML=Configuration.xml
- name: Save Report
uses: actions/upload-artifact@v4
with:
name: coverage-report
path: CoverageReport.xml
publish:
name: Publish Report
runs-on: ubuntu-latest
needs: build
steps:
- name: Load Report
uses: actions/download-artifact@v4
with:
name: coverage-report
- name: Send to Codacy
env:
CODACY_PROJECT_TOKEN: ${{ secrets.CODACY_PROJECT_TOKEN }}
run: bash <(curl -Ls https://coverage.codacy.com/get.sh) report -r CoverageReport.xml