-
Notifications
You must be signed in to change notification settings - Fork 1
/
CI.TeePee.Refit.yml
61 lines (52 loc) · 1.23 KB
/
CI.TeePee.Refit.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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
name: CI_$(date:yyyyMMdd)$(rev:.r)
trigger:
batch: true
paths:
include:
- TeePee.Refit/*
- CI.TeePee.Refit.yml
pr:
branches:
include:
- main
paths:
include:
- TeePee.Refit/*
- CI.TeePee.Refit.yml
pool:
vmImage: 'windows-latest'
variables:
solution: '**/TeePee.Refit.sln'
buildConfiguration: 'Release'
NUGET_PACKAGES: $(Pipeline.Workspace)/.nuget/packages
steps:
- task: UseDotNet@2
displayName: 'Use .NET 7'
inputs:
version: 7.x
- task: Cache@2
displayName: 'NuGet Pipeline Cache'
inputs:
key: 'nuget | "$(Agent.OS)" | TeePee.Refit/**/packages.lock.json,!**/bin/**,!**/obj/**'
restoreKeys: |
nuget | "$(Agent.OS)"
nuget
path: '$(NUGET_PACKAGES)'
- task: DotNetCoreCLI@2
displayName: 'Restore Solution'
inputs:
command: 'restore'
projects: '$(solution)'
arguments: '-c $(buildConfiguration)'
- task: DotNetCoreCLI@2
displayName: 'Build Solution'
inputs:
command: 'build'
projects: '$(solution)'
arguments: '-c $(buildConfiguration) --no-restore'
- task: DotNetCoreCLI@2
displayName: 'Unit Tests'
inputs:
command: 'test'
projects: 'TeePee.Refit/**/*[Tt]ests.csproj'
arguments: '-c $(buildConfiguration) --no-build'