Skip to content

Commit

Permalink
Better travis.ci
Browse files Browse the repository at this point in the history
  • Loading branch information
ondrap committed Dec 27, 2017
1 parent 0f34d14 commit 0a3b824
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 11 deletions.
22 changes: 12 additions & 10 deletions .travis.yml
Expand Up @@ -31,17 +31,17 @@ before_cache:
matrix:
include:
- compiler: "ghc-7.4.2"
addons: {apt: {packages: [ghc-ppa-tools,cabal-install-head,ghc-7.4.2], sources: [hvr-ghc]}}
addons: {apt: {packages: [ghc-ppa-tools,cabal-install-2.0,ghc-7.4.2], sources: [hvr-ghc]}}
- compiler: "ghc-7.6.3"
addons: {apt: {packages: [ghc-ppa-tools,cabal-install-head,ghc-7.6.3], sources: [hvr-ghc]}}
addons: {apt: {packages: [ghc-ppa-tools,cabal-install-2.0,ghc-7.6.3], sources: [hvr-ghc]}}
- compiler: "ghc-7.8.4"
addons: {apt: {packages: [ghc-ppa-tools,cabal-install-head,ghc-7.8.4], sources: [hvr-ghc]}}
addons: {apt: {packages: [ghc-ppa-tools,cabal-install-2.0,ghc-7.8.4], sources: [hvr-ghc]}}
- compiler: "ghc-7.10.3"
addons: {apt: {packages: [ghc-ppa-tools,cabal-install-head,ghc-7.10.3], sources: [hvr-ghc]}}
addons: {apt: {packages: [ghc-ppa-tools,cabal-install-2.0,ghc-7.10.3], sources: [hvr-ghc]}}
- compiler: "ghc-8.0.2"
addons: {apt: {packages: [ghc-ppa-tools,cabal-install-head,ghc-8.0.2], sources: [hvr-ghc]}}
addons: {apt: {packages: [ghc-ppa-tools,cabal-install-2.0,ghc-8.0.2], sources: [hvr-ghc]}}
- compiler: "ghc-8.2.1"
addons: {apt: {packages: [ghc-ppa-tools,cabal-install-head,ghc-8.2.1], sources: [hvr-ghc]}}
addons: {apt: {packages: [ghc-ppa-tools,cabal-install-2.0,ghc-8.2.1], sources: [hvr-ghc]}}

# allow_failures:
# - compiler: "ghc-8.2.1"
Expand All @@ -62,14 +62,16 @@ install:
- rm -fv cabal.project.local
- "echo 'packages: .' > cabal.project"
- rm -f cabal.project.freeze
- cabal new-build -w ${HC} ${TEST} ${BENCH} -f-doctest --dep -j2 all
- cabal new-build -w ${HC} ${TEST} ${BENCH} --dep -j2 all
- cabal new-build -w ${HC} --disable-tests --disable-benchmarks --dep -j2 all

# 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.
script:
- if [ -f configure.ac ]; then autoreconf -i; fi
- rm -rf dist/
## This creates packagedb, so that sdist works
- cabal new-build -w ${HC} --disable-tests --disable-benchmarks all
## This somehow needs to be installed for sdist for older ghc distros
- cabal sdist # test that a source-distribution can be generated
- cd dist/
- SRCTAR=(${PKGNAME}-*.tar.gz)
Expand All @@ -86,7 +88,7 @@ script:
# - rm -rf ./dist-newstyle

# build & run tests
- cabal new-build -w ${HC} ${TEST} ${BENCH} -f-doctest all
- if [ "x$TEST" = "x--enable-tests" ]; then cabal new-test -w ${HC} ${TEST} ${BENCH} -f-doctest all; fi
- cabal new-build -w ${HC} ${TEST} ${BENCH} all
- if [ "x$TEST" = "x--enable-tests" ]; then cabal new-test -w ${HC} ${TEST} ${BENCH} all; fi

# EOF
2 changes: 1 addition & 1 deletion wreq.cabal
Expand Up @@ -122,7 +122,7 @@ library
time-locale-compat,
template-haskell,
text,
time,
time >= 1.5,
unordered-containers

-- A convenient server for testing locally, or if httpbin.org is down.
Expand Down

0 comments on commit 0a3b824

Please sign in to comment.