forked from Trustroots/trustroots
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
46 lines (43 loc) · 1.35 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
language: node_js
matrix:
fast_finish: true
# Generally using active LTS versions here, see https://github.com/nodejs/Release
include:
- name: "Test client"
node_js: 12
env: RUN="npm run test:client"
- name: "Test server"
node_js: 12
env: RUN="npm run test:server"
- name: "Lint and try building"
node_js: 12
env: RUN="npx concurrently --kill-others-on-fail 'npm:lint' 'npm:build:prod'"
# https://docs.travis-ci.com/user/reference/overview/#Virtualisation-Environment-vs-Operating-System
script: $RUN
install: npm ci
dist: trusty
services: mongodb
addons:
apt:
sources:
- google-chrome
packages:
- google-chrome-stable
- graphicsmagick
before_script:
- mongo --version
- mongod --version
# https://docs.travis-ci.com/user/gui-and-headless-browsers/#Using-xvfb-to-Run-Tests-That-Require-a-GUI
- 'export PATH=$PATH:/usr/lib/chromium-browser/'
- 'export DISPLAY=:99.0'
- 'sh -e /etc/init.d/xvfb start'
- sleep 3 # give xvfb some time to start
# Ensure stable NPM version (avoids `-next.0` tags)
- 'npm install -g npm'
cache:
directories:
- "$HOME/.node-gyp"
- "$HOME/.npm"
notifications:
slack:
secure: XRMYG9Hf+bJjMSHHXN0XeGT4ZhSP+oCHBUWmjBwxO0p+VORBOEZvlh/2OvxingFuzLGOXFeOPr1g91G+OgiCGR6GxaDpf680lEjk8ESTJ4oECv0aO2NQEZWYR4peiLRtBmJZTCSsKXDY21nrDHiKOaMQyPJqbzkIrTBMnK/YJpg=