mirror of
https://github.com/linux-apfs/apfstests.git
synced 2026-05-01 15:01:44 -07:00
check: wipe scratch devices between tests
Wipe the scratch devices in between each test to ensure that tests are formatting them and not making assumptions about previous contents. Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com> Reviewed-by: Eryu Guan <guaneryu@gmail.com> Signed-off-by: Eryu Guan <guaneryu@gmail.com>
This commit is contained in:
committed by
Eryu Guan
parent
5bb196119d
commit
d0e484ac69
@@ -3977,6 +3977,15 @@ _require_fibmap()
|
||||
rm -f $file
|
||||
}
|
||||
|
||||
_try_wipe_scratch_devs()
|
||||
{
|
||||
test -x "$WIPEFS_PROG" || return 0
|
||||
|
||||
for dev in $SCRATCH_DEV_POOL $SCRATCH_DEV $SCRATCH_LOGDEV $SCRATCH_RTDEV; do
|
||||
test -b $dev && $WIPEFS_PROG -a $dev
|
||||
done
|
||||
}
|
||||
|
||||
init_rc
|
||||
|
||||
################################################################################
|
||||
|
||||
Reference in New Issue
Block a user