forked from astropy/pyvo
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
109 lines (87 loc) · 3.05 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
# We set the language to c because python isn't supported on the MacOS X nodes
# on Travis. However, the language ends up being irrelevant anyway, since we
# install Python ourselves using conda.
language: c
os:
- linux
# Setting sudo to false opts in to Travis-CI container-based builds.
sudo: false
# The apt packages below are needed for sphinx builds. A full list of packages
# that can be included can be found here:
#
# https://github.com/travis-ci/apt-package-whitelist/blob/master/ubuntu-precise
addons:
apt:
packages:
- graphviz
stage: Comprehensive tests
stages:
# Do the style check and a single test job, don't proceed if it fails
- name: Initial tests
# Test docs, astropy dev, and without optional dependencies
- name: Comprehensive tests
# Leaving windows to the last stage
- name: Windows test
# These will only run when cron is opted in
- name: Cron tests
if: type = cron
env:
global:
# The following versions are the 'default' for tests, unless
# overridden underneath. They are defined here in order to save having
# to repeat them for all configurations.
- PYTHON_VERSION=3.7
- NUMPY_VERSION=stable
- ASTROPY_VERSION=stable
- MAIN_CMD='python setup.py'
- SETUP_CMD='test'
- PIP_DEPENDENCIES='requests mimeparse requests_mock'
- EVENT_TYPE='pull_request push'
- CONDA_CHANNELS='astropy'
matrix:
# Don't wait for allowed failures
fast_finish: true
include:
# Make sure that egg_info works without dependencies
- env: PYTHON_VERSION=3.6 SETUP_CMD='egg_info'
stage: Initial tests
# Try MacOS X
- os: osx
stage: Cron tests
env: SETUP_CMD='test'
# Do a coverage test.
- os: linux
stage: Initial tests
env: SETUP_CMD='test --coverage'
# Now try Astropy dev and LTS vesions with the latest 3.x.
- os: linux
env: ASTROPY_VERSION=development
EVENT_TYPE='pull_request push cron'
- os: linux
env: ASTROPY_VERSION=lts
# try all python versions
- os: linux
env: PYTHON_VERSION=3.6 NUMPY_VERSION=1.15
PIP_DEPENDENCIES='requests mimeparse requests_mock contextlib2'
- os: linux
env: PYTHON_VERSION=3.5 NUMPY_VERSION=1.14
# Do a PEP8 test with flake8
- os: linux
stage: Initial tests
env: MAIN_CMD='flake8' SETUP_CMD=''
# Check for sphinx doc build warnings
- os: linux
env: SETUP_CMD='build_docs -w'
PIP_DEPENDENCIES='requests mimeparse requests_mock sphinx_astropy'
# Try on windows. Since it takes longer, only run after everything passes
- os: windows
stage: Windows test
install:
- git clone git://github.com/astropy/ci-helpers.git
- source ci-helpers/travis/setup_conda.sh
script:
- $MAIN_CMD $SETUP_CMD
after_success:
- if [[ $SETUP_CMD == 'test --coverage' ]]; then
codecov;
fi