Optimize scripts.

This commit is contained in:
James Cole 2016-01-24 15:55:48 +01:00
parent a7ecdf715f
commit 2832d308f1
2 changed files with 10 additions and 1 deletions

View File

@ -38,12 +38,14 @@ then
# run it! # run it!
echo "Now running $firstFile" echo "Now running $firstFile"
phpunit --verbose $firstFile phpunit --verbose $firstFile
result=$?
fi fi
if [ -f "$secondFile" ] if [ -f "$secondFile" ]
then then
# run it! # run it!
echo "Now running $secondFile" echo "Now running $secondFile"
phpunit --verbose $secondFile phpunit --verbose $secondFile
result=$?
fi fi
@ -54,4 +56,6 @@ fi
cp .env.local .env cp .env.local .env
# restore cover # restore cover
cp phpunit.default.xml phpunit.xml cp phpunit.default.xml phpunit.xml
exit ${result}

5
pu.sh
View File

@ -27,6 +27,7 @@ if [ -z "$1" ]
then then
echo "Running all tests..." echo "Running all tests..."
phpunit phpunit
result=$?
fi fi
# test selective.. # test selective..
@ -43,12 +44,14 @@ then
# run it! # run it!
echo "Now running $firstFile" echo "Now running $firstFile"
phpunit --verbose $firstFile phpunit --verbose $firstFile
result=$?
fi fi
if [ -f "$secondFile" ] if [ -f "$secondFile" ]
then then
# run it! # run it!
echo "Now running $secondFile" echo "Now running $secondFile"
phpunit --verbose $secondFile phpunit --verbose $secondFile
result=$?
fi fi
@ -58,3 +61,5 @@ fi
# restore .env file # restore .env file
cp .env.local .env cp .env.local .env
exit ${result}