-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathazure-pipelines.yml
61 lines (49 loc) · 1.41 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
52
53
54
55
56
57
58
59
60
61
trigger:
- main
pr:
branches:
include:
- main
jobs:
- job: CI
workspace:
clean: all
pool:
name: nitsm-python-test
# py -3 indicates the latest python version installed on the system
steps:
- script: |
py -3 -m pip install --upgrade pip
displayName: 'Upgrade pip'
- script: |
py -3 -m pip install --upgrade tox
displayName: 'Install or upgrade tox'
- task: PowerShell@2
displayName: 'Switch to old TestStand/TSM'
inputs:
targetType: filePath
filePath: 'C:\Activate_TSVersion.ps1'
arguments: '-VersionToActivate old'
- script: |
tox -- older
displayName: 'Run python unit tests with older version of TestStand/TSM'
- task: PowerShell@2
displayName: 'Switch to new TestStand/TSM'
inputs:
targetType: filePath
filePath: 'C:\Activate_TSVersion.ps1'
arguments: '-VersionToActivate new'
- script: |
tox -- newer
displayName: 'Run python unit tests with newer version of TestStand/TSM'
- task: PublishTestResults@2
condition: succeededOrFailed()
inputs:
testResultsFiles: '**/*-results.xml'
testRunTitle: 'Publish test results'
displayName: 'Display test results'
- task: PublishCodeCoverageResults@1
inputs:
codeCoverageTool: Cobertura
summaryFileLocation: '$(System.DefaultWorkingDirectory)/**/coverage.xml'
displayName: 'Display code coverage results'