mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-09-09 17:24:53 +00:00
tests: qemumonitorjson: Do QMP schema validation for DO_TEST_GEN
Test some more QMP commands against the schema. Signed-off-by: Peter Krempa <pkrempa@redhat.com>
This commit is contained in:
parent
b3a0e3aab1
commit
4085984889
@ -1297,7 +1297,7 @@ testQemuMonitorJSON ## funcName(const void *opaque) \
|
|||||||
{ \
|
{ \
|
||||||
const testQemuMonitorJSONSimpleFuncData *data = opaque; \
|
const testQemuMonitorJSONSimpleFuncData *data = opaque; \
|
||||||
virDomainXMLOptionPtr xmlopt = data->xmlopt; \
|
virDomainXMLOptionPtr xmlopt = data->xmlopt; \
|
||||||
qemuMonitorTestPtr test = qemuMonitorTestNewSimple(true, xmlopt); \
|
qemuMonitorTestPtr test = qemuMonitorTestNewSchema(xmlopt, data->schema); \
|
||||||
const char *reply = data->reply; \
|
const char *reply = data->reply; \
|
||||||
int ret = -1; \
|
int ret = -1; \
|
||||||
\
|
\
|
||||||
@ -2894,6 +2894,7 @@ mymain(void)
|
|||||||
|
|
||||||
#define DO_TEST_GEN(name, ...) \
|
#define DO_TEST_GEN(name, ...) \
|
||||||
simpleFunc = (testQemuMonitorJSONSimpleFuncData) {.xmlopt = driver.xmlopt, \
|
simpleFunc = (testQemuMonitorJSONSimpleFuncData) {.xmlopt = driver.xmlopt, \
|
||||||
|
.schema = qapiData.schema \
|
||||||
__VA_ARGS__ }; \
|
__VA_ARGS__ }; \
|
||||||
if (virTestRun(# name, testQemuMonitorJSON ## name, &simpleFunc) < 0) \
|
if (virTestRun(# name, testQemuMonitorJSON ## name, &simpleFunc) < 0) \
|
||||||
ret = -1
|
ret = -1
|
||||||
|
Loading…
Reference in New Issue
Block a user