summaryrefslogtreecommitdiffstats
path: root/tests/libqtest.h
diff options
context:
space:
mode:
Diffstat (limited to 'tests/libqtest.h')
-rw-r--r--tests/libqtest.h24
1 files changed, 9 insertions, 15 deletions
diff --git a/tests/libqtest.h b/tests/libqtest.h
index cadf1d4a03..7833148358 100644
--- a/tests/libqtest.h
+++ b/tests/libqtest.h
@@ -666,7 +666,8 @@ static inline void qtest_end(void)
QDict *qmp(const char *fmt, ...) GCC_FMT_ATTR(1, 2);
/**
- * qmp_assert_success:
+ * qtest_qmp_assert_success:
+ * @qts: QTestState instance to operate on
* @fmt...: QMP message to send to qemu, formatted like
* qobject_from_jsonf_nofail(). See parse_escape() for what's
* supported after '%'.
@@ -674,7 +675,8 @@ QDict *qmp(const char *fmt, ...) GCC_FMT_ATTR(1, 2);
* Sends a QMP message to QEMU and asserts that a 'return' key is present in
* the response.
*/
-void qmp_assert_success(const char *fmt, ...) GCC_FMT_ATTR(1, 2);
+void qtest_qmp_assert_success(QTestState *qts, const char *fmt, ...)
+ GCC_FMT_ATTR(2, 3);
/*
* qmp_eventwait:
@@ -688,16 +690,6 @@ static inline void qmp_eventwait(const char *event)
}
/**
- * hmp:
- * @fmt...: HMP command to send to QEMU, formats arguments like sprintf().
- *
- * Send HMP command to QEMU via QMP's human-monitor-command.
- *
- * Returns: the command's output. The caller should g_free() it.
- */
-char *hmp(const char *fmt, ...) GCC_FMT_ATTR(1, 2);
-
-/**
* get_irq:
* @num: Interrupt to observe.
*
@@ -956,6 +948,7 @@ void qtest_cb_for_every_machine(void (*cb)(const char *machine),
/**
* qtest_qmp_device_add:
+ * @qts: QTestState instance to operate on
* @driver: Name of the device that should be added
* @id: Identification string
* @fmt...: QMP message to send to qemu, formatted like
@@ -964,16 +957,17 @@ void qtest_cb_for_every_machine(void (*cb)(const char *machine),
*
* Generic hot-plugging test via the device_add QMP command.
*/
-void qtest_qmp_device_add(const char *driver, const char *id, const char *fmt,
- ...) GCC_FMT_ATTR(3, 4);
+void qtest_qmp_device_add(QTestState *qts, const char *driver, const char *id,
+ const char *fmt, ...) GCC_FMT_ATTR(4, 5);
/**
* qtest_qmp_device_del:
+ * @qts: QTestState instance to operate on
* @id: Identification string
*
* Generic hot-unplugging test via the device_del QMP command.
*/
-void qtest_qmp_device_del(const char *id);
+void qtest_qmp_device_del(QTestState *qts, const char *id);
/**
* qmp_rsp_is_err: