* provide way to skip karama tests

This commit is contained in:
Seth Call 2013-08-10 21:29:57 -05:00
parent 4039452bf0
commit 2e89c2ef25
1 changed files with 15 additions and 13 deletions

28
build
View File

@ -45,20 +45,22 @@ if [ -z $SKIP_TESTS ]; then
fi
echo "running karma tests"
#http://shortforgilbert.com/blog/2011/03/25/headless-jasmine-ci
# TODO starting Xvfb here because we don't do this on start of build server
# If you run it once, it will background/nohup itself, so this is 'lazy'
Xvfb :99 -screen 0 1440x900x16 > /dev/null 2>&1 &
# run jasmine using the virtual screen, and in the test environment to use the jam_web_test db
DISPLAY=":99" karma start spec/javascripts/karma.ci.conf.js
if [ -z $SKIP_KARMA ]; then
echo "running karma tests"
#http://shortforgilbert.com/blog/2011/03/25/headless-jasmine-ci
# TODO starting Xvfb here because we don't do this on start of build server
# If you run it once, it will background/nohup itself, so this is 'lazy'
Xvfb :99 -screen 0 1440x900x16 > /dev/null 2>&1 &
# run jasmine using the virtual screen, and in the test environment to use the jam_web_test db
DISPLAY=":99" karma start spec/javascripts/karma.ci.conf.js
if [ "$?" = "0" ]; then
echo "success: karma tests completed"
else
echo "running karma tests failed"
exit 1
fi
if [ "$?" = "0" ]; then
echo "success: karma tests completed"
else
echo "running karma tests failed"
exit 1
fi
fi
if [ -z "$SKIP_CUCUMBER_TESTS" ]; then
echo "running cucumber tests"