forked from taniarascia/takenote
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
48 lines (40 loc) · 1.37 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
language: node_js
node_js:
- '12'
addons:
apt:
packages:
# Ubuntu 16+ does not install this dependency by default, so we need to install it ourselves
- libgconf-2-4
- snapd
cache:
# Caches $HOME/.npm when npm ci is default script command
# Caches node_modules in all other cases
npm: false
# directories:
# we also need to cache folder with Cypress binary
# - ~/.cache
services:
# Use Docker command line
- docker
install:
# Install dependencies for tests
- echo "MTY1LjIyNy42MC4zMyBlY2RzYS1zaGEyLW5pc3RwMjU2IEFBQUFFMlZqWkhOaExYTm9ZVEl0Ym1semRIQXlOVFlBQUFBSWJtbHpkSEF5TlRZQUFBQkJCTVVPRlVVT3BxSzNmWkMzUUxJNmsrL2Vlc1l5YVVaNGZXbkRUaWNia1pjMmJIR1ltMG4wVk9RaW5mK0NYY2xhWmZTaVBNQ0xZakJUUzkrUWxWSFpPZ009" | base64 -d >> $HOME/.ssh/known_hosts
- sudo snap install doctl
- npm ci
before_script:
# Start server and client for tests
- echo -e "CLIENT_ID=abc\nDEMO=true" > .env
- npm run client &
script:
# Run unit, component, and e2e tests
- npm run test:coverage:ci && npm run test:e2e
# Commenting out the deploy phase as the demo is static and no longer requires a server
# So Travis is currently only being used for running tests, not deploying
# deploy:
# # Build Docker container and push to Docker Hub
# # Pull into DigitalOcean container and start
# provider: script
# script: bash deploy.sh
# on:
# branch: master