forked from wafo-project/wafo
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
61 lines (56 loc) · 2.12 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
# vim ft=yaml
# travis-ci.org definition for WAFO build (based on MOxUnit which is based on CoSMoMVPA,
# which is based on PyMVPA, which is based on nipype configuration,
# which in turn was based on nipy)
#
# We pretend to be java because we need GNU Octave which is not
# available (as of April 2015)
language: java
cache:
- apt
env:
global:
- OCTAVE=octave
matrix:
- WITH_COVERAGE=
- WITH_COVERAGE=true
before_install:
# to prevent IPv6 being used for APT
- sudo bash -c "echo 'Acquire::ForceIPv4 \"true\";' > /etc/apt/apt.conf.d/99force-ipv4"
- travis_retry sudo apt-get -y -qq update
- travis_retry sudo apt-get install -y -qq software-properties-common python-software-properties
- travis_retry sudo apt-add-repository -y ppa:octave/stable
- travis_retry sudo apt-get -y -qq update
# get Octave 4,0
- travis_retry sudo apt-get -y -qq install octave
# install MOcov
- cd ..
- rm -rf MOcov
- git clone https://github.com/MOcov/MOcov.git
- make -C MOcov install
# install MOxUnit
- rm -rf MOxUnit
- git clone https://github.com/MOxUnit/MOxUnit.git
- make -C MOxUnit install
# go back to original directory
- cd wafo
# prevent shippable from re-using old test results
- if [[ "$SHIPPABLE" == "true" ]]; then
rm -f shippable/testresults/*.xml;
fi
script:
- if [[ "$WITH_COVERAGE" == "true" ]]; then
TEST_ARGS=WITH_COVERAGE=true;
COVER_ARGS=COVER=`pwd`/wafo;
if [[ "$SHIPPABLE" == "true" ]]; then
OUTPUT_ARGS=COVER_XML_FILE=shippable/codecoverage/coverage.xml;
elif [[ "$TRAVIS" == "true" ]]; then
OUTPUT_ARGS=COVER_JSON_FILE=`pwd`/coveralls.json;
AFTER_SCRIPT="curl --verbose -F json_file=@`pwd`/coveralls.json https://coveralls.io/api/v1/jobs";
fi;
elif [[ "$SHIPPABLE" == "true" ]]; then
RESULT_ARGS=JUNIT_XML_FILE=shippable/testresults/test_results.xml;
fi
- echo Test arguments $TEST_ARGS $COVER_ARGS $OUTPUT_ARGS $RESULT_ARGS
- make test $TEST_ARGS $COVER_ARGS $OUTPUT_ARGS $RESULT_ARGS
- $AFTER_SCRIPT