Test sdist

If ChangeLog is present
This commit is contained in:
Nikolay Yakimov 2016-08-03 18:57:35 +03:00
parent 99e64b0307
commit c5c86c4ec1

View File

@ -44,6 +44,16 @@ script:
- cabal check
- stack --no-terminal build --test --no-run-tests
- stack --no-terminal test ghc-mod:spec
- |
if [ -r "$TRAVIS_BUILD_DIR/ChangeLog" ]; then
sdistdir="$TRAVIS_BUILD_DIR/../sdist-test"
mkdir -p "$sdistdir"
tar zvxf $(stack sdist 2>&1 | tail -n1 | sed 's/.* //') --strip-components=1 -C "$sdistdir"
cp "ghc-$GHCVER.yaml" stack.yaml "$sdistdir"
cd "$sdistdir"
stack --no-terminal build --test --no-run-tests
stack --no-terminal test ghc-mod:spec
fi
matrix:
matrix: