allow to execute multiple tests in a directory at once

This commit is contained in:
Bjoern Schiessle 2016-06-14 11:32:45 +02:00
parent 01f8434a75
commit e7cb21b7e9
No known key found for this signature in database
GPG Key ID: 2378A753E2BF04F6
1 changed files with 11 additions and 2 deletions

View File

@ -303,9 +303,18 @@ function execute_tests {
else
echo "No coverage"
fi
echo "${PHPUNIT[@]}" --configuration phpunit-autotest.xml $GROUP $COVER --log-junit "autotest-results-$DB.xml" "$2" "$3"
"${PHPUNIT[@]}" --configuration phpunit-autotest.xml $GROUP $COVER --log-junit "autotest-results-$DB.xml" "$2" "$3"
if [ -d "$2" ]; then
for f in $(find "$2" -name '*.php'); do
echo "${PHPUNIT[@]}" --configuration phpunit-autotest.xml $GROUP $COVER --log-junit "autotest-results-$DB.xml" "$2" / "$f" "$3"
"${PHPUNIT[@]}" --configuration phpunit-autotest.xml $GROUP $COVER --log-junit "autotest-results-$DB.xml" "$f" "$3"
RESULT=$?
done;
else
echo "${PHPUNIT[@]}" --configuration phpunit-autotest.xml $GROUP $COVER --log-junit "autotest-results-$DB.xml" "$2" "$3"
"${PHPUNIT[@]}" --configuration phpunit-autotest.xml $GROUP $COVER --log-junit "autotest-results-$DB.xml" "$2" "$3"
RESULT=$?
fi
if [ "$PRIMARY_STORAGE_CONFIG" == "swift" ] ; then
cd ..