-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.pr-pipeline.yml
72 lines (63 loc) · 1.69 KB
/
.pr-pipeline.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
62
63
64
65
66
67
68
69
70
71
# https://docs.microsoft.com/azure/devops/pipelines/languages/python
trigger: none
pr:
- master
- dev
stages:
- stage: Check
jobs:
- job: Tests
pool:
vmImage: 'Ubuntu-16.04'
strategy:
matrix:
Python37:
python.version: '3.7'
steps:
- template: .use-python.yml
- script: pytest tests.py
displayName: 'Test'
- job: Typings
pool:
vmImage: 'Ubuntu-16.04'
strategy:
matrix:
Python37:
python.version: '3.7'
steps:
- template: .use-python.yml
- script: mypy package_index.py
displayName: 'Check typings'
- job: Version
pool:
vmImage: 'Ubuntu-16.04'
strategy:
matrix:
Python37:
python.version: '3.7'
steps:
- template: .use-python.yml
- script: cv package_index
displayName: 'Check version changed'
- stage: Report
jobs:
- job: TestCoverage
pool:
vmImage: 'Ubuntu-16.04'
strategy:
matrix:
Python37:
python.version: '3.7'
steps:
- template: .use-python.yml
- script: git checkout $(System.PullRequest.SourceBranch)
displayName: 'Checkout branch'
- script: pytest tests.py --cov=package_index --cov-report=html
displayName: 'Test with coverage'
- script: coveralls
displayName: 'Save code coverage'
env:
COVERALLS_REPO_TOKEN: $(COVERALLS_REPO_TOKEN)
dependsOn:
- Check
condition: succeeded('Check')