forked from poliastro/poliastro
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
80 lines (67 loc) · 1.93 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
# The only current way of using OS X virtual machines in Travis CI
# is setting up a generic environment
# This is not a problem because Python will be installed through conda
language: python
branches:
only:
- master
- 0.3.x
- 0.4.x
- 0.5.x
- 0.6.x
- 0.7.x
- 0.8.x
env:
global:
- MPLBACKEND="Agg"
- RUN_MYPY="true"
- RUN_NTB="false"
matrix:
include:
- os: osx
language: generic
- os: linux
python: 3.5
- os: linux
python: 3.6
- os: linux
python: pypy3
env: PIP_EXTRA_INDEX_URL=https://antocuni.github.io/pypy-wheels/ubuntu/ RUN_MYPY="false"
- os: linux
python: 3.6
env: RUN_NTB="true"
allow_failures:
- python: pypy3
- env: RUN_NTB="true"
addons:
apt:
packages:
- pandoc
- libatlas-dev
- libblas-dev
- liblapack-dev
before_install:
- if [[ $TRAVIS_OS_NAME == 'osx' ]]; then HOMEBREW_NO_AUTO_UPDATE=1 brew install python3; fi
- if [[ $TRAVIS_OS_NAME == 'osx' ]]; then python3 -m venv venv; fi
- if [[ $TRAVIS_OS_NAME == 'osx' ]]; then source venv/bin/activate; fi
- if [[ $TRAVIS_OS_NAME == 'osx' ]]; then python3 -m pip install --upgrade pip; fi
- if [[ $RUN_MYPY == 'true' ]]; then pip install mypy; fi
install:
- pip install numpy # Required
- pip install . # Test installation correctness
- pip install .[dev] # Test development dependencies
before_script:
- pycodestyle setup.py src/ # Check PEP8 compliance
- if [[ $RUN_MYPY == 'true' ]]; then mypy --ignore-missing-imports --check-untyped-defs src/; fi
script:
- pytest -vv # Test against installed code
- if [[ $RUN_NTB == 'true' ]]; then sphinx-build -vW -b html docs/source _HTMLTest; fi # Test docs build
after_success:
# Uninstall to test coverage against sources
- pip uninstall poliastro -y
- pip install -e .
- NUMBA_DISABLE_JIT=1 pytest --cov
# Publish coverage
- pip install codecov
- codecov
sudo: false