-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy path.travis.yml
60 lines (55 loc) · 2.86 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
env:
- GHCVER=7.6.3 CABALVER=1.18 JOBQUEUE_TEST_BACKEND="sqlite3://test.sqlite3" MONAD_CONTROL_VERSION="<= 0.3.3.0"
- GHCVER=7.6.3 CABALVER=1.18 JOBQUEUE_TEST_BACKEND="zookeeper://localhost:2181" MONAD_CONTROL_VERSION="<= 0.3.3.0"
- GHCVER=7.6.3 CABALVER=1.18 JOBQUEUE_TEST_BACKEND="sqlite3://test.sqlite3"
- GHCVER=7.6.3 CABALVER=1.18 JOBQUEUE_TEST_BACKEND="zookeeper://localhost:2181"
- GHCVER=7.8.2 CABALVER=1.18 JOBQUEUE_TEST_BACKEND="sqlite3://test.sqlite3"
- GHCVER=7.8.2 CABALVER=1.18 JOBQUEUE_TEST_BACKEND="zookeeper://localhost:2181"
- GHCVER=7.8.3 CABALVER=1.18 JOBQUEUE_TEST_BACKEND="sqlite3://test.sqlite3" MONAD_CONTROL_VERSION="<= 0.3.3.0"
- GHCVER=7.8.3 CABALVER=1.18 JOBQUEUE_TEST_BACKEND="zookeeper://localhost:2181" MONAD_CONTROL_VERSION="<= 0.3.3.0"
- GHCVER=7.8.3 CABALVER=1.18 JOBQUEUE_TEST_BACKEND="sqlite3://test.sqlite3"
- GHCVER=7.8.3 CABALVER=1.18 JOBQUEUE_TEST_BACKEND="zookeeper://localhost:2181"
- GHCVER=7.10.2 CABALVER=1.22 JOBQUEUE_TEST_BACKEND="sqlite3://test.sqlite3" MONAD_CONTROL_VERSION="<= 0.3.3.0"
- GHCVER=7.10.2 CABALVER=1.22 JOBQUEUE_TEST_BACKEND="zookeeper://localhost:2181" MONAD_CONTROL_VERSION="<= 0.3.3.0"
- GHCVER=7.10.2 CABALVER=1.22 JOBQUEUE_TEST_BACKEND="sqlite3://test.sqlite3"
- GHCVER=7.10.2 CABALVER=1.22 JOBQUEUE_TEST_BACKEND="zookeeper://localhost:2181"
before_install:
- travis_retry sudo add-apt-repository -y ppa:hvr/ghc
- travis_retry sudo apt-add-repository ppa:nikicat/zookeeper -y
- travis_retry sudo apt-get update
- travis_retry sudo apt-get install cabal-install-$CABALVER ghc-$GHCVER
- travis_retry sudo apt-get install libzookeeper-mt-dev
- travis_retry sudo apt-get install zookeeperd
- export PATH=$HOME/.cabal/bin:/opt/ghc/$GHCVER/bin:/opt/cabal/$CABALVER/bin:$PATH
- cd jobqueue
install:
- cabal update
- cabal sandbox init
- cabal install hpc-coveralls --bindir=$HOME/.cabal/bin/
- cabal sandbox delete
- cabal install happy
- cabal install 'double-conversion < 1'
- cabal install "monad-control ${MONAD_CONTROL_VERSION}"
- cabal install --only-dependencies --enable-tests --enable-benchmarks --extra-include-dirs=/usr/include/zookeeper
script:
- cabal configure --enable-tests --enable-benchmarks -v2 # -v2 provides useful information for debugging
- cabal build # this builds all libraries and executables (including tests/benchmarks)
- cabal test
- cat dist/test/*.log
- cabal check
- cabal sdist # tests that a source-distribution can be generated
- export SRC_TGZ=$(cabal-$CABALVER info . | awk '{print $2 ".tar.gz";exit}') ;
cd dist/;
if [ -f "$SRC_TGZ" ]; then
cabal install "$SRC_TGZ";
else
echo "expected '$SRC_TGZ' not found";
exit 1;
fi
after_script:
- cd ..
- cabal clean
- cabal configure --enable-tests -v2 --enable-library-coverage # -v2 provides useful information for debugging
- cabal build
- cabal test
- hpc-coveralls --exclude-dir=test test