diff options
author | Kevin Wolf <kwolf@redhat.com> | 2017-07-12 13:53:03 +0200 |
---|---|---|
committer | Kevin Wolf <kwolf@redhat.com> | 2017-07-18 15:14:36 +0200 |
commit | 208c38e4e4a5e808b5720329f3633f4ab2bc5026 (patch) | |
tree | 4ce7e4487a748b7c09b18f4b4c8caa3f1a9f075b /tests/qemu-iotests/067 | |
parent | e1824e585f54426bd6b035221bf85f90893dc653 (diff) | |
download | qemu-208c38e4e4a5e808b5720329f3633f4ab2bc5026.zip |
qemu-iotests: Test unplug of -device without drive
This caused an assertion failure until recently because the BlockBackend
would be detached on unplug, but was in fact never attached in the first
place. Add a regression test.
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Reviewed-by: John Snow <jsnow@redhat.com>
Diffstat (limited to 'tests/qemu-iotests/067')
-rwxr-xr-x | tests/qemu-iotests/067 | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/tests/qemu-iotests/067 b/tests/qemu-iotests/067 index 38d23fce6b..5d4ca4bc61 100755 --- a/tests/qemu-iotests/067 +++ b/tests/qemu-iotests/067 @@ -137,6 +137,19 @@ run_qemu <<EOF { "execute": "quit" } EOF +echo +echo === Empty drive with -device and device_del === +echo + +run_qemu -device virtio-scsi-pci -device scsi-cd,id=cd0 <<EOF +{ "execute": "qmp_capabilities" } +{ "execute": "query-block" } +{ "execute": "device_del", "arguments": { "id": "cd0" } } +{ "execute": "system_reset" } +{ "execute": "query-block" } +{ "execute": "quit" } +EOF + # success, all done echo "*** done" rm -f $seq.full |