Skip to content

Commit 1ceb7ae

Browse files
committed
Don't run the unit tests when doing saucelabs.
1 parent 04bc06e commit 1ceb7ae

3 files changed

Lines changed: 12 additions & 8 deletions

File tree

.travis.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ env:
1616
- DISPLAY=:99.0
1717
- CHROME_BIN=chromium-browser
1818
matrix:
19-
- CI_MODE=local
20-
- CI_MODE=saucelabs
19+
- CI_MODE=local_e2e
20+
- CI_MODE=saucelabs_e2e
2121

2222
cache:
2323
directories:

scripts/travis_setup.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,6 @@ set -ex -o pipefail
44
cd `dirname $0`
55

66
# Start Xvfb when running locally.
7-
if [[ ${TRAVIS} && (${CI_MODE} == "local") ]]; then
7+
if [[ ${TRAVIS} && (${CI_MODE} == "local_e2e") ]]; then
88
sh -e /etc/init.d/xvfb start
99
fi

scripts/travis_test.sh

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,16 @@ cd `dirname $0`
55
cd ../tour-of-heroes
66

77
ng build
8-
npm run lint
9-
npm run test -- --watch=false
8+
9+
if [[ ${TRAVIS} && (${CI_MODE} == "local_e2e") ]]; then
10+
npm run lint
11+
npm run test -- --watch=false
12+
PROTRACTOR_CONFIG="./protractor.conf.js"
13+
fi
1014

1115
# When using saucelabs, use a different config.
12-
if [[ ${TRAVIS} && (${CI_MODE} == "saucelabs") ]]; then
13-
PROTRACTOR_CONFIG="protractor-saucelabs.conf.js"
16+
if [[ ${TRAVIS} && (${CI_MODE} == "saucelabs_e2e") ]]; then
17+
PROTRACTOR_CONFIG="./protractor-saucelabs.conf.js"
1418
fi
1519

16-
concurrently --success first --kill-others \"lite-server\" \"protractor $PROTRACTOR_CONFIG\"
20+
concurrently --success first --kill-others "lite-server" "protractor $PROTRACTOR_CONFIG"

0 commit comments

Comments
 (0)