-
Notifications
You must be signed in to change notification settings - Fork 295
/
.travis.yml
107 lines (96 loc) · 2.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
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
language: python
# Tell travis we want Ubuntu 14.04
sudo: required
services:
- docker
dist: trusty
notifications:
email: false
# with building pushes enabled on travis we would get
# two builds for every new commit pushed to a branch
# for a PR. So we disable build-on-push for all branches
# except the ones whitelisted here.
branches:
only:
- master
matrix:
fast_finish: true
include:
- os: linux
python: "3.4"
# Tell travis we want debian trusty
sudo: required
dist: trusty
env:
- TESTATTR="'not huge and not known_failing'"
addons:
apt:
packages:
- astyle
- cppcheck
- enchant
- os: linux
python: "3.5"
# Tell travis we want debian trusty
sudo: required
dist: trusty
env:
- TESTATTR="'not huge and not known_failing'"
addons:
apt:
packages:
- astyle
- cppcheck
- enchant
- os: linux
python: "3.6"
# Tell travis we want debian trusty
sudo: required
dist: trusty
env:
- TESTATTR="'not huge and not known_failing'"
addons:
apt:
packages:
- astyle
- cppcheck
- enchant
- os: osx
language: generic
osx_image: xcode7.3
env:
- TESTATTR="'not linux and not known_failing and not huge'"
before_install:
- source ci_scripts/install.sh
# command to install common dependencies
install:
- python --version
- which python
- gcc --version
- which gcc
- make install-dependencies
# command to run tests
script:
- make test
- make pep8
- make doc
- make py-demos
- make cpp-demos
- cd examples/stamps && ./do.sh
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then cd ../.. && COMMIT=${TRAVIS_PULL_REQUEST_SHA:-$TRAVIS_COMMIT} SLUG=${TRAVIS_PULL_REQUEST_SLUG:-"dib-lab/khmer"} make docker-container; fi
# generate all the diagnostic reports
after_success:
- cd $TRAVIS_BUILD_DIR && echo $TRAVIS_BUILD_DIR
- make clean
- PYTEST_ADDOPTS=-qqq make coverage-gcovr.xml coverage.xml
# Fix suggested by http://diff-cover.readthedocs.io/en/latest/#troubleshooting
- git fetch origin master:refs/remotes/origin/master
- PYTEST_ADDOPTS=-qqq make diff-cover
- make format
- make diff_pylint_report
- make cppcheck
- make pydocstyle
# only upload one coverage report to codecov as it merges all reports
# from all builds into one.
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then pip install codecov; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then codecov -X pycov search gcov -f coverage.xml coverage-gcovr.xml; fi