From ebb20e075e5c2ad839120fb45cfa6e3a43375485 Mon Sep 17 00:00:00 2001 From: Julien Chanseaume Date: Mon, 11 Aug 2014 14:19:45 +0200 Subject: [PATCH] make a uniq script to execute phpunit and casperjs --- .travis.yml | 5 ++--- run-tests.sh | 11 +++++++++++ 2 files changed, 13 insertions(+), 3 deletions(-) create mode 100755 run-tests.sh diff --git a/.travis.yml b/.travis.yml index 1d1ac2909..cda13356f 100755 --- a/.travis.yml +++ b/.travis.yml @@ -29,10 +29,9 @@ before_script: - git clone https://github.com/n1k0/casperjs.git - cd casperjs - git checkout tags/1.1-beta3 + - cd ../thelia -script: - - phpunit - - "DISPLAY=:99.0 ./bin/casperjs test ../thelia/tests/functionnal/casperjs/exe/front/ --pre=../thelia/tests/functionnal/casperjs/conf/local.js --verbose --thelia2_base_url='http://localhost:8000/index.php/' --thelia2_screenshot_path='../thelia/tests/functionnal/casperjs/screenshot/'" +script: "./run-tests.sh" matrix: allow_failures: diff --git a/run-tests.sh b/run-tests.sh new file mode 100755 index 000000000..b55ccf7aa --- /dev/null +++ b/run-tests.sh @@ -0,0 +1,11 @@ +#/usr/bin/env/sh + +# will exit with non-zero error code if any of the command fails +set -e + +echo "phpunit" +phpunit + +echo "CasperJS" +cd ../casperjs +"DISPLAY=:99.0 ./bin/casperjs test ../thelia/tests/functionnal/casperjs/exe/front/ --pre=../thelia/tests/functionnal/casperjs/conf/local.js --verbose --thelia2_base_url='http://localhost:8000/index.php/' --thelia2_screenshot_path='../thelia/tests/functionnal/casperjs/screenshot/'"