Skip to content
This repository was archived by the owner on Feb 26, 2024. It is now read-only.

Commit 65bbbfd

Browse files
committed
chore(.travis.yml): fix e2e tests on Travis (run on latest Chrome)
Previously, the E2E tests would always fail/not run on Travis, because the current version of WebDriver requires a newer version of Chrome than the one installed on the VM.
1 parent 37dd5bc commit 65bbbfd

File tree

3 files changed

+10
-7
lines changed

3 files changed

+10
-7
lines changed

.travis.yml

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,17 @@
1+
sudo: required
2+
dist: trusty
3+
14
language: node_js
25
node_js:
36
- '4.4'
47

5-
env: BROWSERS=firefox E2E_BROWSERS=Firefox
6-
78
before_script:
89
- export DISPLAY=:99.0
910
- sh -e /etc/init.d/xvfb start
10-
- npm run update-webdriver
11+
- wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | sudo apt-key add -
12+
- sudo sh -c 'echo "deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google-chrome.list'
13+
- sudo apt-get update -q
14+
- sudo apt-get install -q google-chrome-stable
1115

1216
script:
1317
- scripts/private/test-all.sh

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
"postinstall": "bower install",
2020

2121
"prestart": "npm install",
22-
"start": "http-server -a localhost -p 8000 -c-1 ./app",
22+
"start": "http-server ./app -a localhost -p 8000 -c-1",
2323

2424
"pretest": "npm install",
2525
"test": "karma start karma.conf.js",

scripts/private/test-all.sh

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ npm install
2121
npm run update-webdriver
2222

2323
# Start up the web server
24-
node_modules/.bin/http-server -a localhost -p 8000 -c-1 ./app &
24+
node_modules/.bin/http-server ./app -a localhost -p 8000 -c-1 --silent &
2525
WEBSERVER_PID=$!
2626

2727
# Run the unit and e2e tests
@@ -31,6 +31,5 @@ do
3131
git checkout -f step-$i
3232

3333
node_modules/.bin/karma start karma.conf.js --single-run
34-
node_modules/.bin/protractor e2e-tests/protractor.conf.js
35-
34+
node_modules/.bin/protractor e2e-tests/protractor.conf.js --directConnect
3635
done

0 commit comments

Comments
 (0)