Re: [PATCH 02/11] Mark the domain as active in qemuhotplugtest

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 16.12.2014 17:41, Ján Tomko wrote:
This will allow us to call qemuDomainObjIsActive() in
the tested functions to check if the domain has crashed.
---
  tests/qemuhotplugtest.c | 4 ++++
  1 file changed, 4 insertions(+)

diff --git a/tests/qemuhotplugtest.c b/tests/qemuhotplugtest.c
index 9d39968..49e4272 100644
--- a/tests/qemuhotplugtest.c
+++ b/tests/qemuhotplugtest.c
@@ -90,6 +90,8 @@ qemuHotplugCreateObjects(virDomainXMLOptionPtr xmlopt,
      if (qemuAssignDeviceAliases((*vm)->def, priv->qemuCaps) < 0)
          goto cleanup;

+    (*vm)->def->id = 7;
+
      ret = 0;
   cleanup:
      return ret;
@@ -177,9 +179,11 @@ testQemuHotplugCheckResult(virDomainObjPtr vm,
      char *actual;
      int ret;

+    vm->def->id = -1;
      actual = virDomainDefFormat(vm->def, VIR_DOMAIN_XML_SECURE);
      if (!actual)
          return -1;
+    vm->def->id = 7;

      if (STREQ(expected, actual)) {
          if (fail && virTestGetVerbose())


Can you turn the domain ID into a macro?

ACK

Michal

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list





[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]