-
Notifications
You must be signed in to change notification settings - Fork 45
/
.azure_pipeline.yml
115 lines (105 loc) · 3.35 KB
/
.azure_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
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
jobs:
- job: linting
displayName: Linting
pool:
vmImage: ubuntu-latest
steps:
- task: UsePythonVersion@0
inputs:
versionSpec: '3.9'
- bash: |
# Include pytest compatibility with mypy
pip install black==22.3
displayName: Install linters
- bash: |
black --check --diff .
displayName: Run black
- job: 'test_loky'
strategy:
matrix:
windows-py311:
imageName: windows-latest
python.version: "3.11"
tox.env: py311
windows-py38:
imageName: windows-latest
python.version: "3.8"
tox.env: py38
macos-py311:
imageName: "macos-latest"
python.version: "3.11"
tox.env: py311
macos-py38:
imageName: "macos-latest"
python.version: "3.8"
tox.env: py38
linux-pypy3:
imageName: "ubuntu-latest"
python.version: "pypy3"
tox.env: pypy3
LOKY_MAX_CPU_COUNT: "2"
linux-py311:
imageName: "ubuntu-latest"
python.version: "3.11"
tox.env: py311
linux-py39-joblib-tests:
imageName: "ubuntu-latest"
python.version: "3.9"
tox.env: "py39"
joblib.tests: "true"
linux-python-py39-high-memory:
imageName: "ubuntu-latest"
python.version: "3.9"
tox.env: py39
RUN_MEMORY: "true"
linux-py38:
imageName: "ubuntu-latest"
python.version: "3.8"
tox.env: py38
linux-py37:
imageName: "ubuntu-latest"
python.version: "3.7"
tox.env: py37
pool:
vmImage: $(imageName)
variables:
JUNITXML: 'test-data.xml'
PYTEST_ARGS: '-vl --timeout=60 --maxfail=5'
steps:
- task: UsePythonVersion@0
inputs:
versionSpec: '$(python.version)'
displayName: 'Use Python $(python.version)'
condition: ne(variables['python.version'], 'pypy3')
- bash: |
wget -q https://downloads.python.org/pypy/pypy3.7-v7.3.7-linux64.tar.bz2 -O pypy.tar.bz2
mkdir -p pypy3
(cd pypy3; tar --strip-components=1 -xf ../pypy.tar.bz2)
mv pypy3 /opt/pypy37
/opt/pypy37/bin/pypy3 -m ensurepip
/opt/pypy37/bin/pypy3 -m pip install --upgrade pip wheel
/opt/pypy37/bin/pypy3 -m venv pypy-venv
echo "##vso[task.prependpath]pypy-venv/bin"
displayName: 'Install PyPy 3.7'
condition: eq(variables['python.version'], 'pypy3')
# azure-pipelines unpredictably switches between Git\bin\bash and
# Git\usr\bin\bash when running a bash script inside Windows environments.
# The latter may use wrong bash commands, resulting in errors when codecov
# tries to upload the coverage results.
- bash: echo "##vso[task.prependpath]C:/Program Files/Git/bin"
displayName: 'Override Git bash shell for Windows'
condition: eq(variables['Agent.OS'], 'Windows_NT')
- script: python -m pip install --upgrade tox
displayName: 'Install tox'
- script: |
bash continuous_integration/runtests.sh
displayName: 'Test loky'
- task: PublishTestResults@2
inputs:
testResultsFiles: '$(JUNITXML)'
displayName: 'Publish Test Results'
condition: succeededOrFailed()
- bash: |
curl -s https://codecov.io/bash | bash
displayName: 'Upload to codecov'
condition: and(succeeded(), ne(variables['joblib.tests'], 'true'))