Darryl L. Pierce
2009-Dec-15 15:34 UTC
[Ovirt-devel] [PATCH] If the specified ISO does not exist, then the script dies.
Before any tests are run, the ISO is checked and if it doesn't exist then the script exits with an explicit failure. Signed-off-by: Darryl L. Pierce <dpierce at redhat.com> --- autotest.sh | 4 ++++ 1 files changed, 4 insertions(+), 0 deletions(-) diff --git a/autotest.sh b/autotest.sh index c67931a..904b961 100755 --- a/autotest.sh +++ b/autotest.sh @@ -723,6 +723,10 @@ done isoname=$(basename $isofile) isofile="$(cd `dirname $isofile`; pwd)/${isoname}" +if ! [ -s "${isofile}" ]; then + die "Missing or invalid file: ${isofile}" +fi + shift $(($OPTIND - 1)) set +u -- 1.6.5.2
Joey Boggs
2009-Dec-21 16:13 UTC
[Ovirt-devel] [PATCH] If the specified ISO does not exist, then the script dies.
On 12/15/2009 10:34 AM, Darryl L. Pierce wrote:> Before any tests are run, the ISO is checked and if it doesn't exist > then the script exits with an explicit failure. > > Signed-off-by: Darryl L. Pierce<dpierce at redhat.com> > --- > autotest.sh | 4 ++++ > 1 files changed, 4 insertions(+), 0 deletions(-) > > diff --git a/autotest.sh b/autotest.sh > index c67931a..904b961 100755 > --- a/autotest.sh > +++ b/autotest.sh > @@ -723,6 +723,10 @@ done > isoname=$(basename $isofile) > isofile="$(cd `dirname $isofile`; pwd)/${isoname}" > > +if ! [ -s "${isofile}" ]; then > + die "Missing or invalid file: ${isofile}" > +fi > + > shift $(($OPTIND - 1)) > > set +u >ACK
Maybe Matching Threads
- [PATCH] The autotest timeout is now a command line configurable option.
- [PATCH node] Update autobuild and autotest scripts for new build structure
- [PATCH node-image] Adds a preserve option for autotest VMs.
- [PATCH node-image] Fixing the autotest script.
- [PATCH] Adds the qemu log to the autotest output.