testing: Support running multiple tests with * as wildcard (e.g. ikev2/ocsp-*)

This commit is contained in:
Tobias Brunner 2017-07-07 09:23:14 +02:00
parent d7dc677ee5
commit 49917f0028
1 changed files with 10 additions and 6 deletions

View File

@ -207,12 +207,16 @@ for SUBDIR in $TESTS
do
SUBTESTS="`basename $SUBDIR`"
if [ $SUBTESTS = $SUBDIR ]
then
SUBTESTS="`ls $DEFAULTTESTSDIR/$SUBDIR`"
else
SUBDIR="`dirname $SUBDIR`"
fi
if [ $SUBTESTS = $SUBDIR ]
then
SUBTESTS="`ls $DEFAULTTESTSDIR/$SUBDIR`"
else
if [[ $SUBTESTS == *'*'* ]]
then
SUBTESTS="`basename -a $DEFAULTTESTSDIR/$SUBDIR`"
fi
SUBDIR="`dirname $SUBDIR`"
fi
if [ ! -d $TODAYDIR/$SUBDIR ]
then