summaryrefslogtreecommitdiffstats
path: root/autotest.sh
diff options
context:
space:
mode:
authorBjoern Schiessle <bjoern@schiessle.org>2016-06-14 11:32:45 +0200
committerBjoern Schiessle <bjoern@schiessle.org>2016-06-14 11:32:45 +0200
commite7cb21b7e92fdd5ae6f10eca889dcb9990661973 (patch)
tree8a65cd078438813fc3919fd30a2c8657f2c28949 /autotest.sh
parent01f8434a754d3822cf0bed4ad473a9a7aec7d623 (diff)
downloadnextcloud-server-e7cb21b7e92fdd5ae6f10eca889dcb9990661973.tar.gz
nextcloud-server-e7cb21b7e92fdd5ae6f10eca889dcb9990661973.zip
allow to execute multiple tests in a directory at once
Diffstat (limited to 'autotest.sh')
-rwxr-xr-xautotest.sh13
1 files changed, 11 insertions, 2 deletions
diff --git a/autotest.sh b/autotest.sh
index e798157fe64..57d65e692d4 100755
--- a/autotest.sh
+++ b/autotest.sh
@@ -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 ..