-
Notifications
You must be signed in to change notification settings - Fork 30
/
.travis.yml
177 lines (164 loc) · 5.71 KB
/
.travis.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
language: python
dist: xenial
# only intended for Linux python3 jobs.
# Linux Python2.7 job, Windows jobs, and Mac jobs will overwrite
install: python3 -m pip install .[dev] codecov
# only intended for linux jobs. MacOS and Windows will use package entry "python[3] -m codecov"
after_success: codecov
before_cache:
- if [ "${TRAVIS_OS_NAME}" = "osx" ]; then brew cleanup; fi
jobs:
include:
# linux
- python: "3.8"
script: python3 -m tox -e py38 -- --cov-report=xml
- python: "3.7"
script: python3 -m tox -e py37 -- --cov-report=xml
- python: "3.6.9"
script: python3 -m tox -e py36 -- --cov-report=xml
- python: "3.5"
script: python3 -m tox -e py35 -- --cov-report=xml
- python: "2.7.17"
install: python -m pip install .[dev] codecov
script: python -m tox -e py27 -- --cov-report=xml
# osx python 3.8
- name: "Python: 3.8"
os: osx
osx_image: xcode11
language: shell
cache:
directories:
- $HOME/Library/Caches/Homebrew
- /usr/local/Homebrew
# switch to python 3.8
addons:
homebrew:
update: true
before_install:
- pyenv install 3.8-dev
- pyenv global 3.8-dev
- export PATH="/Users/travis/.pyenv/shims:${PATH}"
# end switch
install: python3 -m pip install --user .[dev] codecov
script: python3 -m tox -e py38 -- --cov-report=xml
after_success: python3 -m codecov
# osx python 3.7
- name: "Python: 3.7"
os: osx
# xcode 11 image comes with python 3.7
osx_image: xcode11
# language: python will error
language: shell
install: python3 -m pip install --user .[dev] codecov
script: python3 -m tox -e py37 -- --cov-report=xml
after_success: python3 -m codecov
# osx python 3.6.5
- name: "Python: 3.6.5"
os: osx
osx_image: xcode9.4 # Python 3.6.5 running on macOS 10.13
before_script: python3 --version
language: shell
install: python3 -m pip install --user .[dev] codecov
script: python3 -m tox -e py36 -- --cov-report=xml
after_success: python3 -m codecov
# osx python 3.5
- name: "Python: 3.5.7"
os: osx
osx_image: xcode11
cache:
directories:
- $HOME/Library/Caches/Homebrew
- /usr/local/Homebrew
language: shell
# switch to python 3.5
addons:
homebrew:
update: true
before_install:
- pyenv install 3.5.7
- pyenv global 3.5.7
- export PATH="/Users/travis/.pyenv/shims:${PATH}"
- python3 -m pip install --user --upgrade pip
- python3 -m pip install --user --upgrade setuptools
# end switch
install: python3 -m pip install --user .[dev] codecov
# for some reason tox cannot find python3.5. we have to use py instead of py35
script: python3 -m tox -e py35 -- --cov-report=xml
after_success: python3 -m codecov
# osx python 2.7.14
- name: "Python: 2.7.14"
os: osx
osx_image: xcode9.3 # Python 2.7.14_2 running on macOS 10.13
language: shell
before_install:
- python -m pip install --user --upgrade pip
- python -m pip install --user --upgrade setuptools
install: python -m pip install --user .[dev] codecov
script: python -m tox -e py27 -- --cov-report=xml
after_success: python -m codecov
# windows python 3.8
- name: "Python: 3.8"
os: windows
# language: python will error
language: shell
# install python 3.8
before_install:
- choco install python --version 3.8.0
- python -m pip install --upgrade pip
install: python -m pip install --user .[dev] codecov
# On Windows, python3 does not exist
script: python -m tox -e py38 -- --cov-report=xml
env: PATH=/c/Python38:/c/Python38/Scripts:$PATH
after_success: python -m codecov
# windows python 3.7
- name: "Python: 3.7"
os: windows
# language: python will error
language: shell
# install python 3.7
before_install:
- choco install python --version 3.7.4
- python -m pip install --upgrade pip
install: python -m pip install --user .[dev] codecov
# On Windows, python3 does not exist
script: python -m tox -e py37 -- --cov-report=xml
env: PATH=/c/Python37:/c/Python37/Scripts:$PATH
after_success: python -m codecov
# windows python 3.6
- name: "Python: 3.6"
os: windows
language: shell
before_install:
- choco install python --version 3.6.8
- python -m pip install --upgrade pip
install: python -m pip install --user .[dev] codecov
script: python -m tox -e py36 -- --cov-report=xml
env: PATH=/c/Python36:/c/Python36/Scripts:$PATH
after_success: python -m codecov
# 3.5 and 2.7 on Windows are temporally disabled
# cuz a timeout issue on travis builds
# see this issue: https://github.com/Madoshakalaka/pipenv-setup/issues/31
# # windows python 3.5
# - name: "Python: 3.5"
# os: windows
# language: shell
# before_install:
# - choco install python --version 3.5.4
# - python -m pip install --upgrade pip
# install: python -m pip install --user .[dev] codecov
# script: python -m tox -e py35 -- --cov-report=xml
# env: PATH=/c/Python35:/c/Python35/Scripts:$PATH
# after_success: python -m codecov
#
#
# # windows python 2.7
# - name: "Python: 2.7"
# os: windows
# language: shell
# before_install:
# - choco install python2
# - python -m pip install --upgrade pip
# install: python -m pip install --user .[dev] codecov
# script: python -m tox -e py27 -- --cov-report=xml
# env: PATH=/c/Python27:/c/Python27/Scripts:$PATH
# after_success: python -m codecov