From: Brian Foster <bfoster@redhat.com>
To: fstests@vger.kernel.org
Subject: [PATCH] xfs/297: fail test if _scratch_mount fails
Date: Thu, 6 Jul 2017 14:06:20 -0400 [thread overview]
Message-ID: <20170706180620.58376-1-bfoster@redhat.com> (raw)
xfs/297 formats the scratch device with test specific mkfs options
that limit the use of certain mount options (i.e., if logbsize !=
256k). If an incompatible mount option is set, the mount fails but
the test proceeds to run against the root filesystem.
Update xfs/297 to fail if the mount of the scratch device fails for
whatever reason.
Signed-off-by: Brian Foster <bfoster@redhat.com>
---
A couple other options here are to exclude the use of logbsize
(effectively _notrun the test) or to hardcode the mount with '-o
logbsize=256k' in the test. I didn't like the former because it
excludes even when a valid logbsize is set. The latter requires us to
use _require_scratch_nocheck, otherwise the post-test remount fails.
This configuration is rare enough that this seemed like the least bad
option.
Brian
tests/xfs/297 | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tests/xfs/297 b/tests/xfs/297
index fe92441..9accffd 100755
--- a/tests/xfs/297
+++ b/tests/xfs/297
@@ -52,7 +52,7 @@ _require_command "$KILLALL_PROG" killall
rm -f $seqres.full
_scratch_mkfs_xfs -d agcount=16,su=256k,sw=12 -l su=256k,size=5120b >/dev/null 2>&1
-_scratch_mount >/dev/null 2>&1
+_scratch_mount >>$seqres.full 2>&1 || _fail "mount failed"
STRESS_DIR="$SCRATCH_MNT/testdir"
mkdir -p $STRESS_DIR
--
2.9.4
next reply other threads:[~2017-07-06 18:06 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-07-06 18:06 Brian Foster [this message]
2017-07-06 20:32 ` [PATCH] xfs/297: fail test if _scratch_mount fails Bill O'Donnell
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=20170706180620.58376-1-bfoster@redhat.com \
--to=bfoster@redhat.com \
--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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.