diff options
| author | Daniel P. Berrangé | 2021-02-04 13:48:32 +0100 |
|---|---|---|
| committer | Dr. David Alan Gilbert | 2021-02-08 12:19:51 +0100 |
| commit | aae12d4baa1304756c073fac34ac53e6445f4fdf (patch) | |
| tree | 0f35b35750fcdb501b7fdb702b1485c1160874e3 /include/exec | |
| parent | migration: introduce a delete_snapshot wrapper (diff) | |
| download | qemu-aae12d4baa1304756c073fac34ac53e6445f4fdf.tar.gz qemu-aae12d4baa1304756c073fac34ac53e6445f4fdf.tar.xz qemu-aae12d4baa1304756c073fac34ac53e6445f4fdf.zip | |
iotests: add support for capturing and matching QMP events
When using the _launch_qemu and _send_qemu_cmd functions from
common.qemu, any QMP events get mixed in with the output from
the commands and responses.
This makes it difficult to write a test case as the ordering
of events in the output is not stable.
This introduces a variable 'capture_events' which can be set
to a list of event names. Any events listed in this variable
will not be printed, instead collected in the $QEMU_EVENTS
environment variable.
A new '_wait_event' function can be invoked to collect events
at a fixed point in time. The function will first pull events
cached in $QEMU_EVENTS variable, and if none are found, will
then read more from QMP.
Reviewed-by: Eric Blake <eblake@redhat.com>
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20210204124834.774401-11-berrange@redhat.com>
Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
Diffstat (limited to 'include/exec')
0 files changed, 0 insertions, 0 deletions
