This repository has been archived by the owner on Sep 24, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 22
/
.travis.yml
55 lines (48 loc) · 1.64 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
language: python
sudo: false
env:
global:
- secure: "DdUE82IkNYo317595sy4H6z3GQoaVUTAAUDOOoJATa199ERxSQy8VlsMKELdRTrBEt76kSBJdjjJ7YSiOVSMt9qao9XWOWYjtfdX0KpbkmfiHMH6fmQnckNndMbPY8wa42fFusIWOxZL/jCay1Gq0GppjoHdSoaLGIk3hLkYE1U="
addons:
apt:
packages: octave
matrix:
fast_finish: true
include:
- python: 2.7
env: TEST_TARGET=default NUMPY=1.11
- python: 2.7
env: TEST_TARGET=default NUMPY=1.12
- python: 3.6
env: TEST_TARGET=default NUMPY=1.11
- python: 3.6
env: TEST_TARGET=default NUMPY=1.12
- python: 3.6
env: TEST_TARGET=publish NUMPY=1.12
allow_failures:
- python: 3.6
env: TEST_TARGET=publish NUMPY=1.12
before_install:
- wget http://bit.ly/miniconda -O miniconda.sh
- bash miniconda.sh -b -p $HOME/miniconda
- export PATH="$HOME/miniconda/bin:$PATH"
- conda update conda --yes
- conda config --add channels conda-forge --force
- conda create --yes -n TEST python=$TRAVIS_PYTHON_VERSION --file requirements-dev.txt
- source activate TEST
# Install after to ensure it will be downgraded when testing an older version.
- conda install --yes --quiet numpy=$NUMPY
- if [[ "$TRAVIS_PYTHON_VERSION" == "3.6" ]]; then
conda install --yes doctr ;
fi
# Test source distribution.
install:
- python setup.py sdist && version=$(python setup.py --version) && pushd dist && pip install gsw-${version}.tar.gz && popd
script:
- if [[ $TEST_TARGET == "default" ]]; then
py.test -vv ;
fi
- if [[ $TEST_TARGET == "publish" ]]; then
pushd docs && make html && popd ;
doctr deploy --built-docs=docs/_build/html --gh-pages-docs . ;
fi