From: Amir Goldstein Date: Mon, 2 Jan 2017 13:22:59 +0000 (+0200) Subject: check: support include/exclude of sub groups X-Git-Tag: v2022.05.01~2246 X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=5d801985113e284b60fe1aa11bd73eef699900b9;p=users%2Fhch%2Fxfstests-dev.git check: support include/exclude of sub groups Allow including and/or excluding tests by test dir and group. -g and -x command line arguments can take the form of /. For example: ./check -n -g xfs/quick ./check -n -g stress -x xfs/stress ./check -n -g xfs/punch -x dangerous_fuzzers Signed-off-by: Amir Goldstein Reviewed-by: Eryu Guan Signed-off-by: Eryu Guan --- diff --git a/check b/check index faf6281cb..8d1ec7148 100755 --- a/check +++ b/check @@ -105,6 +105,14 @@ get_group_list() { local grp=$1 local grpl="" + local sub=$(dirname $grp) + + if [ -n "$sub" -a "$sub" != "." -a -d "$SRC_DIR/$sub" ]; then + # group is given as / (e.g. xfs/quick) + grp=$(basename $grp) + get_sub_group_list $sub $grp + return + fi for d in $SRC_GROUPS $FSTYP; do if ! test -d "$SRC_DIR/$d" ; then