forked from astropy/sphinx-automodapi
-
Notifications
You must be signed in to change notification settings - Fork 0
/
azure-template.yml
58 lines (48 loc) · 1.72 KB
/
azure-template.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
jobs:
- job: ${{ format(parameters.name) }}
pool:
${{ if eq(parameters.os, 'macosx') }}:
vmImage: 'macOS-latest'
${{ if eq(parameters.os, 'linux') }}:
vmImage: 'ubuntu-latest'
${{ if eq(parameters.os, 'windows') }}:
vmImage: 'vs2017-win2016'
steps:
- ${{ if eq(parameters.os, 'macosx') }}:
- script: brew install graphviz
displayName: Installing graphviz
- ${{ if eq(parameters.os, 'linux') }}:
- script: sudo apt-get install -y graphviz
displayName: Installing graphviz
- ${{ if eq(parameters.os, 'windows') }}:
- script: choco install graphviz vcpython27 curl codecov --no-progress
displayName: Installing graphviz, vcpython27, curl, and codecov
- task: UsePythonVersion@0
inputs:
versionSpec: '2.7'
architecture: 'x64'
- task: UsePythonVersion@0
inputs:
versionSpec: '3.5'
architecture: 'x64'
- task: UsePythonVersion@0
inputs:
versionSpec: '3.6'
architecture: 'x64'
- task: UsePythonVersion@0
inputs:
versionSpec: '3.7'
architecture: 'x64'
- script: pip install tox "coverage<5.0"
displayName: Installing tox and coverage
- script: tox
displayName: Running tests with tox
- bash: coverage combine .tmp/*/.coverage
displayName: Combining coverage results
- bash: coverage report
displayName: Show coverage
# As described in https://github.com/codecov/codecov-bash/issues/189, the
# official bash script doesn't use the correct variable names for pull
# requests, so we use a fork of the bash script for now.
- bash: bash <(curl https://raw.githubusercontent.com/astrofrog/codecov-bash/fixed-azure/codecov) -t $(codecov.token)
displayName: Uploading results to codecov