]> git.apps.os.sepia.ceph.com Git - xfstests-dev.git/commit
generic/094: fix test ignoring failures
authorFilipe Manana <fdmanana@suse.com>
Thu, 29 May 2025 11:33:13 +0000 (12:33 +0100)
committerZorro Lang <zlang@kernel.org>
Fri, 6 Jun 2025 01:55:44 +0000 (09:55 +0800)
commit5ca2b3450351ca504e829cc57bdd16c715496fd4
treeefcc6e8c925cfdbb221ee35fa7b0bc2624e5714a
parentd866af976999cdcc3c548b4bf5baa865942e895f
generic/094: fix test ignoring failures

The test is ignoring failures completely:

1) If mounting the scratch device fails it redirects both stdout and
   stderr to /dev/null, so it gets unnoticed and the test runs against
   a different fs than expected (in my test environment $SCRATCH_MNT
   points to a directory in an ext4 fs for example but I want to test
   btrfs);

2) We are redirecting the stdout and stderr of fiemap-tester to the
   $seqres.full file, so if it fails it gets completely unnoticed and
   the test succeeds.

For the first issue fix this by not even using the scratch filesystem and
use instead the test filesystem, since the test creates a 2M file which
is small enough.

For the second issue simply don't redirect the stdout and stderr, so that
if the test program fails it causes a mismatch with the golden output,
making the test fail.

Signed-off-by: Filipe Manana <fdmanana@suse.com>
Reviewed-by: Zorro Lang <zlang@redhat.com>
Signed-off-by: Zorro Lang <zlang@kernel.org>
tests/generic/094