public inbox for fstests@vger.kernel.org
 help / color / mirror / Atom feed
From: David Disseldorp <ddiss@suse.de>
To: fstests@vger.kernel.org
Cc: David Disseldorp <ddiss@suse.de>
Subject: [PATCH] check: fix -X exclude_file behaviour
Date: Wed, 19 Dec 2018 16:41:55 +0100	[thread overview]
Message-ID: <20181219154155.10140-1-ddiss@suse.de> (raw)

It is currently processed before FSTYP has been properly set, leading to
xfs, btrfs, etc. specific exclude_files being ignored.

Signed-off-by: David Disseldorp <ddiss@suse.de>
Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de>
---
 check | 18 +++++++++++-------
 1 file changed, 11 insertions(+), 7 deletions(-)

diff --git a/check b/check
index 59f94c1c..5f8210d7 100755
--- a/check
+++ b/check
@@ -22,6 +22,7 @@ have_test_arg=false
 randomize=false
 export here=`pwd`
 xfile=""
+subdir_xfile=""
 brief_test_summary=false
 do_report=false
 DUMP_OUTPUT=false
@@ -272,13 +273,7 @@ while [ $# -gt 0 ]; do
 		XGROUP_LIST="$XGROUP_LIST ${xgroup//,/ }"
 		;;
 
-	-X)	xfile=$2; shift ;
-		for d in $SRC_GROUPS $FSTYP; do
-			[ -f $SRC_DIR/$d/$xfile ] || continue
-			for f in `sed "s/#.*$//" $SRC_DIR/$d/$xfile`; do
-				echo $d/$f >> $tmp.xlist
-			done
-		done
+	-X)	subdir_xfile=$2; shift ;
 		;;
 	-E)	xfile=$2; shift ;
 		if [ -f $xfile ]; then
@@ -325,6 +320,15 @@ if ! . ./common/rc; then
 	exit 1
 fi
 
+if [ -n "$subdir_xfile" ]; then
+	for d in $SRC_GROUPS $FSTYP; do
+		[ -f $SRC_DIR/$d/$subdir_xfile ] || continue
+		for f in `sed "s/#.*$//" $SRC_DIR/$d/$subdir_xfile`; do
+			echo $d/$f >> $tmp.xlist
+		done
+	done
+fi
+
 # Process tests from command line now.
 if $have_test_arg; then
 	while [ $# -gt 0 ]; do
-- 
2.13.7

                 reply	other threads:[~2018-12-19 15:42 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20181219154155.10140-1-ddiss@suse.de \
    --to=ddiss@suse.de \
    --cc=fstests@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox