Some test cases require a real definition and thus parse a XML with the
definition to obtain it. Convert the code to use real capabilities and
switch to x86_64.
Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
<currentMemory unit='KiB'>219136</currentMemory>
<vcpu placement='static'>1</vcpu>
<os>
- <type arch='i686' machine='pc'>hvm</type>
+ <type arch='x86_64' machine='pc'>hvm</type>
<boot dev='hd'/>
</os>
<clock offset='utc'/>
<on_reboot>restart</on_reboot>
<on_crash>destroy</on_crash>
<devices>
- <emulator>/usr/bin/qemu-system-i386</emulator>
+ <emulator>/usr/bin/qemu-system-x86_64</emulator>
<disk type='file' device='disk'>
<source file='/tmp/idedisk.img'/>
<target dev='hdc' bus='ide'/>
static int
mymain(void)
{
+ g_autoptr(GHashTable) capslatest = testQemuGetLatestCaps();
+ g_autoptr(GHashTable) capscache = virHashNew(virObjectUnref);
int ret = 0;
if (qemuTestDriverInit(&driver) < 0)
return EXIT_FAILURE;
+ /* Some test cases need a real definition thus parse a XML. We need
+ * qemu capabilities for that. */
+ if (testQemuInsertRealCaps(driver.qemuCapsCache, "x86_64", "latest", "",
+ capslatest, capscache, NULL, NULL) < 0)
+ return EXIT_FAILURE;
+
virEventRegisterDefaultImpl();
#define DO_TEST(name) \