[PATCH] xfstests 273 274 275: do test in dedicated dir and leave test files in it

Eric Sandeen sandeen at sandeen.net
Fri Jan 27 15:16:19 CST 2012


On 1/12/12 11:20 AM, Eryu Guan wrote:
> Do all testings in dedicated dir($SCRATCH_MNT/$seq) instead of
> $SCRATCH_MNT and don't remove test files in _cleanup() for debug
> purpose.
> 
> Signed-off-by: Eryu Guan <guaneryu at gmail.com>
> ---
...


> @@ -58,8 +60,9 @@ umount $SCRATCH_DEV 2>/dev/null
>  _scratch_mkfs_sized $((1 * 1024 * 1024 * 1024)) >>$seq.full 2>&1
>  _scratch_mount
>  
> -rm -rf $SCRATCH_MNT/*
> -cd $SCRATCH_MNT
> +rm -rf $WORK_DIR
> +mkdir -p $WORK_DIR

Seems like the simplest solution is to just not rm -rf _anything_ immediately
after the mkfs.  Why bother?  All it does is remove lost+found/ ... wouldn't
it be simpler to just remove that one line?

-Eric

> +cd $WORK_DIR
>  
>  dd if=/dev/zero of=tmp1 bs=4K count=1 >/dev/null 2>&1
>  if [ $? -ne 0 ]




More information about the xfs mailing list