-
Notifications
You must be signed in to change notification settings - Fork 2
/
.travis.yml
52 lines (43 loc) · 980 Bytes
/
.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
dist: trusty
sudo: false
language: node_js
node_js:
- "12"
addons:
chrome: stable
apt:
update: true
packages:
- gettext-base
env:
global:
CODECOV_TOKEN=$CODECOV_TOKEN
cache:
directories:
- ./node_modules
install:
- npm install
stages:
- name: Lint & Test
- name: Deploy to Firebase
if: branch = master
jobs:
include:
- stage: Lint & Test
script:
- npm run lint
- stage: Lint & Test
script:
- npm run test -- --no-watch --no-progress --code-coverage --browsers=ChromeHeadless
after_script:
- if [[ "$TRAVIS_TEST_RESULT" == 0 ]]; then ./node_modules/.bin/codecov; fi
- stage: Deploy to Firebase
skip_cleanup: true
script:
- npm run build -- --prod --output-path=dist
before_deploy:
- envsubst < ./dist/assets/env.template.js > ./dist/assets/env.js
deploy:
provider: firebase
token: $FIREBASE_TOKEN
edge: true