From: Eryu Guan Date: Tue, 27 May 2014 02:07:17 +0000 (+1000) Subject: xfs/005: filter _scratch_mount output to match golden image X-Git-Tag: v2022.05.01~3126 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=caca5818a921e30df4cd3d78e2004721c8684279;p=xfstests-dev.git xfs/005: filter _scratch_mount output to match golden image Failure message of mount has been changed since util-linux v2.21, to something like: mount: mount /dev/sda5 on /mnt/scratch failed: Structure needs cleaning Filter the output to match the golden image for newer mount binary so that both old and new version of mount work correctly. Signed-off-by: Eryu Guan Reviewed-by: Brian Foster Signed-off-by: Dave Chinner --- diff --git a/tests/xfs/005 b/tests/xfs/005 index 94157c4c..509ac619 100755 --- a/tests/xfs/005 +++ b/tests/xfs/005 @@ -40,6 +40,11 @@ _cleanup() rm -f $tmp.* } +filter_mount() +{ + sed -e "s/mount .* failed: //" +} + # get standard environment, filters and checks . ./common/rc . ./common/filter @@ -59,7 +64,7 @@ _scratch_mkfs_xfs -m crc=1 >> $seqres.full 2>&1 || _fail "mkfs failed" $XFS_IO_PROG -c "pwrite 224 4" $SCRATCH_DEV | _filter_xfs_io # should FAIL, the crc is bad; golden output contains mount failure -_scratch_mount +_scratch_mount 2>&1 | filter_mount # success, all done status=0