forked from castleproject/Core
-
Notifications
You must be signed in to change notification settings - Fork 0
58 lines (41 loc) · 1.31 KB
/
Copy pathbuild.yml
File metadata and controls
58 lines (41 loc) · 1.31 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
55
56
57
58
name: Build
on: [ push, pull_request ]
jobs:
build-and-test:
name: Build and test
strategy:
matrix:
os: [ ubuntu-latest, windows-latest, macos-latest ]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout repository
uses: actions/checkout@v6
# -----
# Setup .NET sdk
# -----
- name: Install .NET SDKs
uses: actions/setup-dotnet@v5
with:
dotnet-version: |
8.0.x
9.0.x
10.0.x
# -----
# Build
# -----
- name: Restore NuGet packages
run: dotnet restore
- name: Build all targets
run: dotnet build -c Release --no-restore
# ----
# Test
# ----
- name: Test on .NET 8
run: dotnet test -c Release -f net8.0 --no-build --no-restore -l "console;verbosity=detailed"
- name: Test on .NET 9
run: dotnet test -c Release -f net9.0 --no-build --no-restore -l "console;verbosity=detailed"
- name: Test on .NET 10
run: dotnet test -c Release -f net10.0 --no-build --no-restore -l "console;verbosity=detailed"
- name: Test on .NET Framework 4.6.2 (Windows only)
if: matrix.os == 'windows-latest'
run: dotnet test -c Release -f net462 --no-build --no-restore -l "console;verbosity=detailed"