forked from jakebeal/TASBEFlowAnalytics
-
Notifications
You must be signed in to change notification settings - Fork 8
/
Copy path.travis.yml
69 lines (64 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
# vim ft=yaml
# travis-ci.org definition for TASBEFlowAnalytics build (based on MOxUnit)
#
# This pretends to be java because it needs GNU Octave which is not
# available (as of April 2015)
language: java
services:
- xvfb
cache:
- apt
env:
global:
- OCTAVE=octave
matrix:
- WITH_COVERAGE=
# Disable until ready to go there:
#- WITH_COVERAGE=true
#- RUN_DOC_TEST=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 liboctave-dev
# install Octave io package
# Forge is unreliable: trying to get directly instead:
# - octave --no-gui --quiet --eval "pkg install -forge io"
# - wget -O io-2.4.10.tar.gz https://downloads.sourceforge.net/octave/io-2.4.10.tar.gz?download --no-check-certificate
- octave --no-gui --quiet --eval "pkg install matlab_compat/io-2.4.10.tar.gz"
# install MOxUnit
- cd ..
- rm -rf MOxUnit
- git clone https://github.com/MOxUnit/MOxUnit.git
- make -C MOxUnit install
# install MOcov
- rm -rf MOcov
- git clone https://github.com/MOcov/MOcov.git
- make -C MOcov install
# retrieve MOdox
- rm -rf MOdox
- travis_retry git clone -v git://github.com/MOdox/MOdox.git
- make -C MOdox install
# retrieve Tutorial for running tests
- rm -rf TASBEFlowAnalytics-Tutorial
- git clone --branch=master https://github.com/TASBE/TASBEFlowAnalytics-Tutorial
# go back to original directory
- cd TASBEFlowAnalytics
script:
- if [[ "$WITH_COVERAGE" == "true" ]]; then
TEST_ARGS=WITH_COVERAGE=true;
COVER_ARGS=COVER=`pwd`/TASBEFlowAnalytics;
if [[ "$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 [[ "$RUN_DOC_TEST" == "true" ]]; then
TEST_ARGS=RUN_DOC_TEST=true;
fi;
- echo Test arguments $TEST_ARGS $COVER_ARGS $OUTPUT_ARGS $RESULT_ARGS
- make test $TEST_ARGS $COVER_ARGS $OUTPUT_ARGS $RESULT_ARGS
- eval $AFTER_SCRIPT