@@ -1,42 +1,47 @@
3# explicitly request container-based infrastructure
1# explicitly request container-based infrastructure
8− - env: CABALVER=1.16 GHCVER=7.6.3
6+ - env: GHCVER=7.8.4 STACK_YAML=stack-7.8.yaml
9− addons: {apt: {packages: [cabal-install-1.16,ghc-7.6.3,happy-1.18.10], sources: [hvr-ghc]}}
7+ addons:
10− - env: CABALVER=1.18 GHCVER=7.8.4
8+ apt:
11− addons: {apt: {packages: [cabal-install-1.18,ghc-7.8.4,happy-1.19.4], sources: [hvr-ghc]}}
9+ sources:
12− - env: CABALVER=1.22 GHCVER=7.10.2
13+ - env: GHCVER=7.10.2 STACK_YAML=stack.yaml
13− addons: {apt: {packages: [cabal-install-1.22,ghc-7.10.2,happy-1.19.5],sources: [hvr-ghc]}}
14+ addons:
14− - env: CABALVER=head GHCVER=head
15+ apt:
15− addons: {apt: {packages: [cabal-install-head,ghc-head,happy-head], sources: [hvr-ghc]}}
16+ sources:
20+ - env: GHCVER=head STACK_YAML=stack-head.yaml
17 allow_failures:
27 allow_failures:
18− - env: CABALVER=head GHCVER=head
28+ - env: GHCVER=head STACK_YAML=stack-head.yaml
20before_install:
34before_install:
21− - export PATH=/opt/ghc/$GHCVER/bin:/opt/cabal/$CABALVER/bin:$PATH
36+ - export PATH=/opt/ghc/$GHCVER/bin:$PATH
38+ - mkdir -p ~/.local/bin
39+ - export PATH=~/.local/bin:$PATH
40+ - travis_retry curl -L https://www.stackage.org/stack/linux-x86_64 | tar xz --wildcards --strip-components=1 -C ~/.local/bin '*/stack'
24− - cabal --version
43+ - stack --no-terminal --skip-ghc-check setup
25− - echo "$(ghc --version) [$(ghc --print-project-git-commit-id 2> /dev/null || echo '?')]"
44+ - stack --no-terminal --skip-ghc-check test --only-snapshot
26− - travis_retry cabal update
27− - cabal install --only-dependencies --enable-tests --enable-benchmarks
29−# Here starts the actual work to be performed for the package under test; any command which exits with a non-zero exit code causes the build to fail.
31− - if [ -f configure.ac ]; then autoreconf -i; fi
47+ - stack --no-terminal --skip-ghc-check test
32− - cabal configure --enable-tests --enable-benchmarks -v2 # -v2 provides useful information for debugging
33− - cabal build # this builds all libraries and executables (including tests/benchmarks)
36− - cabal sdist # tests that a source-distribution can be generated
38−# Check that the resulting source distribution can be built & installed.
39−# If there are no other `.tar.gz` files in `dist`, this can be even simpler:
40−# `cabal install --force-reinstalls dist/*-*.tar.gz`
41− - SRC_TGZ=$(cabal info . | awk '{print $2;exit}').tar.gz &&
42− (cd dist && cabal install --force-reinstalls "$SRC_TGZ")