forked from desihub/desidatamodel
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
85 lines (73 loc) · 2.47 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
#
# IMPORTANT. OS X support is so experimental that you have to specifically
# request to have it enabled, on a per-repository basis. See
# http://docs.travis-ci.com/user/multi-os/#Manual-intervention-required
#
# This file will still work, without OS X enabled, it just won't run those
# tests.
#
language: python
os:
- linux
# - osx
# Setting sudo to false opts in to Travis-CI container-based builds.
sudo: false
# The apt packages below are needed for sphinx builds, which can no longer
# be installed with sudo apt-get.
addons:
apt:
packages:
- graphviz
- texlive-latex-extra
- dvipng
python:
- 2.7
- 3.3
- 3.4
- 3.5
env:
global:
# The following versions are the 'default' for tests, unless
# overidden underneath. They are defined here in order to save having
# to repeat them for all configurations.
- MAIN_CMD='python setup.py'
matrix:
- SETUP_CMD='test'
matrix:
# Don't wait for allowed failures.
fast_finish: true
# OS X support is still experimental, so don't penalize failuures.
allow_failures:
- os: osx
include:
# Check for sphinx doc build warnings - we do this first because it
# runs for a long time
- os: linux
python: 2.7
env: SETUP_CMD='build_sphinx'
# -w is an astropy extension
# Do a bdist_egg compile. This will catch things like errors in the
# overall package structure.
- os: linux
python: 2.7
env: SETUP_CMD='bdist_egg'
# Coverage test, pass the results to coveralls.
- os: linux
python: 2.7
env: SETUP_CMD='test --coverage'
# env: MAIN_CMD='coverage' SETUP_CMD='run py/desidatamodel/test/desidatamodel_test_suite.py'
# PEP 8 compliance.
# - os: linux
# python: 2.7
# env: MAIN_CMD='pep8' SETUP_CMD='--count py/desidatamodel'
install:
- if [[ $MAIN_CMD == 'pep8' ]]; then pip install pep8; fi
- if [[ $SETUP_CMD == 'build_sphinx' ]]; then pip install Sphinx; fi
# - if [[ $MAIN_CMD == 'coverage' ]]; then pip install coverage coveralls; fi
- if [[ $SETUP_CMD == 'test --coverage' ]]; then pip install coverage coveralls; fi
- pip install -r requirements.txt
script:
- $MAIN_CMD $SETUP_CMD
after_success:
# - if [[ $MAIN_CMD == 'coverage' ]]; then coveralls; fi
- if [[ $SETUP_CMD == 'test --coverage' ]]; then coveralls; fi