forked from sagemathinc/cocalc
/
.travis.yml
56 lines (49 loc) · 1.8 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
# SageMathCloud Travis-CI Configuration File
language: node_js
# caching not available, but this should work if it is running in container mode
# container mode disables "sudo", but we need it as long as rethinkdb isn't preinstalled
cache:
apt: true
# directories:
# - salvus/node_modules
# SMC breaks on iojs
node_js:
- "0.12"
# - "0.11"
# - "iojs"
# Travis supports "global" and "build matrix" variables
# http://docs.travis-ci.com/user/environment-variables/
env:
matrix:
- MODE=server
# - MODE=client
# Installation and setup
before_script:
# rethinkdb installation according to http://www.rethinkdb.com/docs/install/ubuntu/
- source /etc/lsb-release
- echo "deb http://download.rethinkdb.com/apt $DISTRIB_CODENAME main" | sudo tee /etc/apt/sources.list.d/rethinkdb.list
- wget -qO- http://download.rethinkdb.com/apt/pubkey.gpg | sudo apt-key add -
- sudo apt-get update -qq
# besides rethinkdb, we need at least python-yaml
- sudo apt-get install rethinkdb python-yaml --force-yes
- rethinkdb --version
- rethinkdb --daemon
# the setup & compilation of SMC
- cd salvus
- source salvus-env
- npm install
- npm run make
# This is the actual testing, which runs in the same directory where `before_script` did end up in.
# A non-zero exit code indicates a failure.
# npm test is the usual, but we also run coverage reporting
script:
- if [[ $MODE = "server" ]]; then npm run test-list; fi
# - if [[ $MODE = "server" ]]; then npm run coveralls; fi
# - if [[ $MODE = "client" ]]; then echo "insert client testing command here" ; fi
# send coverage report over to https://coveralls.io
#after_success:
# - if [[ $MODE = "server" ]]; then sh -c 'cat ./coverage/lcov.info | ./node_modules/.bin/coveralls'; fi
notifications:
slack:
rooms:
- sagemath:imLn6eVwpZSOBCWBIKu97HXx#dev