Previously too much code was disabled in ifdefs, and during
compilation with old libvirt (version < 1.3.x) warning was shown
because of unused test variables.
Change-Id: I631c9446add4ccef068a3c4585f8750a5930f406
Signed-off-by: Radoslaw Jablonski <radoslawx.jablonski@intel.com>
#include "testing.h"
#include "virt.c" /* sic */
-#ifdef HAVE_LIST_ALL_DOMAINS
-
virDomainPtr *domains;
static int setup(void) {
return 0;
}
+#ifdef HAVE_LIST_ALL_DOMAINS
DEF_TEST(get_domain_state_notify) {
if (setup() == 0) {
int n_domains = virConnectListAllDomains(
return 0;
}
+#endif
DEF_TEST(persistent_domains_state_notification) {
if (setup() == 0) {
return 0;
}
-#endif
int main(void) {
#ifdef HAVE_LIST_ALL_DOMAINS
RUN_TEST(get_domain_state_notify);
- RUN_TEST(persistent_domains_state_notification);
#endif
+ RUN_TEST(persistent_domains_state_notification);
END_TEST;
}