-
-
Notifications
You must be signed in to change notification settings - Fork 2
/
azure-pipelines.yml
51 lines (49 loc) · 1.22 KB
/
azure-pipelines.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
variables:
buildConfiguration: 'Release'
netSdkVersion: '8.x'
jobs:
- job: BuildAndRunCodeAnalysis
displayName: Build and run code analysis
pool:
vmImage: windows-latest
steps:
- task: UseDotNet@2
displayName: Set up .NET SDK
inputs:
version: $(netSdkVersion)
- task: DotNetCoreCLI@2
displayName: Build solution with code analysis
inputs:
command: build
projects: '*.sln'
arguments: -c $(buildConfiguration) -warnaserror
- job: RunTests
displayName: Run tests on
strategy:
matrix:
Linux:
imageName: 'ubuntu-latest'
macOS:
imageName: 'macOS-latest'
Windows:
imageName: 'windows-latest'
pool:
vmImage: $(imageName)
steps:
- task: UseDotNet@2
displayName: Set up .NET SDK
inputs:
version: $(netSdkVersion)
- task: DotNetCoreCLI@2
displayName: Build solution
inputs:
command: build
projects: '*.sln'
arguments: -c $(buildConfiguration) -p:RunCodeAnalysis=false
- task: DotNetCoreCLI@2
displayName: Run tests
timeoutInMinutes: 15
inputs:
command: test
projects: 'test/*/*Tests.csproj'
arguments: -c $(buildConfiguration) -s "azure-pipelines.runsettings" --no-build