You are here

run-simpletest.sh in Support Ticketing System 8

#!/bin/bash
# @file
# Simple script to run the tests.

set -e

# Goto current directory.
DIR=$(dirname $0)
cd $DIR

drush -y en simpletest support

export CORE_DIR=$(drush drupal-directory)

cd $CORE_DIR
{ php ./core/scripts/run-tests.sh --color --verbose --url 'http://127.0.0.1/' "support" || echo "1 fails"; } | tee /tmp/simpletest-result.txt

egrep -i "([1-9]+ fail)|(Fatal error)|([1-9]+ exception)" /tmp/simpletest-result.txt && exit 1
exit 0

File

tests/run-simpletest.sh
View source
  1. #!/bin/bash
  2. # @file
  3. # Simple script to run the tests.
  4. set -e
  5. # Goto current directory.
  6. DIR=$(dirname $0)
  7. cd $DIR
  8. drush -y en simpletest support
  9. export CORE_DIR=$(drush drupal-directory)
  10. cd $CORE_DIR
  11. { php ./core/scripts/run-tests.sh --color --verbose --url 'http://127.0.0.1/' "support" || echo "1 fails"; } | tee /tmp/simpletest-result.txt
  12. egrep -i "([1-9]+ fail)|(Fatal error)|([1-9]+ exception)" /tmp/simpletest-result.txt && exit 1
  13. exit 0