blob: a9d2dfc686ba66ffd7abddf09899b7779e683583 (
plain)
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
|
image: Visual Studio 2017
shallow_clone: true
install:
- "set PATH=%PYTHON%;%PYTHON%\\Scripts;%PATH%"
- python --version
- pip install lxml
- pip install pypiwin32
- choco install dmd
- choco install ldc
- choco install swig
- choco install vswhere
environment:
matrix:
- PYTHON: "C:\\Python27"
BUILD_JOB_NUM: 1
- PYTHON: "C:\\Python27"
BUILD_JOB_NUM: 2
- PYTHON: "C:\\Python27"
BUILD_JOB_NUM: 3
- PYTHON: "C:\\Python27"
BUILD_JOB_NUM: 4
- PYTHON: "C:\\Python35"
BUILD_JOB_NUM: 1
- PYTHON: "C:\\Python35"
BUILD_JOB_NUM: 2
- PYTHON: "C:\\Python35"
BUILD_JOB_NUM: 3
- PYTHON: "C:\\Python35"
BUILD_JOB_NUM: 4
- PYTHON: "C:\\Python36"
BUILD_JOB_NUM: 1
- PYTHON: "C:\\Python36"
BUILD_JOB_NUM: 2
- PYTHON: "C:\\Python36"
BUILD_JOB_NUM: 3
- PYTHON: "C:\\Python36"
BUILD_JOB_NUM: 4
- PYTHON: "C:\\Python27-x64"
BUILD_JOB_NUM: 1
- PYTHON: "C:\\Python27-x64"
BUILD_JOB_NUM: 2
- PYTHON: "C:\\Python27-x64"
BUILD_JOB_NUM: 3
- PYTHON: "C:\\Python27-x64"
BUILD_JOB_NUM: 4
- PYTHON: "C:\\Python35-x64"
BUILD_JOB_NUM: 1
- PYTHON: "C:\\Python35-x64"
BUILD_JOB_NUM: 2
- PYTHON: "C:\\Python35-x64"
BUILD_JOB_NUM: 3
- PYTHON: "C:\\Python35-x64"
BUILD_JOB_NUM: 4
- PYTHON: "C:\\Python36-x64"
BUILD_JOB_NUM: 1
- PYTHON: "C:\\Python36-x64"
BUILD_JOB_NUM: 2
- PYTHON: "C:\\Python36-x64"
BUILD_JOB_NUM: 3
- PYTHON: "C:\\Python36-x64"
BUILD_JOB_NUM: 4
build: off
build_script:
- cmd: python runtest.py -l -a > all_tests.txt
- ps: >-
$TOTAL_BUILD_JOBS = 4;
$Lines = (Get-Content all_tests.txt | Measure-Object -line).Lines;
$start = ($Lines / $TOTAL_BUILD_JOBS) * ($Env:BUILD_JOB_NUM - 1);
$end = ($Lines / $TOTAL_BUILD_JOBS) * $Env:BUILD_JOB_NUM;
if ( $Env:BUILD_JOB_NUM -eq $TOTAL_BUILD_JOBS){ $end = $Lines };
if ( $start -eq 0 ){ $start = 1 };
get-content all_tests.txt | select -first ($end - $start) -skip ($start - 1) | Out-File -Encoding ASCII build_tests.txt;
- cmd: powershell -Command "& { python runtest.py -j 2 -f build_tests.txt; if($LastExitCode -eq 2 -Or $LastExitCode -eq 0) { $host.SetShouldExit(0 )} else {$host.SetShouldExit(1)}}"
|