diff options
Diffstat (limited to 'tests/qemu-iotests/059')
-rwxr-xr-x | tests/qemu-iotests/059 | 34 |
1 files changed, 32 insertions, 2 deletions
diff --git a/tests/qemu-iotests/059 b/tests/qemu-iotests/059 index 279aee6815..10bfbaecec 100755 --- a/tests/qemu-iotests/059 +++ b/tests/qemu-iotests/059 @@ -114,11 +114,41 @@ $QEMU_IMG convert -f qcow2 -O vmdk -o subformat=streamOptimized "$TEST_IMG.qcow2 echo echo "=== Testing monolithicFlat with internally generated JSON file name ===" + +echo '--- blkdebug ---' +# Should work, because bdrv_dirname() works fine with blkdebug IMGOPTS="subformat=monolithicFlat" _make_test_img 64M -$QEMU_IO -c "open -o driver=$IMGFMT,file.driver=blkdebug,file.image.filename=$TEST_IMG,file.inject-error.0.event=read_aio" 2>&1 \ - | _filter_testdir | _filter_imgfmt +$QEMU_IO -c "open -o driver=$IMGFMT,file.driver=blkdebug,file.image.filename=$TEST_IMG,file.inject-error.0.event=read_aio" \ + -c info \ + 2>&1 \ + | _filter_testdir | _filter_imgfmt | _filter_img_info _cleanup_test_img +echo '--- quorum ---' +# Should not work, because bdrv_dirname() does not work with quorum +IMGOPTS="subformat=monolithicFlat" _make_test_img 64M +cp "$TEST_IMG" "$TEST_IMG.orig" + +filename="json:{ + \"driver\": \"$IMGFMT\", + \"file\": { + \"driver\": \"quorum\", + \"children\": [ { + \"driver\": \"file\", + \"filename\": \"$TEST_IMG\" + }, { + \"driver\": \"file\", + \"filename\": \"$TEST_IMG.orig\" + } ], + \"vote-threshold\": 1 + } }" + +filename=$(echo "$filename" | tr '\n' ' ' | sed -e 's/\s\+/ /g') +$QEMU_IMG info "$filename" 2>&1 \ + | sed -e "s/'json:[^']*'/\$QUORUM_FILE/g" \ + | _filter_testdir | _filter_imgfmt | _filter_img_info + + echo echo "=== Testing version 3 ===" _use_sample_img iotest-version3.vmdk.bz2 |