-
-
Notifications
You must be signed in to change notification settings - Fork 0
54 lines (47 loc) · 1.49 KB
/
Copy pathci.yml
File metadata and controls
54 lines (47 loc) · 1.49 KB
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
46
47
48
49
50
51
52
53
54
name: CI
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
test:
name: Test (.NET ${{ matrix.dotnet-version }})
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
dotnet-version:
- '8.0' # LTS - supported until November 2026
- '9.0' # STS - supported until May 2026
- '10.0' # LTS - latest
steps:
- name: Checkout
uses: actions/checkout@v6
- name: Setup .NET (all versions for multi-targeting)
uses: actions/setup-dotnet@v5
with:
dotnet-version: |
8.0
9.0
10.0
- name: Restore
run: dotnet restore src/NetFramework.Task.Management.sln
- name: Build
run: dotnet build src/NetFramework.Task.Management.sln --configuration Release --no-restore
- name: Test on .NET ${{ matrix.dotnet-version }}
run: |
dotnet test src/NetFramework.Tasks.Management.xUnit.Tests/ \
--configuration Release \
--no-build \
--framework net${{ matrix.dotnet-version }} \
--logger "console;verbosity=normal" \
--collect:"XPlat Code Coverage" \
--results-directory ./coverage
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v6
with:
token: ${{ secrets.CODECOV_TOKEN }}
directory: ./coverage
flags: net${{ matrix.dotnet-version }}
fail_ci_if_error: false