diff mbox series

[2/4] xfs/{088, 089, 091}: redirect stderr when writing to corrupt fs

Message ID 157049659754.2397321.4949328613812405852.stgit@magnolia (mailing list archive)
State Accepted
Headers show
Series fstests: random fixes | expand

Commit Message

Darrick J. Wong Oct. 8, 2019, 1:03 a.m. UTC
From: Darrick J. Wong <darrick.wong@oracle.com>

These tests primarily check that writes to a corrupt fs don't take down
the system, and that running repair will fix them.  Therefore, redirect
stderr to seqres.full so that we don't fail these tests in DAX mode.

Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
---
 tests/xfs/088 |    2 +-
 tests/xfs/089 |    2 +-
 tests/xfs/091 |    2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

Comments

Christoph Hellwig Oct. 8, 2019, 7:01 a.m. UTC | #1
On Mon, Oct 07, 2019 at 06:03:17PM -0700, Darrick J. Wong wrote:
> From: Darrick J. Wong <darrick.wong@oracle.com>
> 
> These tests primarily check that writes to a corrupt fs don't take down
> the system, and that running repair will fix them.  Therefore, redirect
> stderr to seqres.full so that we don't fail these tests in DAX mode.
> 
> Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>

Looks good,

Reviewed-by: Christoph Hellwig <hch@lst.de>
diff mbox series

Patch

diff --git a/tests/xfs/088 b/tests/xfs/088
index 74b45163..d8ca877a 100755
--- a/tests/xfs/088
+++ b/tests/xfs/088
@@ -80,7 +80,7 @@  echo "+ mount image && modify files"
 if _try_scratch_mount >> $seqres.full 2>&1; then
 
 	for x in `seq 1 64`; do
-		$XFS_IO_PROG -f -c "pwrite -S 0x62 0 ${blksz}" "${TESTFILE}.${x}" >> $seqres.full
+		$XFS_IO_PROG -f -c "pwrite -S 0x62 0 ${blksz}" "${TESTFILE}.${x}" >> $seqres.full 2>> $seqres.full
 	done
 	umount "${SCRATCH_MNT}"
 fi
diff --git a/tests/xfs/089 b/tests/xfs/089
index bcbc6363..ad980769 100755
--- a/tests/xfs/089
+++ b/tests/xfs/089
@@ -80,7 +80,7 @@  echo "+ mount image && modify files"
 if _try_scratch_mount >> $seqres.full 2>&1; then
 
 	for x in `seq 1 64`; do
-		$XFS_IO_PROG -f -c "pwrite -S 0x62 0 ${blksz}" "${TESTFILE}.${x}" >> $seqres.full
+		$XFS_IO_PROG -f -c "pwrite -S 0x62 0 ${blksz}" "${TESTFILE}.${x}" >> $seqres.full 2>> $seqres.full
 	done
 	umount "${SCRATCH_MNT}"
 fi
diff --git a/tests/xfs/091 b/tests/xfs/091
index be56d8ae..37c07a52 100755
--- a/tests/xfs/091
+++ b/tests/xfs/091
@@ -80,7 +80,7 @@  echo "+ mount image && modify files"
 if _try_scratch_mount >> $seqres.full 2>&1; then
 
 	for x in `seq 1 64`; do
-		$XFS_IO_PROG -f -c "pwrite -S 0x62 0 ${blksz}" "${TESTFILE}.${x}" >> $seqres.full
+		$XFS_IO_PROG -f -c "pwrite -S 0x62 0 ${blksz}" "${TESTFILE}.${x}" >> $seqres.full 2>> $seqres.full
 	done
 	umount "${SCRATCH_MNT}"
 fi