Hi!
> > Giving it a second though it may. Because if you just mount and unmout
> > the device the kernel code coverage is likely much smaller.
> >
> > What about we list all files on the device and redirect the output to
> > /dev/null and check for the ls exit value?
> 
> In this case most of the changes introduced by this patch are not needed 
> at all:)
> 
> So the final one would be something like this:
> 
> diff --git a/testscripts/isofs.sh b/testscripts/isofs.sh
> index 2bb2555..1f69928 100755
> --- a/testscripts/isofs.sh
> +++ b/testscripts/isofs.sh
> @@ -98,7 +98,7 @@ for mkisofs_opt in \
>          "-allow-lowercase -allow-multidot -iso-level 3 -f -l -D -J -L -R"
>   do
>          rm -f isofs.iso
> -       mkisofs -o isofs.iso -quiet $mkisofs_opt $MAKE_FILE_SYS_DIR
> +       mkisofs -o isofs.iso -quiet $mkisofs_opt $MAKE_FILE_SYS_DIR 2> 
> /dev/null
>          if [ $? -eq 0 ]; then
>                  tst_resm TPASS \
>                          "mkisofs -o isofs.iso -quiet $mkisofs_opt 
> $MAKE_FILE_SYS_DIR"
> @@ -128,9 +128,11 @@ do
>                          continue
>                  fi
> 
> -               ls -lR $MNT_POINT
> -               exportfs -i -o no_root_squash,rw *:$MNT_POINT
> -               exportfs -u :$MNT_POINT
> +               ls -lR $MNT_POINT > /dev/null
> +               if [ $? -ne 0 ]; then
> +                       tst_resm TFAIL "ls -lR $MNT_POINT"
> +                       continue
> +               fi
> 
>                  umount $MNT_POINT
>                  if [ $? -ne 0 ]; then
> 
> Correct?

I think that we should try to umount it if the ls has failed too.

In reality when ls fails the system would be in inconstistent state and
the umount will likely fail too but it would not harm.

> exportfs always returns 0, so there is no point to execute it at all.

Right.

-- 
Cyril Hrubis
[email protected]

------------------------------------------------------------------------------
Is your legacy SCM system holding you back? Join Perforce May 7 to find out:
• 3 signs your SCM is hindering your productivity
• Requirements for releasing software faster
• Expert tips and advice for migrating your SCM now
http://p.sf.net/sfu/perforce
_______________________________________________
Ltp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list

Reply via email to