-
Notifications
You must be signed in to change notification settings - Fork 9
45 lines (38 loc) · 993 Bytes
/
ci.yaml
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: CI Workflow
on:
push:
branches:
- main
- dev
pull_request:
branches:
- main
- dev
types: [opened, edited, reopened, synchronize]
env:
NUGET_PACKAGES: ${{ github.workspace }}/.nuget/packages
jobs:
build-and-test:
name: Build and Test
strategy:
matrix:
dotnet-version: ["8.0.x", "6.0.x"]
os: ["ubuntu-latest", "windows-latest"]
runs-on: ${{matrix.os}}
steps:
- uses: actions/checkout@v4
name: Checkout
with:
fetch-depth: 0
- name: Setup dotnet ${{ matrix.dotnet-version }}
uses: actions/setup-dotnet@v4
with:
dotnet-version: ${{ matrix.dotnet-version }}
cache: true
cache-dependency-path: "**/packages.lock.json"
- name: Restore dependencies
run: dotnet restore --no-cache --disable-parallel --verbosity minimal
- name: Build
run: dotnet build
- name: Test
run: dotnet test