From 49917f002829f2d0d9062f69461ac04ab14f1b6e Mon Sep 17 00:00:00 2001 From: Tobias Brunner Date: Fri, 7 Jul 2017 09:23:14 +0200 Subject: [PATCH] testing: Support running multiple tests with * as wildcard (e.g. ikev2/ocsp-*) --- testing/do-tests | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/testing/do-tests b/testing/do-tests index 60c34c798..230403b9f 100755 --- a/testing/do-tests +++ b/testing/do-tests @@ -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