If network config does not require dnsmasq then none is spawned.
Having a test case that would still require generating dnsmasq
config is weird and can lead to spurious results. Just fail such
test case.
Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
virNetworkObjSetDef(obj, def);
+ if (!networkNeedsDnsmasq(def)) {
+ VIR_TEST_VERBOSE("spurious request to generate conf files. Would not start dnsmasq in real life scenario");
+ goto fail;
+ }
+
dctx = dnsmasqContextNew(def->name, "/var/lib/libvirt/dnsmasq");
if (dctx == NULL)