-
Notifications
You must be signed in to change notification settings - Fork 58
/
.travis.yml
75 lines (61 loc) · 2.01 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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
sudo: required
dist: trusty
env:
global:
- DEPLOY_SITE=qualityfaster
- BROWSER=chrome
- DISPLAY=:99.0
language: node_js
node_js: "stable"
addons:
apt:
sources:
- google-chrome
packages:
- google-chrome-stable
firefox: "latest"
cache:
directories:
- "node_modules"
- "~/.npm"
- "~/.meteor"
- "src/node_modules"
- "src/.meteor/local/build"
- "src/.meteor/local/bundler-cache"
- "src/.meteor/local/db"
- "src/.meteor/local/isopacks"
- "src/.meteor/local/plugin-cache"
before_cache:
# Remove any log files before caching
- find . -name "*.log" -type f -delete
before_install:
# Start X Virtual Frame Buffer for headless testing with real browsers
- scripts/start-xvfb.sh
install:
# Install & cache Meteor
- scripts/install-meteor.sh
# Install NPM dependencies
- npm install
# Download & cache Chimp's dependencies
- scripts/download-chimp-dependencies.sh
# Download & cache Karma's dependencies
- scripts/download-karma-dependencies.sh
script:
- npm test
# For the deployment code below to work, you need to first carry out the following steps on your local machine:
# 1. Create a Meteor developer account and sign-up for Galaxy
# 2a. Login with Meteor and save the session to file
# METEOR_SESSION_FILE=meteor-session-file.json meteor login
# 2b. Use Node.js to encode and output the file as a Base64 string
# FILE_CONTENT=`cat meteor-session-file.json` node -e "console.log(new Buffer(process.env.FILE_CONTENT).toString('base64'))"
# 3. Copy & paste the output in an environment variable called METEOR_SESSION_FILE_CONTENT in the project settings on TravisCI
# NOTE Deployment is being handled by CircleCI. Simply uncomment these below if you prefer to use TravisCI.
#deploy:
# # We deploy to production any time the previous test step passed AND...
# provider: script
# # We use the script to deploy
# script: scripts/deploy.sh
# skip_cleanup: true
# on:
# # ...when the commit is made to this branch
# branch: dev