Skip to content

Commit 5d28dcb

Browse files
committed
[appveyor.yml] update with support for Py3.7 builds
1 parent a986aef commit 5d28dcb

File tree

1 file changed

+37
-15
lines changed

1 file changed

+37
-15
lines changed

appveyor.yml

Lines changed: 37 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,41 @@
1-
build: false
21
environment:
32
matrix:
4-
- TOXENV: py35
5-
- TOXENV: py36
6-
- TOXENV: py37
7-
platform:
8-
- x86
9-
- x64
10-
init:
11-
- "ECHO %TOXENV%"
12-
- ps: "ls C:\\Python*"
3+
- JOB: "3.5 64-bit"
4+
PYTHON_HOME: "C:\\Python35-x64"
5+
6+
- JOB: "3.6 64-bit"
7+
PYTHON_HOME: "C:\\Python36-x64"
8+
9+
- JOB: "3.7 64-bit"
10+
PYTHON_HOME: "C:\\Python37-x64"
11+
12+
- JOB: "3.7 32-bit"
13+
PYTHON_HOME: "C:\\Python37"
14+
1315
install:
14-
- "c:\\python27\\Scripts\\pip install tox"
16+
# If there is a newer build queued for the same PR, cancel this one.
17+
# The AppVeyor 'rollout builds' option is supposed to serve the same
18+
# purpose but it is problematic because it tends to cancel builds pushed
19+
# directly to master instead of just PR builds (or the converse).
20+
# credits: JuliaLang developers.
21+
- ps: if ($env:APPVEYOR_PULL_REQUEST_NUMBER -and $env:APPVEYOR_BUILD_NUMBER -ne ((Invoke-RestMethod `
22+
https://ci.appveyor.com/api/projects/$env:APPVEYOR_ACCOUNT_NAME/$env:APPVEYOR_PROJECT_SLUG/history?recordsNumber=50).builds | `
23+
Where-Object pullRequestId -eq $env:APPVEYOR_PULL_REQUEST_NUMBER)[0].buildNumber) { `
24+
throw "There are newer queued builds for this pull request, failing early." }
25+
26+
# Prepend Python to the PATH of this build
27+
- "SET PATH=%PYTHON_HOME%;%PYTHON_HOME%\\Scripts;%PATH%"
28+
29+
# check that we have the expected version and architecture for Python
30+
- "python --version"
31+
- "python -c \"import struct; print(struct.calcsize('P') * 8)\""
32+
33+
# upgrade pip and setuptools to avoid out-of-date warnings
34+
- "python -m pip install --disable-pip-version-check --user --upgrade pip setuptools"
35+
36+
# install the test dependencies
37+
- "python -m pip install tox"
38+
1539
test_script:
16-
- "git clean -f -d -x"
17-
- "c:\\python27\\Scripts\\tox --version"
18-
- "c:\\python27\\Scripts\\pip --version"
19-
- "c:\\python27\\Scripts\\tox"
40+
# run tests
41+
- "tox"

0 commit comments

Comments
 (0)