From: Eric Sandeen <sandeen@redhat.com>
To: xfs-oss <xfs@oss.sgi.com>
Subject: [PATCH] xfstests 249: use -F option for xfs_io
Date: Wed, 23 Mar 2011 10:53:57 -0500 [thread overview]
Message-ID: <4D8A1795.3080401@redhat.com> (raw)
Test 249 was appearing to pass on ext4, but it wasn't really
exercising the test due to lack of "-F" in the xfs_io arguments.
Without -F the files were created (oddly enough); neither pwrite
nor sendfile were executed, and the diff of the two (empty)
files passed, resulting in a passed test without testing anything.
So add the -F, capture the output, and test the result of each
xfs_io invocation.
Signed-off-by: Eric Sandeen <sandeen@redhat.com>
---
diff --git a/249 b/249
index 6fc972e..3b3a64d
--- a/249
+++ b/249
@@ -52,9 +52,12 @@ echo "Feel the serenity."
SRC=$TEST_DIR/$seq.src
DST=$TEST_DIR/$seq.dst
+rm -f $seq.full
-$XFS_IO_PROG -f -c "pwrite -S 0xa5a55a5a 0 32768k" -c fsync $SRC > /dev/null 2>&1
-$XFS_IO_PROG -f -c "sendfile -i $SRC 0 32768k" -c fsync $DST > /dev/null 2>&1
+$XFS_IO_PROG -F -f -c "pwrite -S 0xa5a55a5a 0 32768k" -c fsync $SRC >> $seq.full 2>&1
+[ $? -ne 0 ] && _fail "xfs_io pwrite failed"
+$XFS_IO_PROG -F -f -c "sendfile -i $SRC 0 32768k" -c fsync $DST >> $seq.full 2>&1
+[ $? -ne 0 ] && _fail "xfs_io sendfile failed"
diff $SRC $DST
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
next reply other threads:[~2011-03-23 15:51 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-03-23 15:53 Eric Sandeen [this message]
2011-03-23 16:03 ` [PATCH V2] xfstests 249: use -F option for xfs_io Eric Sandeen
2011-03-23 22:50 ` Dave Chinner
2011-04-04 18:36 ` Alex Elder
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=4D8A1795.3080401@redhat.com \
--to=sandeen@redhat.com \
--cc=xfs@oss.sgi.com \
/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.