diff --git a/tests/qemucapabilitiestest.c b/tests/qemucapabilitiestest.c index 5a27b3624e..b98f775fd4 100644 --- a/tests/qemucapabilitiestest.c +++ b/tests/qemucapabilitiestest.c @@ -53,7 +53,7 @@ testQemuCaps(const void *opaque) abs_srcdir, data->base, data->archName) < 0) goto cleanup; - if (!(mon = qemuMonitorTestNewFromFile(repliesFile, data->xmlopt))) + if (!(mon = qemuMonitorTestNewFromFile(repliesFile, data->xmlopt, false))) goto cleanup; if (!(capsActual = virQEMUCapsNew()) || diff --git a/tests/qemumonitortestutils.c b/tests/qemumonitortestutils.c index c04663e4c0..c86a27adce 100644 --- a/tests/qemumonitortestutils.c +++ b/tests/qemumonitortestutils.c @@ -930,7 +930,8 @@ qemuMonitorTestNew(bool json, qemuMonitorTestPtr qemuMonitorTestNewFromFile(const char *fileName, - virDomainXMLOptionPtr xmlopt) + virDomainXMLOptionPtr xmlopt, + bool simple) { qemuMonitorTestPtr test = NULL; char *json = NULL; @@ -940,6 +941,9 @@ qemuMonitorTestNewFromFile(const char *fileName, if (virTestLoadFile(fileName, &json) < 0) goto cleanup; + if (simple && !(test = qemuMonitorTestNewSimple(true, xmlopt))) + goto cleanup; + /* Our JSON parser expects replies to be separated by a newline character. * Hence we must preprocess the file a bit. */ tmp = singleReply = json; diff --git a/tests/qemumonitortestutils.h b/tests/qemumonitortestutils.h index c42073787a..8e2f371d7b 100644 --- a/tests/qemumonitortestutils.h +++ b/tests/qemumonitortestutils.h @@ -70,7 +70,8 @@ qemuMonitorTestPtr qemuMonitorTestNew(bool json, const char *greeting); qemuMonitorTestPtr qemuMonitorTestNewFromFile(const char *fileName, - virDomainXMLOptionPtr xmlopt); + virDomainXMLOptionPtr xmlopt, + bool simple); qemuMonitorTestPtr qemuMonitorTestNewAgent(virDomainXMLOptionPtr xmlopt);