forked from JuliaPy/pyjulia
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
91 lines (87 loc) · 2.72 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
language: python
os:
- linux
python:
- "2.7"
- "3.6"
env:
matrix:
- JULIA_VERSION=0.6.4 CROSS_VERSION=1
- JULIA_VERSION=1.0
- JULIA_VERSION=nightly
global:
- TOXENV=py
- PYJULIA_TEST_INCOMPATIBLE_PYTHONS=/usr/bin/python2
matrix:
# Python environment is not functional on OS X
include:
- language: generic
env:
- PYTHON=python2
- JULIA_VERSION=1.0
# - JULIA_VERSION=nightly
os: osx
- language: generic
env:
- PYTHON=python2
- JULIA_VERSION=0.6.4
- CROSS_VERSION=1
os: osx
- language: generic
env:
- PYTHON=python3
- PYJULIA_TEST_INCOMPATIBLE_PYTHONS=python2
- JULIA_VERSION=1.0
# - JULIA_VERSION=nightly
os: osx
- language: generic
env:
- PYTHON=python3
- PYJULIA_TEST_INCOMPATIBLE_PYTHONS=python2
- JULIA_VERSION=0.6.4
- CROSS_VERSION=1
os: osx
allow_failures:
- env: JULIA_VERSION=nightly
branches:
only:
- master
notifications:
email: false
before_script:
- echo ./ci/install-julia.sh "$JULIA_VERSION"
- ./ci/install-julia.sh "$JULIA_VERSION"
- if [ "$TRAVIS_OS_NAME" = "osx" -a "$PYTHON" = "python3" ]; then brew update; brew upgrade python || echo "Ignoring errors..."; fi
- if [ "$TRAVIS_OS_NAME" = "osx" -a "$PYTHON" = "python2" ]; then brew update; brew list python@2 &>/dev/null || brew install python@2 || echo "Ignoring errors..."; fi
# Ignoring errors from brew since it may actually be OK to do so.
# Following which command will catch installation failure:
- PYTHON=${PYTHON:-python}
- which $PYTHON
- $PYTHON -m pip --version
- $PYTHON -m pip install --quiet tox coveralls
- julia --color=yes -e 'VERSION >= v"0.7.0-DEV.5183" && using Pkg; Pkg.add("PyCall")'
script:
# Point PYJULIA_TEST_INCOMPATIBLE_PYTHONS to incompatible Python
# executable (see: test/test_compatible_exe.py).
- if [ "$PYJULIA_TEST_INCOMPATIBLE_PYTHONS" = "$PYTHON" ]; then
PYJULIA_TEST_INCOMPATIBLE_PYTHONS="";
elif ! which "$PYJULIA_TEST_INCOMPATIBLE_PYTHONS"; then
PYJULIA_TEST_INCOMPATIBLE_PYTHONS="";
fi
- echo "$PYJULIA_TEST_INCOMPATIBLE_PYTHONS"
# "py,py27" below would be redundant when the main interpreter is
# Python 2.7 but it simplifies the CI setup.
- if [ "$CROSS_VERSION" = "1" ]; then
$PYTHON -m tox -e py,py27;
fi
- if [ "$CROSS_VERSION" = "1" ]; then
cat .tox/py/log/pytest.log;
fi
- if [ "$CROSS_VERSION" = "1" ]; then
cat .tox/py27/log/pytest.log;
fi
- PYJULIA_TEST_REBUILD=yes $PYTHON -m tox -- --cov=julia
- cat .tox/py/log/pytest.log
after_success:
- .tox/py/bin/coverage combine .coverage
- coveralls