]> git.phdru.name Git - sqlconvert.git/blob - appveyor.yml
5c904d71277b6f2af444c9fca50c306e57ee1d9d
[sqlconvert.git] / appveyor.yml
1 # Test on windows
2 # Heavily inspired by Oliver Grisel's appveyor-demo (https://github.com/ogrisel/python-appveyor-demo)
3 version: '{branch}-{build}'
4
5 cache:
6   - '%LOCALAPPDATA%\pip\Cache'
7
8 # Match travis
9 clone_depth: 50
10
11 services:
12   - postgresql
13
14 environment:
15   PGUSER: "postgres"
16   PGPASSWORD: "Password12!"
17
18   matrix:
19     - TOXENV: "py27"
20       PYTHON_VERSION: "2.7"
21       PYTHON_ARCH: "32"
22       PYTHON_HOME: "C:\\Python27"
23     - TOXENV: "py37"
24       PYTHON_VERSION: "3.7"
25       PYTHON_ARCH: "64"
26       PYTHON_HOME: "C:\\Python37-x64"
27     - TOXENV: "py38"
28       PYTHON_VERSION: "3.8"
29       PYTHON_ARCH: "64"
30       PYTHON_HOME: "C:\\Python38-x64"
31     - TOXENV: "py39"
32       PYTHON_VERSION: "3.9"
33       PYTHON_ARCH: "32"
34       PYTHON_HOME: "C:\\Python39"
35       APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
36     - TOXENV: "py39"
37       PYTHON_VERSION: "3.9"
38       PYTHON_ARCH: "64"
39       PYTHON_HOME: "C:\\Python39-x64"
40       APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
41     - TOXENV: "py27-postgres-w32"
42       PYTHON_VERSION: "2.7"
43       PYTHON_ARCH: "32"
44       PYTHON_HOME: "C:\\Python27"
45       db: postgresql
46     - TOXENV: "py37-postgres-w32"
47       PYTHON_VERSION: "3.7"
48       PYTHON_ARCH: "64"
49       PYTHON_HOME: "C:\\Python37-x64"
50       db: postgresql
51     - TOXENV: "py38-postgres-w32"
52       PYTHON_VERSION: "3.8"
53       PYTHON_ARCH: "64"
54       PYTHON_HOME: "C:\\Python38-x64"
55       db: postgresql
56     - TOXENV: "py39-postgres-w32"
57       PYTHON_VERSION: "3.9"
58       PYTHON_ARCH: "32"
59       PYTHON_HOME: "C:\\Python39"
60       db: postgresql
61       APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
62     - TOXENV: "py39-postgres-w32"
63       PYTHON_VERSION: "3.9"
64       PYTHON_ARCH: "64"
65       PYTHON_HOME: "C:\\Python39-x64"
66       db: postgresql
67       APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
68     - TOXENV: "py27-sqlite-w32"
69       PYTHON_VERSION: "2.7"
70       PYTHON_ARCH: "32"
71       PYTHON_HOME: "C:\\Python27"
72     - TOXENV: "py37-sqlite-w32"
73       PYTHON_VERSION: "3.7"
74       PYTHON_ARCH: "64"
75       PYTHON_HOME: "C:\\Python37-x64"
76     - TOXENV: "py38-sqlite-w32"
77       PYTHON_VERSION: "3.8"
78       PYTHON_ARCH: "64"
79       PYTHON_HOME: "C:\\Python38-x64"
80     - TOXENV: "py39-sqlite-w32"
81       PYTHON_VERSION: "3.9"
82       PYTHON_ARCH: "32"
83       PYTHON_HOME: "C:\\Python39"
84       APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
85     - TOXENV: "py39-sqlite-w32"
86       PYTHON_VERSION: "3.9"
87       PYTHON_ARCH: "64"
88       PYTHON_HOME: "C:\\Python39-x64"
89       APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
90     - TOXENV: "py27-flake8"
91       PYTHON_VERSION: "2.7"
92       PYTHON_ARCH: "32"
93       PYTHON_HOME: "C:\\Python27"
94     - TOXENV: "py39-flake8"
95       PYTHON_VERSION: "3.9"
96       PYTHON_ARCH: "64"
97       PYTHON_HOME: "C:\\Python39-x64"
98
99 install:
100   # Ensure we use the right python version
101   - "SET PATH=%PYTHON_HOME%;%PYTHON_HOME%\\Scripts;C:\\Program Files\\PostgreSQL\\9.5\\bin;%PATH%"
102   - "SET TOXPYTHON=%PYTHON_HOME%\\python.exe"
103   - "python --version"
104   - "python -c \"import struct; print(struct.calcsize('P') * 8)\""
105   - "python -m pip install --upgrade \"pip<21\" \"setuptools<44\""
106   - "pip install --upgrade \"tox<3.1\" ppu"
107   - "pip --version"
108
109 # No build step - we don't have C extensions
110 build: false
111
112 test_script:
113   - "tox"
114
115 after_test:
116   - "remove-old-files.py -o 180 %LOCALAPPDATA%\\pip\\Cache"