2015-01-08 17:20:05 -05:00
|
|
|
#!/bin/bash
|
2015-11-05 11:20:13 -05:00
|
|
|
set -ex
|
2015-01-08 17:20:05 -05:00
|
|
|
|
|
|
|
echo =============================================================================
|
|
|
|
# go to project dir
|
|
|
|
SCRIPT_DIR=$(dirname $0)
|
|
|
|
cd $SCRIPT_DIR/../..
|
|
|
|
|
|
|
|
./node_modules/.bin/webdriver-manager update
|
|
|
|
|
|
|
|
function killServer () {
|
|
|
|
kill $serverPid
|
|
|
|
}
|
|
|
|
|
2015-07-20 18:54:30 -04:00
|
|
|
# Serving pre-compiled dart JS takes an extra 15m.
|
|
|
|
# So we do this only for post-commit testing.
|
|
|
|
# Pull requests test with Dartium and pub serve
|
2015-09-22 14:32:14 -04:00
|
|
|
# TODO(jeffbcross): restore conditional dart2js/pubserve #4316
|
|
|
|
#if [ "${TRAVIS_PULL_REQUEST}" = "false" ]; then
|
|
|
|
# WARNING: the build/pubbuild.dart task is assumed to have been run before, in test_server_dart.sh
|
2015-07-20 18:54:30 -04:00
|
|
|
./node_modules/.bin/gulp serve.js.dart2js&
|
|
|
|
serverPid=$!
|
2015-09-22 14:32:14 -04:00
|
|
|
#else
|
|
|
|
# ./node_modules/.bin/gulp serve.dart&
|
|
|
|
# serverPid=$!
|
|
|
|
#fi
|
2015-01-08 17:20:05 -05:00
|
|
|
|
2015-05-04 21:34:06 -04:00
|
|
|
./node_modules/.bin/gulp build.css.material&
|
|
|
|
|
2015-01-08 17:20:05 -05:00
|
|
|
trap killServer EXIT
|
|
|
|
|
2015-01-20 19:29:50 -05:00
|
|
|
# wait for server to come up!
|
|
|
|
sleep 10
|
|
|
|
|
2015-03-15 16:51:41 -04:00
|
|
|
./node_modules/.bin/protractor protractor-dart2js.conf.js --browsers=${E2E_BROWSERS:-Dartium}
|
2015-03-26 19:56:53 -04:00
|
|
|
./node_modules/.bin/protractor protractor-dart2js.conf.js --benchmark --dryrun --browsers=${E2E_BROWSERS:-Dartium}
|