move '_require_fs_space' after mounted.
==before patch==
btrfs/012 [not run] This test requires at least 0GB free on /fs/scratch to run
==after patch==
btrfs/012 189s ... 194s
Ran: btrfs/012
Passed all 1 tests
Signed-off-by: Zhu Yifei <yifeix.zhu@intel.com>
Reviewed-by: Filipe Manana <fdmanana@suse.com>
Signed-off-by: Eryu Guan <guaneryu@gmail.com>
# ext4 does not support zoned block device
_require_non_zoned_device "${SCRATCH_DEV}"
-_require_fs_space $SCRATCH_MNT $(du -s /lib/modules/`uname -r` | ${AWK_PROG} '{print $1}')
-
BLOCK_SIZE=`_get_block_size $TEST_DIR`
# Create & populate an ext4 filesystem
# Manual mount so we don't use -t btrfs or selinux context
mount -t ext4 $SCRATCH_DEV $SCRATCH_MNT
+_require_fs_space $SCRATCH_MNT $(du -s /lib/modules/`uname -r` | ${AWK_PROG} '{print $1}')
+
cp -aR /lib/modules/`uname -r`/ $SCRATCH_MNT
_scratch_unmount