-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy path.travis.yml
More file actions
64 lines (54 loc) · 1.8 KB
/
Copy path.travis.yml
File metadata and controls
64 lines (54 loc) · 1.8 KB
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
# Use new container infrastructure to enable caching
sudo: false
# Choose a lightweight base image; we provide our own build tools.
language: c
# Caching so the next build will be fast too.
cache:
directories:
- $HOME/.ghc
- $HOME/.cabal
- $HOME/.stack
- $(npm config get prefix)/bin/lightning-server
# The different configurations we want to test. We have BUILD=cabal which uses
# cabal-install, and BUILD=stack which uses Stack. More documentation on each
# of those below.
#
# We set the compiler values here to tell Travis to use a different
# cache file per set of arguments.
#
# If you need to have different apt packages for each combination in the
# matrix, you can use a line such as:
# addons: {apt: {packages: [libfcgi-dev,libgmp-dev]}}
env:
global:
- LIGHTNING_VIZ_URL=http://localhost:3000
- TRAVIS_NODE_VERSION=6.9.1
addons:
apt:
packages:
- libgmp-dev
- cabal-install-1.24
- happy-1.19.5
- alex-3.1.7
sources:
- hvr-ghc
before_install:
# Install NodeJS
- rm -rf ~/.nvm && git clone https://github.com/creationix/nvm.git ~/.nvm && (cd ~/.nvm && git checkout `git describe --abbrev=0 --tags`) && source ~/.nvm/nvm.sh && nvm install $TRAVIS_NODE_VERSION
# Install lightning-server
- npm install -g lightning-server
# Download and unpack stack executable
- mkdir -p ~/.local/bin
- export PATH=$HOME/.local/bin:$PATH
- travis_retry curl -L https://www.stackage.org/stack/linux-x86_64 | tar xz --wildcards --strip-components=1 -C ~/.local/bin '*/stack'
install:
- stack --no-terminal --install-ghc test --only-dependencies
# Start lightning-server before
before_script:
- lightning-server &
- sleep 3
script:
# Build and test
- stack --no-terminal test --flag lightning-haskell:integration --haddock --no-haddock-deps
# Make sure sdist can be built
- stack sdist