[libvirt] [PATCH] qemucaps2xmltest: fix test to successfully run without kvm support

Function virQEMUCapsInitGuestFromBinary detect kvm support by testing whether /dev/kvm exists or whether we pass path to kvmbin. Provide the path we are testing via kvmbin for testing purpose instead of detecting presence of /dev/kvm to successfully run the tests on all hosts. Signed-off-by: Pavel Hrdina <phrdina@redhat.com> --- tests/qemucaps2xmltest.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/qemucaps2xmltest.c b/tests/qemucaps2xmltest.c index b3975b4..826f9ea 100644 --- a/tests/qemucaps2xmltest.c +++ b/tests/qemucaps2xmltest.c @@ -118,8 +118,8 @@ testGetCaps(char *capsData, const testQemuData *data) if (virQEMUCapsInitGuestFromBinary(caps, "/usr/bin/qemu-system-i386", qemuCaps, - NULL, - NULL, + "/usr/bin/qemu-system-i386", + qemuCaps, data->guestarch) < 0) { fprintf(stderr, "failed to create the capabilities from qemu"); goto error; -- 2.0.5

On Wed, Mar 25, 2015 at 10:50:52AM +0100, Pavel Hrdina wrote:
Function virQEMUCapsInitGuestFromBinary detect kvm support by testing whether /dev/kvm exists or whether we pass path to kvmbin. Provide the path we are testing via kvmbin for testing purpose instead of detecting presence of /dev/kvm to successfully run the tests on all hosts.
Signed-off-by: Pavel Hrdina <phrdina@redhat.com> --- tests/qemucaps2xmltest.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
ACK Jan

On Wed, Mar 25, 2015 at 12:12:20PM +0100, Ján Tomko wrote:
On Wed, Mar 25, 2015 at 10:50:52AM +0100, Pavel Hrdina wrote:
Function virQEMUCapsInitGuestFromBinary detect kvm support by testing whether /dev/kvm exists or whether we pass path to kvmbin. Provide the path we are testing via kvmbin for testing purpose instead of detecting presence of /dev/kvm to successfully run the tests on all hosts.
Signed-off-by: Pavel Hrdina <phrdina@redhat.com> --- tests/qemucaps2xmltest.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
ACK
Jan
Thanks, pushed now. Pavel

Hi, On Wed, Mar 25, 2015 at 12:29:41PM +0100, Pavel Hrdina wrote:
On Wed, Mar 25, 2015 at 12:12:20PM +0100, Ján Tomko wrote:
On Wed, Mar 25, 2015 at 10:50:52AM +0100, Pavel Hrdina wrote:
Function virQEMUCapsInitGuestFromBinary detect kvm support by testing whether /dev/kvm exists or whether we pass path to kvmbin. Provide the path we are testing via kvmbin for testing purpose instead of detecting presence of /dev/kvm to successfully run the tests on all hosts.
Signed-off-by: Pavel Hrdina <phrdina@redhat.com> --- tests/qemucaps2xmltest.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
ACK
Jan
Thanks, pushed now.
According to Testbuild: http://honk.sigxcpu.org:8001/job/libvirt-check/3300/consoleFull SourceBuild http://honk.sigxcpu.org:8001/job/libvirt-build/3730/ this broke on Debian Wheezy like: TEST: qemucaps2xmltest 1) all_1.6.0-1 ... Offset 280 Expect [ <domain type='kvm'> <emulator>/usr/bin/qemu-system-i386</emulator> </domain> <] Actual [<] ... FAILED 2) nodisksnapshot_1.6.0-1 ... Offset 280 Expect [ <domain type='kvm'> <emulator>/usr/bin/qemu-system-i386</emulator> </domain> <] Actual [<] ... FAILED FAIL: qemucaps2xmltest I didn't get a chance to look into this in any detail yet. Any idea what went wrong? Cheers, -- Guido

Hi, On Wed, Mar 25, 2015 at 03:24:53PM +0100, Guido Günther wrote:
Hi, On Wed, Mar 25, 2015 at 12:29:41PM +0100, Pavel Hrdina wrote:
On Wed, Mar 25, 2015 at 12:12:20PM +0100, Ján Tomko wrote:
On Wed, Mar 25, 2015 at 10:50:52AM +0100, Pavel Hrdina wrote:
Function virQEMUCapsInitGuestFromBinary detect kvm support by testing whether /dev/kvm exists or whether we pass path to kvmbin. Provide the path we are testing via kvmbin for testing purpose instead of detecting presence of /dev/kvm to successfully run the tests on all hosts.
Signed-off-by: Pavel Hrdina <phrdina@redhat.com> --- tests/qemucaps2xmltest.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
ACK
Jan
Thanks, pushed now.
According to
Testbuild: http://honk.sigxcpu.org:8001/job/libvirt-check/3300/consoleFull SourceBuild http://honk.sigxcpu.org:8001/job/libvirt-build/3730/
this broke on Debian Wheezy like:
TEST: qemucaps2xmltest 1) all_1.6.0-1 ... Offset 280 Expect [ <domain type='kvm'> <emulator>/usr/bin/qemu-system-i386</emulator> </domain> <] Actual [<] ... FAILED 2) nodisksnapshot_1.6.0-1 ... Offset 280 Expect [ <domain type='kvm'> <emulator>/usr/bin/qemu-system-i386</emulator> </domain> <] Actual [<] ... FAILED FAIL: qemucaps2xmltest
I didn't get a chance to look into this in any detail yet. Any idea what went wrong?
Just for the record: this got fixed by eb05cb0d5c4ab013622a3695bcd60b72eeaa7dfe with logs at http://honk.sigxcpu.org:8001/job/libvirt-check/3324/ Cheers, -- Guido
participants (3)
-
Guido Günther
-
Ján Tomko
-
Pavel Hrdina