-
Notifications
You must be signed in to change notification settings - Fork 1
37 lines (33 loc) · 949 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
name: CI
on:
push:
branches: ["main"]
pull_request:
branches: ["main"]
env:
SOLUTION_PATH: src/Our.Umbraco.InvisibleNodes.sln
NUGET_PACKAGES: ${{ github.workspace }}/.nuget/packages
jobs:
build:
runs-on: windows-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Setup .NET
uses: actions/setup-dotnet@v3
with:
dotnet-version: |
6.x
- name: Cache NuGet Packages
uses: actions/cache@v3
with:
path: ${{ github.workspace }}/.nuget/packages
key: ${{ runner.os }}-nuget-${{ hashFiles('**/packages.lock.json') }}
restore-keys: |
${{ runner.os }}-nuget-
- name: Restore
run: dotnet restore --locked-mode ${{ env.SOLUTION_PATH }}
- name: Build
run: dotnet build --no-restore ${{ env.SOLUTION_PATH }}
- name: Test
run: dotnet test --no-build --verbosity normal ${{ env.SOLUTION_PATH }}