forked from AzureAD/microsoft-identity-web
-
Notifications
You must be signed in to change notification settings - Fork 0
/
azure-pipelines.yml
45 lines (43 loc) · 1.14 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
trigger:
- master
pr:
autoCancel: true
branches:
include:
- master
jobs:
- job: "Sonar"
pool:
vmImage: 'windows-latest'
demands:
- msbuild
steps:
- template: build/template-install-dotnet-core.yaml
- template: build/template-install-keyvault-secrets.yaml
- task: SonarCloudPrepare@1
inputs:
SonarCloud: 'SonarCloud-microsoft_identity_web'
organization: 'azuread'
scannerMode: 'MSBuild'
projectKey: 'AzureAD_microsoft-identity-web'
projectName: 'microsoft-identity-web'
extraProperties: |
sonar.exclusions=tests\**
- task: DotNetCoreCLI@2
inputs:
projects: 'Microsoft.Identity.Web.sln'
command: 'restore'
- task: VSBuild@1
inputs:
solution: Microsoft.Identity.Web.sln
vsVersion: '16.0'
- task: DotNetCoreCLI@2
displayName: 'Run unit tests'
inputs:
command: test
projects: 'tests/**/Microsoft.Identity.Web.Test*.csproj'
arguments: '--collect "Code coverage"'
- task: SonarCloudAnalyze@1
- task: SonarCloudPublish@1
inputs:
pollingTimeoutSec: '300'