diff options
author | Bin Meng <bin.meng@windriver.com> | 2022-10-28 12:57:31 +0800 |
---|---|---|
committer | Thomas Huth <thuth@redhat.com> | 2022-10-28 14:32:09 +0200 |
commit | 69c056fbc0cd57b4b2db7b3e823a9f6945756b38 (patch) | |
tree | b020ecaca9e06b93d4866ffaf24127b7c0ec66d3 /tests/qtest/libqtest.h | |
parent | 1b0f1b14fe26752d628dd71920f4bb63b79765a4 (diff) | |
download | qemu-69c056fbc0cd57b4b2db7b3e823a9f6945756b38.zip qemu-69c056fbc0cd57b4b2db7b3e823a9f6945756b38.tar.gz qemu-69c056fbc0cd57b4b2db7b3e823a9f6945756b38.tar.bz2 |
tests/qtest: libqtest: Introduce qtest_wait_qemu()
Introduce an API for qtest to wait for the QEMU process to terminate.
Suggested-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Signed-off-by: Bin Meng <bin.meng@windriver.com>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20221028045736.679903-7-bin.meng@windriver.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
Diffstat (limited to 'tests/qtest/libqtest.h')
-rw-r--r-- | tests/qtest/libqtest.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/qtest/libqtest.h b/tests/qtest/libqtest.h index 65c040e..91a5f7e 100644 --- a/tests/qtest/libqtest.h +++ b/tests/qtest/libqtest.h @@ -76,6 +76,15 @@ QTestState *qtest_init_without_qmp_handshake(const char *extra_args); QTestState *qtest_init_with_serial(const char *extra_args, int *sock_fd); /** + * qtest_wait_qemu: + * @s: #QTestState instance to operate on. + * + * Wait for the QEMU process to terminate. It is safe to call this function + * multiple times. + */ +void qtest_wait_qemu(QTestState *s); + +/** * qtest_kill_qemu: * @s: #QTestState instance to operate on. * |