/
.travis.yml
75 lines (64 loc) · 1.99 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
dist: trusty
language: python
python:
- "2.7"
- "3.5"
branches:
only:
- master
- beta
- develop
# Hold off testing feature & bugfix branches in case this competes w/other testing.
# - /^feature-.*$/
# - /^bugfix-.*$/
env:
global:
- NOSEOPTS_DEFAULT="-v --with-timer --with-id --rednose"
- NOSEOPTS_PARALLEL="--processes=-1 --process-timeout=2400" # timeout after 40 minutes (travis job timeout is 50 minutes)
- NOSEOPTS_ALL="$NOSEOPTS_DEFAULT $NOSEOPTS_PARALLEL"
matrix:
- NOSETESTS="drivers objects" NOSEOPTS=$NOSEOPTS_ALL # first in build mx because long duration
- NOSETESTS="algorithms" NOSEOPTS=$NOSEOPTS_ALL
- NOSETESTS="algorithmsb" NOSEOPTS=$NOSEOPTS_ALL
- NOSETESTS="tools iotest optimize construction extras" NOSEOPTS=$NOSEOPTS_ALL
- NOSETESTS="report" NOSEOPTS=$NOSEOPTS_ALL
- NOSETESTS="reportb" NOSEOPTS=$NOSEOPTS_ALL
- NOSETESTS="mpi" NOSEOPTS=$NOSEOPTS_DEFAULT # cannot be run in parallel
# Install native package dependencies & initialize build environment
before_install:
- >
sudo apt-get update -qq -y &&
sudo apt-get install -qq -y
gfortran libblas-dev liblapack-dev openmpi-bin openmpi-common openssh-client
openssh-server libopenmpi1.6 libopenmpi1.6-dbg libopenmpi-dev
libsuitesparse-dev
- export DISPLAY=:99.0
- /bin/sh -e /etc/init.d/xvfb start && sleep 3 # some tests require a display
- cmake --version
- gcc --version
# Install python package dependencies
install:
- pip install -e .[travisci]
# Default `test' stage script
script:
- cd test/test_packages
- nosetests $NOSEOPTS $NOSETESTS
# Cache pip packages
cache:
pip: true
timeout: 1000
stages:
- test
- name: deploy # only run deployment for master & develop branches
if: branch IN (master, develop)
jobs:
include:
- stage: deploy
python: 3.5
env: NOSETESTS=none NOSEOPTS=$NOSEOPTS_DEFAULT
install: skip
script: python CI/deploy
notifications:
email:
on_success: change
on_failure: always