forked from scipy/scipy
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
161 lines (161 loc) · 5.25 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
# After changing this file, check it on:
# http://lint.travis-ci.org/
language: python
sudo: false
matrix:
include:
- python: 2.7
env:
- PYFLAKES=1
- PEP8=1
- NUMPYSPEC=numpy
before_install:
- pip install pep8==1.5.1
- pip install pyflakes
script:
- PYFLAKES_NODOCTEST=1 pyflakes scipy benchmarks/benchmarks | grep -E -v 'unable to detect undefined names|assigned to but never used|imported but unused|redefinition of unused' > test.out; cat test.out; test \! -s test.out
- pep8 scipy benchmarks/benchmarks
- python: 2.7
env:
- TESTMODE=fast
- REFGUIDE_CHECK=1
- COVERAGE=
- NPY_RELAXED_STRIDES_CHECKING=1
- NUMPYSPEC="--upgrade git+git://github.com/numpy/[email protected]"
addons:
apt:
packages:
- libatlas-dev
- libatlas-base-dev
- liblapack-dev
- gfortran
- libgmp-dev
- libmpfr-dev
- ccache
- libfreetype6-dev
- libpng-dev
- zlib1g-dev
- texlive-fonts-recommended
- python: 3.5
env:
- TESTMODE=fast
- COVERAGE=
- NUMPYSPEC=numpy
- USE_WHEEL=1
- python: 3.4
env:
- TESTMODE=fast
- COVERAGE=
- NUMPYSPEC=numpy
- python: 3.3
env:
- TESTMODE=fast
- COVERAGE=
- NUMPYSPEC=numpy
- python: 3.2
env:
- TESTMODE=fast
- COVERAGE=
- NUMPYSPEC=numpy
- python: 2.7
env:
- TESTMODE=full
- COVERAGE=--coverage
- NUMPYSPEC=numpy
- python: 2.6
env:
- TESTMODE=fast
- OPTIMIZE=-OO
- NUMPYSPEC="numpy==1.6.2"
addons:
apt:
packages:
- libatlas-dev
- libatlas-base-dev
- liblapack-dev
- gfortran
- libgmp-dev
- libmpfr-dev
- ccache
cache:
directories:
- $HOME/.ccache
before_install:
- export PATH=/usr/lib/ccache:$PATH
- uname -a
- free -m
- df -h
- ulimit -a
- mkdir builds
- pushd builds
# Install gmpy2 dependencies
- mkdir -p $HOME/.local
- wget ftp://ftp.gnu.org/gnu/mpc/mpc-1.0.2.tar.gz
- tar xzvf mpc-1.0.2.tar.gz
- pushd mpc-1.0.2
- ./configure --prefix=$HOME/.local
- make
- make install
- popd
- export CPATH=$HOME/.local/include
- export LIBRARY_PATH=$HOME/.local/lib
# End install gmpy2 dependencies
# Speed up install by not compiling Cython
- travis_retry pip install --install-option="--no-cython-compile" Cython==0.22
- travis_retry pip install $NUMPYSPEC
- travis_retry pip install nose mpmath argparse Pillow
- travis_retry pip install gmpy2 # speeds up mpmath (scipy.special tests)
- if [ "${TESTMODE}" == "full" ]; then pip install coverage; fi
- if [ "${USE_WHEEL}" == "1" ]; then pip install wheel; fi
- |
if [ "${REFGUIDE_CHECK}" == "1" ]; then
travis_retry pip install matplotlib Sphinx==1.2.3
fi
- python -V
- popd
- set -o pipefail
script:
- python -c 'import numpy as np; print("relaxed strides checking:", np.ones((10,1),order="C").flags.f_contiguous)'
# Make sure that relaxed strides checking is actually in effect; otherwise fail loudly
- if [ "$NPY_RELAXED_STRIDES_CHECKING" == "1" ]; then python -c'import numpy as np; assert np.ones((10,1),order="C").flags.f_contiguous'; fi
- |
if [ "${USE_WHEEL}" == "1" ]; then
# Need verbose output or TravisCI will terminate after 10 minutes
pip wheel . -v
pip install wheelhouse/* -v
USE_WHEEL_BUILD="--no-build"
fi
- python -u $OPTIMIZE runtests.py -g -m $TESTMODE $COVERAGE $USE_WHEEL_BUILD |& tee runtests.log
- tools/validate_runtests_log.py $TESTMODE < runtests.log
- if [ "${REFGUIDE_CHECK}" == "1" ]; then python runtests.py -g --refguide-check; fi
after_success:
# Upload development docs, using deploy key from travis-ci encrypted file
# https://developer.github.com/guides/managing-deploy-keys/
# http://docs.travis-ci.com/user/encrypting-files/
- |
if [ "${REFGUIDE_CHECK}" == "1" -a "${TRAVIS_PULL_REQUEST}" == "false" -a "${TRAVIS_BRANCH}" == "master" ]; then
set -e
openssl aes-256-cbc -K $encrypted_35a522e29e4d_key -iv $encrypted_35a522e29e4d_iv -in tools/ci/devdocs-deploy.key.enc -out tools/ci/devdocs-deploy.key -d
chmod 600 tools/ci/devdocs-deploy.key
eval `ssh-agent -s`
ssh-add tools/ci/devdocs-deploy.key
git clone [email protected]:scipy/devdocs.git devdocs
python -u $OPTIMIZE runtests.py -g --shell -- -c 'make -C doc html-scipyorg'
pushd devdocs
(git checkout --orphan tmp && git branch -D gh-pages || true)
git checkout --orphan gh-pages
git reset --hard
cp -R ../doc/build/html-scipyorg/. .
touch .nojekyll
git config --global user.email "scipy-travis-bot@nomail"
git config --global user.name "scipy-travis-bot"
git config --global push.default simple
git add . > /dev/null
git commit -m "Docs build of $TRAVIS_COMMIT"
git push --set-upstream origin gh-pages --force
popd
fi
notifications:
# Perhaps we should have status emails sent to the mailing list, but
# let's wait to see what people think before turning that on.
email: false