[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-block] [PATCH 5/6] tests: add iotests helpers for dealing with
From: |
Daniel P . Berrangé |
Subject: |
Re: [Qemu-block] [PATCH 5/6] tests: add iotests helpers for dealing with TLS certificates |
Date: |
Mon, 19 Nov 2018 14:32:19 +0000 |
User-agent: |
Mutt/1.10.1 (2018-07-13) |
On Mon, Nov 19, 2018 at 08:27:56AM -0600, Eric Blake wrote:
> On 11/19/18 5:04 AM, Max Reitz wrote:
>
> > > > > +tls_dir="${TEST_DIR}/tls"
> > > > > +
> > > > > +function tls_x509_cleanup()
> > > > > +{
> > > > > + rm -f ${tls_dir}/*.pem
> > > > > + rm -f ${tls_dir}/*/*.pem
> > > > > + rmdir ${tls_dir}/*
> > > > > + rmdir ${tls_dir}
> > > >
> > > > Why not just:
> > > > rm -rf $tls_dir
> > >
> > > Yeah, I guess we could do that for simplicity
> > >
> > > > Also, the quoting is a bit inconsistent. if ${TEST_DIR} can contain
> > > > spaces,
> > > > then all uses of ${tls_dir} need to be in "".
> > >
> > > Hmm, yes.
> >
> > Which by the way is a very good reason *not* to blindly use "rm -r".
>
> If we ever revive Jeff Cody's patches to let each test run with its own
> temporary directory, then we don't need this function at all. With that in
> place, you either run the testsuite in debug mode (all temporary files
> preserved) or in normal mode (./check itself does rm -rf on the temporary
> directory).
That would be very nice - i'm often just commenting out the rm lines to
preserve temp files.
Regards,
Daniel
--
|: https://berrange.com -o- https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org -o- https://fstop138.berrange.com :|
|: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|
[Qemu-block] [PATCH 5/6] tests: add iotests helpers for dealing with TLS certificates, Daniel P . Berrangé, 2018/11/16
[Qemu-block] [PATCH 6/6] tests: exercise NBD server in TLS mode, Daniel P . Berrangé, 2018/11/16
Re: [Qemu-block] [PATCH 6/6] tests: exercise NBD server in TLS mode, Daniel P . Berrangé, 2018/11/19
Re: [Qemu-block] [PATCH 6/6] tests: exercise NBD server in TLS mode, Eric Blake, 2018/11/17