This repository has been archived by the owner on Jan 25, 2023. It is now read-only.
forked from aboutcode-org/scancode-toolkit
-
Notifications
You must be signed in to change notification settings - Fork 0
/
azure-pipelines.yml
403 lines (354 loc) · 15.3 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
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
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
jobs:
################################################################################
# These jobs are using VMs and Azure-provided Pythons 2.7
################################################################################
- template: etc/ci/azure-linux.yml
parameters:
job_name: vm_ubuntu16_py27
image_name: ubuntu-16.04
python_versions: ['2.7']
test_suites:
misc: |
bin/py.test -n 2 -vvs --reruns=3 --test-suite=all \
--ignore=tests/scancode \
--ignore=tests/cluecode \
--ignore=tests/licensedcode \
--cov=src --cov-report=term --cov-report=xml
bin/codecov --token "$CODECOV_TOKEN"
scancode: |
bin/py.test --reruns=3 -vvs --test-suite=all \
tests/scancode \
--cov=src --cov-report=term --cov-report=xml
bin/codecov --token "$CODECOV_TOKEN"
cluecode: |
bin/py.test -n 2 --reruns=3 -vvs --test-suite=all \
tests/cluecode \
--cov=src --cov-report=term --cov-report=xml
bin/codecov --token "$CODECOV_TOKEN"
license_base: |
bin/py.test -n 2 --reruns=3 -vvs --test-suite=all \
--ignore=tests/licensedcode/test_zzzz_cache.py \
--ignore=tests/licensedcode/test_detection_datadriven1.py \
--ignore=tests/licensedcode/test_detection_datadriven2.py \
tests/licensedcode \
--cov=src --cov-report=term --cov-report=xml
bin/codecov --token "$CODECOV_TOKEN"
license_datadriven1: |
bin/py.test -n 2 --reruns=3 -vvs --test-suite=all \
tests/licensedcode/test_detection_datadriven1.py \
--cov=src --cov-report=term --cov-report=xml
bin/codecov --token "$CODECOV_TOKEN"
license_datadriven2: |
bin/py.test -n 2 --reruns=3 -vvs --test-suite=all \
tests/licensedcode/test_detection_datadriven2.py \
--cov=src --cov-report=term --cov-report=xml
bin/codecov --token "$CODECOV_TOKEN"
license_cache: |
bin/py.test -n 2 --reruns=3 -vvs --test-suite=all \
tests/licensedcode/test_zzzz_cache.py \
--cov=src --cov-report=term --cov-report=xml
bin/codecov --token "$CODECOV_TOKEN"
plugins-scancode-fingerprint: |
bin/pip install -e plugins/scancode-fingerprint
bin/py.test -vvs plugins/scancode-fingerprint/tests/
bin/codecov --token "$CODECOV_TOKEN"
plugins-scancode-compiledcode: |
bin/pip install -e plugins/scancode-dwarfdump-manylinux1_x86_64
bin/pip install -e plugins/scancode-ctags-manylinux1_x86_64
bin/pip install -e plugins/scancode-readelf-manylinux1_x86_64
bin/pip install -e plugins/scancode-compiledcode
bin/py.test -vvs plugins/scancode-compiledcode/tests/
- template: etc/ci/azure-win.yml
parameters:
job_name: Win2016_32_py27
image_name: vs2017-win2016
python_versions: ['2.7']
python_architecture: x86
test_suites:
misc: Scripts\py.test -vvs --reruns=3 --ignore=tests\scancode --ignore=tests\cluecode --ignore=tests\licensedcode
scancode: Scripts\py.test -vvs --reruns=3 tests\scancode
lic_cluecode: Scripts\py.test -vvs --reruns=3 tests\cluecode tests\licensedcode
- template: etc/ci/azure-mac.yml
parameters:
job_name: macos1013_py27
image_name: macos-10.13
python_versions: ['2.7']
test_suites:
all: bin/py.test -n 2 -vvs --reruns=3 --ignore=tests/scancode
scancode: bin/py.test -vvs --reruns=3 tests/scancode
- template: etc/ci/azure-mac.yml
parameters:
job_name: macos1014_py27
image_name: macos-10.14
python_versions: ['2.7']
test_suites:
all: bin/py.test -n 2 -vvs --reruns=3 --ignore=tests/scancode
scancode: bin/py.test -vvs --reruns=3 tests/scancode
################################################################################
# These jobs are using containers and their own Python 2.7
################################################################################
# - template: etc/ci/azure-container-deb.yml
# parameters:
# job_name: ubuntu16_py27
# container: ubuntu:xenial
# python_path: python2.7
# python_version: '2.7'
# install_python: sudo apt-get install -y python python-dev
# test_suite_label: all
# test_suite: bin/py.test -n 2 -vvs --reruns=3
- template: etc/ci/azure-container-deb.yml
parameters:
job_name: ubuntu18_py27
container: 'ubuntu:bionic'
python_path: python2.7
python_version: '2.7'
install_python: sudo apt-get install -y python python-dev
test_suite_label: all
test_suite: bin/py.test -n 2 -vvs --reruns=3
# - template: etc/ci/azure-container-rpm.yml
# parameters:
# job_name: centos7_py27
# container: centos:7
# python_path: python2.7
# python_version: '2.7'
# install_python: sudo yum install -y python python27-devel
# test_suite_label: all
# test_suite: bin/py.test -n 2 -vvs --reruns=3
#
# - template: etc/ci/azure-container-rpm.yml
# parameters:
# job_name: manylinux1_py27
# container: quay.io/pypa/manylinux1_x86_64:latest
# python_path: /opt/python/cp27-cp27mu/bin/python
# python_version: '2.7'
# install_packages: echo "No extra packages for now"
# install_python: echo "Python is pre-installed"
# test_suite_label: all
# test_suite: bin/py.test -n 2 -vvs --reruns=3
#
# - template: etc/ci/azure-container-rpm.yml
# parameters:
# job_name: manylinux2010_py27
# container: quay.io/pypa/manylinux2010_x86_64:latest
# python_path: /opt/python/cp27-cp27mu/bin/python
# python_version: '2.7'
# install_packages: echo "No extra packages for now"
# install_python: echo "Python is pre-installed"
# test_suite_label: all
# test_suite: bin/py.test -n 2 -vvs --reruns=3
#
# - template: etc/ci/azure-container-rpm.yml
# parameters:
# job_name: fedora30_py27
# container: fedora:30
# package_manager: dnf
# python_path: python2.7
# python_version: '2.7'
# install_python: |
# set -e -x
# sudo dnf install -y python2 python2-devel
# test_suite_label: all
# test_suite: bin/py.test -n 2 -vvs --reruns=3
#
# - template: etc/ci/azure-container-deb.yml
# parameters:
# job_name: debian9_py27
# container: debian:stretch
# python_path: python2.7
# python_version: '2.7'
# install_python: sudo apt-get install -y python python-dev
# test_suite_label: all
# test_suite: bin/py.test -n 2 -vvs --reruns=3
########################################################################
# RELEASE on 2.7
########################################################################
- job: Build_release_archive_py2
pool:
vmImage: ubuntu-16.04
steps:
- checkout: self
fetchDepth: 10
- task: UsePythonVersion@0
inputs:
versionSpec: '2.7'
displayName: 'Install Python 2.7'
- script: ./etc/release/release.sh
displayName: 'Build installable releases'
########################################################################
# RELEASE on 3.6. Also check that we can pip install
########################################################################
- job: Build_release_archive_py3
pool:
vmImage: ubuntu-16.04
steps:
- checkout: self
fetchDepth: 10
- task: UsePythonVersion@0
inputs:
versionSpec: '3.6'
displayName: 'Install Python 3.6'
- script: ./etc/release/release.sh
displayName: 'Build installable releases'
- script: ./etc/release/pip-install.sh
displayName: 'Test pip installation'
################################################################################
# These jobs are using VMs and Azure-provided Pythons 3.6
################################################################################
- template: etc/ci/azure-linux.yml
parameters:
job_name: vm_ubuntu16_py36
image_name: ubuntu-16.04
python_versions: ['3.6']
test_suites:
all: bin/py.test -n 2 -vvs --reruns=3
- template: etc/ci/azure-mac.yml
parameters:
job_name: macos_1013_py36
image_name: macos-10.13
python_versions: ['3.6']
test_suites:
all: bin/py.test -n 2 -vvs --reruns=3
- template: etc/ci/azure-mac.yml
parameters:
job_name: macos1014_py36
image_name: macos-10.14
python_versions: ['3.6']
test_suites:
all: bin/py.test -n 2 -vvs --reruns=3
- template: etc/ci/azure-win.yml
parameters:
job_name: Win2016_32_py36
image_name: vs2017-win2016
python_versions: ['3.6']
python_architecture: x86
test_suites:
misc: Scripts\py.test -vvs --reruns=3 --ignore=tests\scancode --ignore=tests\cluecode --ignore=tests\licensedcode
scancode: Scripts\py.test -vvs --reruns=3 tests\scancode
lic_cluecode: Scripts\py.test -vvs --reruns=3 tests\cluecode tests\licensedcode
################################################################################
# These jobs are using containers and their own Python 3.6
################################################################################
- template: etc/ci/azure-container-deb.yml
parameters:
job_name: ubuntu16_py36
container: ubuntu:xenial
python_path: python3.6
python_version: '3.6'
install_python: |
sudo apt-get -y install software-properties-common
sudo add-apt-repository -y ppa:deadsnakes
sudo apt-get -y update
sudo apt-get install -y python3.6 python3.6-venv python3.6-dev
test_suite_label: all
test_suite: bin/py.test -n 2 -vvs --reruns=3
- template: etc/ci/azure-container-deb.yml
parameters:
job_name: ubuntu18_py36
container: ubuntu:bionic
python_path: python3.6
python_version: '3.6'
install_python: sudo apt-get install -y python3.6 python3.6-venv python3.6-dev
test_suite_label: all
test_suite: bin/py.test -n 2 -vvs --reruns=3
# - template: etc/ci/azure-container-rpm.yml
# parameters:
# job_name: centos7_py36
# container: centos:7
# python_path: python3.6
# python_version: '3.6'
# install_python: |
# set -e -x
# sudo yum install -y epel-release
# sudo yum install -y python36 python36-devel python36-virtualenv
# test_suite_label: all
# test_suite: bin/py.test -n 2 -vvs --reruns=3
#
# - template: etc/ci/azure-container-rpm.yml
# parameters:
# job_name: manylinux1_py36
# container: quay.io/pypa/manylinux1_x86_64:latest
# python_path: /opt/python/cp36-cp36m/bin/python
# python_version: '3.6'
# install_packages: echo "No extra packages for now"
# install_python: echo "Python is pre-installed"
# test_suite_label: all
# test_suite: bin/py.test -n 2 -vvs --reruns=3
#
# - template: etc/ci/azure-container-rpm.yml
# parameters:
# job_name: manylinux2010_py36
# container: quay.io/pypa/manylinux2010_x86_64:latest
# python_path: /opt/python/cp36-cp36m/bin/python
# python_version: '3.6'
# install_packages: echo "No extra packages for now"
# install_python: echo "Python is pre-installed"
# test_suite_label: all
# test_suite: bin/py.test -n 2 -vvs --reruns=3
#
################################################################################
# These jobs are using containers and their own Python 3.7
################################################################################
# - template: etc/ci/azure-container-rpm.yml
# parameters:
# job_name: fedora30_py37
# container: fedora:30
# package_manager: dnf
# python_path: python3.7
# python_version: '3.7'
# install_python: |
# set -e -x
# sudo dnf install -y python3 python3-devel python3-virtualenv
# test_suite_label: all
# test_suite: bin/py.test -n 2 -vvs --reruns=3
#
# - template: etc/ci/azure-container-rpm.yml
# parameters:
# job_name: manylinux2010_py37
# container: quay.io/pypa/manylinux2010_x86_64:latest
# python_path: /opt/python/cp37-cp37m/bin/python
# python_version: '3.7'
# install_packages: echo "No extra packages for now"
# install_python: echo "Python is pre-installed"
# test_suite_label: all
# test_suite: bin/py.test -n 2 -vvs --reruns=3
################################################################################
# These jobs are using containers and their own Python 3.6: FAILING FOR NOW
################################################################################
# here we build from sources
# - template: etc/ci/azure-container-deb.yml
# parameters:
# job_name: debian9_py36
# container: debian:stretch
# python_path: python3.6
# python_version: '3.6'
# install_python: |
# set -e -x
# sudo apt-get install -y \
# libncurses5-dev libncursesw5-dev libreadline6-dev \
# libdb-dev libgdbm-dev libsqlite3-dev libssl-dev \
# libbz2-dev libexpat1-dev liblzma-dev zlib1g-dev \
# libcurl4-openssl-dev libpam0g-dev \
# libsqlite3-dev tk-dev libffi-dev \
# curl
# export PYVER=3.6.8
# curl -o Python-$PYVER.tgz https://www.python.org/ftp/python/$PYVER/Python-$PYVER.tgz
# tar -xvf Python-$PYVER.tgz
# cd Python-$PYVER
# ./configure --enable-optimizations
# make -j8
# sudo make altinstall
# test_suite_label: basic tests
# test_suite: bin/py.test -n 2 -vvs --reruns=3
################################################################################
# Misc: we do not support yet Windows 64
################################################################################
#
# - template: etc/ci/azure-win.yml
# parameters:
# job_name: Win2016_64
# image_name: vs2017-win2016
# python_versions: ['2.7', '3.6']
# python_architecture: x64
# test_suites:
# all: Scripts\py.test -n 2 -vvs --ignore=tests\scancode
# scancode: Scripts\py.test -vvs tests\scancode