File tree Expand file tree Collapse file tree 9 files changed +75
-14
lines changed
Expand file tree Collapse file tree 9 files changed +75
-14
lines changed Original file line number Diff line number Diff line change 99 - LOGS_DIR=/tmp/angular-build/logs
1010 - ARCH=linux-x64
1111 matrix :
12- - CHANNEL=stable
13- - CHANNEL=dev
12+ - MODE=js DART_CHANNEL=stable
13+ - MODE=dart DART_CHANNEL=stable
14+ - MODE=dart DART_CHANNEL=dev
1415
1516before_install :
1617- export DISPLAY=:99.0
1718- export GIT_SHA=$(git rev-parse HEAD)
1819- ./scripts/ci/init_android.sh
19- - ./scripts/ci/install_dart.sh
20+ - ./scripts/ci/install_dart.sh ${DART_CHANNEL} ${ARCH}
2021- sh -e /etc/init.d/xvfb start
2122- if [[ -e SKIP_TRAVIS_TESTS ]]; then { cat SKIP_TRAVIS_TESTS ; exit 0; } fi
2223before_script :
2324- mkdir -p $LOGS_DIR
2425script :
25- - ./scripts/ci/build.sh
26- - ./scripts/ci/test_unit.sh
27- - ./scripts/ci/test_e2e.sh
26+ - ./scripts/ci/build_and_test.sh ${MODE}
2827after_script :
2928- ./scripts/ci/print-logs.sh
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+ set -e
3+
4+ MODE=$1
5+
6+ echo =============================================================================
7+ # go to project dir
8+ SCRIPT_DIR=$( dirname $0 )
9+ cd $SCRIPT_DIR /../..
10+
11+ ${SCRIPT_DIR} /build_$MODE .sh
12+ ${SCRIPT_DIR} /test_unit_$MODE .sh
13+ ${SCRIPT_DIR} /test_e2e_$MODE .sh
Original file line number Diff line number Diff line change @@ -7,6 +7,6 @@ SCRIPT_DIR=$(dirname $0)
77source $SCRIPT_DIR /env_dart.sh
88cd $SCRIPT_DIR /../..
99
10- ./node_modules/.bin/gulp build
10+ ./node_modules/.bin/gulp build.js.cjs build.dart
1111
1212pub install
Original file line number Diff line number Diff line change 44echo =============================================================================
55# go to project dir
66SCRIPT_DIR=$( dirname $0 )
7+ # this is needed because we're running JS tests in Dartium too
78source $SCRIPT_DIR /env_dart.sh
89cd $SCRIPT_DIR /../..
910
10- ./node_modules/.bin/gulp ci --browsers= $KARMA_BROWSERS
11+ ./node_modules/.bin/gulp build.js
Original file line number Diff line number Diff line change 11#! /bin/bash
22
3- set -e
3+ set -e -x
44
5- AVAILABLE_DART_VERSION=$( curl " https://storage.googleapis.com/dart-archive/channels/$CHANNEL /release/latest/VERSION" | python -c \
5+ DART_CHANNEL=$1
6+ ARCH=$2
7+
8+ AVAILABLE_DART_VERSION=$( curl " https://storage.googleapis.com/dart-archive/channels/${DART_CHANNEL} /release/latest/VERSION" | python -c \
69 ' import sys, json; print(json.loads(sys.stdin.read())["version"])' )
710
8- echo Fetch Dart channel: $CHANNEL
11+ echo Fetch Dart channel: ${DART_CHANNEL}
912
10- URL_PREFIX=https://storage.googleapis.com/dart-archive/channels/$CHANNEL /release/latest
13+ URL_PREFIX=https://storage.googleapis.com/dart-archive/channels/${DART_CHANNEL} /release/latest
1114DART_SDK_URL=" $URL_PREFIX /sdk/dartsdk-$ARCH -release.zip"
1215DARTIUM_URL=" $URL_PREFIX /dartium/dartium-$ARCH -release.zip"
1316
Original file line number Diff line number Diff line change @@ -13,13 +13,12 @@ function killServer () {
1313 kill $serverPid
1414}
1515
16- ./node_modules/.bin/gulp serve.js.prod serve.js. dart2js&
16+ ./node_modules/.bin/gulp serve.js.dart2js&
1717serverPid=$!
1818
1919trap killServer EXIT
2020
2121# wait for server to come up!
2222sleep 10
2323
24- ./node_modules/.bin/protractor protractor-e2e-js.conf.js --browsers=$E2E_BROWSERS
2524./node_modules/.bin/protractor protractor-e2e-dart2js.conf.js --browsers=$E2E_BROWSERS
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+ set -e
3+
4+ echo =============================================================================
5+ # go to project dir
6+ SCRIPT_DIR=$( dirname $0 )
7+ source $SCRIPT_DIR /env_dart.sh
8+ cd $SCRIPT_DIR /../..
9+
10+ ./node_modules/.bin/webdriver-manager update
11+
12+ function killServer () {
13+ kill $serverPid
14+ }
15+
16+ ./node_modules/.bin/gulp serve.js.prod&
17+ serverPid=$!
18+
19+ trap killServer EXIT
20+
21+ # wait for server to come up!
22+ sleep 10
23+
24+ ./node_modules/.bin/protractor protractor-e2e-js.conf.js --browsers=$E2E_BROWSERS
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+ set -e
3+
4+ echo =============================================================================
5+ # go to project dir
6+ SCRIPT_DIR=$( dirname $0 )
7+ source $SCRIPT_DIR /env_dart.sh
8+ cd $SCRIPT_DIR /../..
9+
10+ ./node_modules/.bin/gulp test.transpiler.unittest
11+ ./node_modules/.bin/gulp test.dart/ci --browsers=$KARMA_BROWSERS
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+ set -e
3+
4+ echo =============================================================================
5+ # go to project dir
6+ SCRIPT_DIR=$( dirname $0 )
7+ source $SCRIPT_DIR /env_dart.sh
8+ cd $SCRIPT_DIR /../..
9+
10+ ./node_modules/.bin/gulp test.transpiler.unittest
11+ ./node_modules/.bin/gulp test.js/ci --browsers=$KARMA_BROWSERS
You can’t perform that action at this time.
0 commit comments