-
Notifications
You must be signed in to change notification settings - Fork 2
/
.travis.yml
80 lines (75 loc) · 2.43 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
# https://travis-ci.org/obspy/vcr
language: c
matrix:
include:
- os: linux
env: PYTHON_VERSION=2.7
- os: linux
env: PYTHON_VERSION=3.3
- os: linux
env: PYTHON_VERSION=3.4
- os: linux
env: PYTHON_VERSION=3.5 PYTHON_ARCH=32
addons:
apt:
packages:
# https://github.com/travis-ci/apt-package-whitelist/blob/master/ubuntu-precise
- libstdc++6:i386
- gcc-multilib
- os: linux
env: PYTHON_VERSION=3.5 PYTHON_ARCH=64
- os: linux
env: PYTHON_VERSION=3.6
- os: osx
env: PYTHON_VERSION=2.7
- os: osx
env: PYTHON_VERSION=3.3
- os: osx
env: PYTHON_VERSION=3.4
- os: osx
env: PYTHON_VERSION=3.5
- os: osx
env: PYTHON_VERSION=3.6
install:
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then
export OS="MacOSX";
else
export OS="Linux";
fi
- |
if [[ "$PYTHON_ARCH" == 32 ]]; then
export ARCH=""
# OPT is used by setuptools patches contained in newer numpy versions
# used by obspy when running pip install --no-deps .
export OPT="-m32"
# workaround for sudo dpkg --add-architecture i386
# be sure multiarch is the only file in this directory
ls /etc/dpkg/dpkg.cfg.d/
# multiarch must contain foreign-architecture i386. If not it will
# error later and you need to do the following and add sudo: true
#sudo sh -c "echo 'foreign-architecture i386' > /etc/dpkg/dpkg.cfg.d/multiarch"
cat /etc/dpkg/dpkg.cfg.d/multiarch
else
export ARCH="_64"
fi
- if [[ "${PYTHON_VERSION:0:1}" == '2' ]]; then
wget https://repo.continuum.io/miniconda/Miniconda2-latest-${OS}-x86${ARCH}.sh -O miniconda.sh;
else
wget https://repo.continuum.io/miniconda/Miniconda3-latest-${OS}-x86${ARCH}.sh -O miniconda.sh;
fi
- bash miniconda.sh -b -p $HOME/miniconda
- export PATH="$HOME/miniconda/bin:$PATH"
- hash -r
- conda config --set always_yes yes --set changeps1 no
- conda update -q conda
- conda create -q -n test-environment python=$PYTHON_VERSION
- source activate test-environment
script:
- pip install -r requirements.txt
- pip install -r requirements_test.txt
# Check that we have the expected version and architecture for Python
- "python --version"
- "python -c \"import struct; print(struct.calcsize('P') * 8)\""
- python setup.py test
notifications:
email: false