test: minor improvements in examples e2e tests script (#18487) (#18487)

PR Close #18487

PR Close #18487
This commit is contained in:
Georgios Kalpakas 2017-08-05 20:04:32 +03:00 committed by Jason Aden
parent 8dec381145
commit 922908818f
2 changed files with 40 additions and 29 deletions

View File

@ -9,6 +9,7 @@ set -u -e -o pipefail
# can be used to run each of the examples in isolation via http as well.
#
(
cd `dirname $0`
DIST="../../dist/examples";
@ -40,3 +41,4 @@ for MODULE in `find . -name module.ts`; do
find `dirname $MODULE` -name \*.css -exec cp {} $FINAL_DIR_PATH \;
done
)

View File

@ -1,8 +1,17 @@
#!/bin/sh
#!/usr/bin/env bash
set -u -e -o pipefail
(
cd `dirname $0`
./build.sh
gulp serve-examples &
trap "kill $!" EXIT
(cd ../../ && NODE_PATH=$NODE_PATH:dist/all $(npm bin)/protractor protractor-examples-e2e.conf.js --bundles=true)
(
cd ../../
NODE_PATH=${NODE_PATH:-}:dist/all
$(npm bin)/protractor protractor-examples-e2e.conf.js --bundles=true
)
)