summaryrefslogtreecommitdiff
path: root/tests/qemu-iotests/071
diff options
context:
space:
mode:
authorKevin Wolf <kwolf@redhat.com>2016-10-07 17:05:04 +0200
committerKevin Wolf <kwolf@redhat.com>2016-10-24 17:54:03 +0200
commit0153d2f50bc2ad3f41810d838fcf66acbf10f07a (patch)
treee72fc58ae6fbb621fce1dc7a9546d0f5f38d183f /tests/qemu-iotests/071
parent170f4b2e5cf43895399f57ca4287f26c713be654 (diff)
downloadqemu-0153d2f50bc2ad3f41810d838fcf66acbf10f07a.tar.gz
qemu-0153d2f50bc2ad3f41810d838fcf66acbf10f07a.tar.bz2
qemu-0153d2f50bc2ad3f41810d838fcf66acbf10f07a.zip
block: Remove "options" indirection from blockdev-add
Now that QAPI supports boxed types, we can have unions at the top level of a command, so let's put our real options directly there for blockdev-add instead of having a single "options" dict that contains the real arguments. blockdev-add is still experimental and we already made substantial changes to the API recently, so we're free to make changes like this one, too. Signed-off-by: Kevin Wolf <kwolf@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Reviewed-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Fam Zheng <famz@redhat.com> Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com> Reviewed-by: Max Reitz <mreitz@redhat.com>
Diffstat (limited to 'tests/qemu-iotests/071')
-rwxr-xr-xtests/qemu-iotests/071118
1 files changed, 51 insertions, 67 deletions
diff --git a/tests/qemu-iotests/071 b/tests/qemu-iotests/071
index 6d0864cff6..48b495513f 100755
--- a/tests/qemu-iotests/071
+++ b/tests/qemu-iotests/071
@@ -107,25 +107,21 @@ run_qemu <<EOF
{ "execute": "qmp_capabilities" }
{ "execute": "blockdev-add",
"arguments": {
- "options": {
- "node-name": "drive0",
- "driver": "file",
- "filename": "$TEST_IMG"
- }
+ "node-name": "drive0",
+ "driver": "file",
+ "filename": "$TEST_IMG"
}
}
{ "execute": "blockdev-add",
"arguments": {
- "options": {
- "driver": "$IMGFMT",
- "node-name": "drive0-debug",
- "file": {
- "driver": "blkdebug",
- "image": "drive0",
- "inject-error": [{
- "event": "l2_load"
- }]
- }
+ "driver": "$IMGFMT",
+ "node-name": "drive0-debug",
+ "file": {
+ "driver": "blkdebug",
+ "image": "drive0",
+ "inject-error": [{
+ "event": "l2_load"
+ }]
}
}
}
@@ -145,26 +141,22 @@ run_qemu <<EOF
{ "execute": "qmp_capabilities" }
{ "execute": "blockdev-add",
"arguments": {
- "options": {
- "node-name": "drive0",
- "driver": "$IMGFMT",
- "file": {
- "driver": "file",
- "filename": "$TEST_IMG"
- }
+ "node-name": "drive0",
+ "driver": "$IMGFMT",
+ "file": {
+ "driver": "file",
+ "filename": "$TEST_IMG"
}
}
}
{ "execute": "blockdev-add",
"arguments": {
- "options": {
- "driver": "blkverify",
- "node-name": "drive0-verify",
- "test": "drive0",
- "raw": {
- "driver": "file",
- "filename": "$TEST_IMG.base"
- }
+ "driver": "blkverify",
+ "node-name": "drive0-verify",
+ "test": "drive0",
+ "raw": {
+ "driver": "file",
+ "filename": "$TEST_IMG.base"
}
}
}
@@ -184,27 +176,23 @@ run_qemu <<EOF
{ "execute": "qmp_capabilities" }
{ "execute": "blockdev-add",
"arguments": {
- "options": {
- "node-name": "drive0",
- "driver": "file",
- "filename": "$TEST_IMG.base"
- }
+ "node-name": "drive0",
+ "driver": "file",
+ "filename": "$TEST_IMG.base"
}
}
{ "execute": "blockdev-add",
"arguments": {
- "options": {
- "driver": "blkverify",
- "node-name": "drive0-verify",
- "test": {
- "driver": "$IMGFMT",
- "file": {
- "driver": "file",
- "filename": "$TEST_IMG"
- }
- },
- "raw": "drive0"
- }
+ "driver": "blkverify",
+ "node-name": "drive0-verify",
+ "test": {
+ "driver": "$IMGFMT",
+ "file": {
+ "driver": "file",
+ "filename": "$TEST_IMG"
+ }
+ },
+ "raw": "drive0"
}
}
{ "execute": "human-monitor-command",
@@ -223,30 +211,26 @@ run_qemu <<EOF
{ "execute": "qmp_capabilities" }
{ "execute": "blockdev-add",
"arguments": {
- "options": {
- "node-name": "drive0",
- "driver": "file",
- "filename": "$TEST_IMG"
- }
+ "node-name": "drive0",
+ "driver": "file",
+ "filename": "$TEST_IMG"
}
}
{ "execute": "blockdev-add",
"arguments": {
- "options": {
- "driver": "$IMGFMT",
- "node-name": "drive0-debug",
- "file": {
- "driver": "blkdebug",
- "image": "drive0",
- "inject-error": [{
- "event": "read_aio",
- "state": 42
- }],
- "set-state": [{
- "event": "write_aio",
- "new_state": 42
- }]
- }
+ "driver": "$IMGFMT",
+ "node-name": "drive0-debug",
+ "file": {
+ "driver": "blkdebug",
+ "image": "drive0",
+ "inject-error": [{
+ "event": "read_aio",
+ "state": 42
+ }],
+ "set-state": [{
+ "event": "write_aio",
+ "new_state": 42
+ }]
}
}
}