On 01/06/2012 08:04 AM, Jiri Denemark wrote: > --- Also a bit light on the commit message. > src/libvirt_private.syms | 1 + > src/qemu/qemu_capabilities.c | 5 + > src/qemu/qemu_capabilities.h | 1 + > src/qemu/qemu_command.c | 97 +++++++++++++------- > tests/qemuhelptest.c | 21 +++-- > tests/qemuxml2argvdata/qemu-lib.sh | 50 ++++++++++ > tests/qemuxml2argvdata/qemu-supported-cpus.sh | 15 +++ > tests/qemuxml2argvdata/qemu.sh | 51 +---------- Thanks for enhancing the testsuite; as time-consuming as it is, it always has a good payout in preventing regressions. > diff --git a/tests/qemuxml2argvdata/qemu-lib.sh b/tests/qemuxml2argvdata/qemu-lib.sh > new file mode 100644 Should this be chmod +x? > diff --git a/tests/qemuxml2argvdata/qemu-supported-cpus.sh b/tests/qemuxml2argvdata/qemu-supported-cpus.sh > new file mode 100755 > index 0000000..c4c14d9 > --- /dev/null > +++ b/tests/qemuxml2argvdata/qemu-supported-cpus.sh > @@ -0,0 +1,15 @@ > +#! /bin/sh > + > +source $(dirname $0)/qemu-lib.sh I guess since you are sourcing the file, it doesn't matter if it the helper file is executable; it is just division of labor. s/source/./ (the spelled-out name is a bash extension not guaranteed by POSIX). > + > +case $* in > +"-M ?") > + faked_machine > + ;; > +"-cpu ?") > + faked_cpu | fgrep -v '[' fgrep is not standard (although it's likely to exist on all platforms where qemu exists). In isolation, [ doesn't need shell quoting (although seeing quotes around a grep script makes it obvious what pattern you are looking for). I'd use either: faked_cpu | grep -Fv '[' faked_cpu | grep -v '\[' > diff --git a/tests/qemuxml2argvdata/qemu.sh b/tests/qemuxml2argvdata/qemu.sh > index 6d5d354..bbf5a16 100755 > --- a/tests/qemuxml2argvdata/qemu.sh > +++ b/tests/qemuxml2argvdata/qemu.sh > @@ -1,55 +1,6 @@ > #! /bin/sh > > +source $(dirname $0)/qemu-lib.sh Again, s/source/./ -- Eric Blake eblake@xxxxxxxxxx +1-919-301-3266 Libvirt virtualization library http://libvirt.org
Attachment:
signature.asc
Description: OpenPGP digital signature
-- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list