diff options
author | Max Reitz | 2019-11-07 17:36:59 +0100 |
---|---|---|
committer | Max Reitz | 2020-01-06 13:43:07 +0100 |
commit | ecb4c1d116634c49aee91680e87d6d89044d2632 (patch) | |
tree | 17fd6e538de9cde8bcf761539e89e9cee252804f | |
parent | iotests: Replace IMGOPTS='' by --no-opts (diff) | |
download | qemu-ecb4c1d116634c49aee91680e87d6d89044d2632.tar.gz qemu-ecb4c1d116634c49aee91680e87d6d89044d2632.tar.xz qemu-ecb4c1d116634c49aee91680e87d6d89044d2632.zip |
iotests: Drop IMGOPTS use in 267
Overwriting IMGOPTS means ignoring all user-supplied options, which is
not what we want. Replace the current IMGOPTS use by a new BACKING_FILE
variable.
Signed-off-by: Max Reitz <mreitz@redhat.com>
Reviewed-by: Maxim Levitsky <mlevitsk@redhat.com>
Message-id: 20191107163708.833192-14-mreitz@redhat.com
Signed-off-by: Max Reitz <mreitz@redhat.com>
-rwxr-xr-x | tests/qemu-iotests/267 | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/tests/qemu-iotests/267 b/tests/qemu-iotests/267 index b823668e29..bd9a5c5524 100755 --- a/tests/qemu-iotests/267 +++ b/tests/qemu-iotests/267 @@ -69,7 +69,11 @@ size=128M run_test() { - _make_test_img $size + if [ -n "$BACKING_FILE" ]; then + _make_test_img -b "$BACKING_FILE" $size + else + _make_test_img $size + fi printf "savevm snap0\ninfo snapshots\nloadvm snap0\n" | run_qemu "$@" | _filter_date } @@ -120,12 +124,12 @@ echo TEST_IMG="$TEST_IMG.base" _make_test_img $size -IMGOPTS="backing_file=$TEST_IMG.base" \ +BACKING_FILE="$TEST_IMG.base" \ run_test -blockdev driver=file,filename="$TEST_IMG.base",node-name=backing-file \ -blockdev driver=file,filename="$TEST_IMG",node-name=file \ -blockdev driver=$IMGFMT,file=file,backing=backing-file,node-name=fmt -IMGOPTS="backing_file=$TEST_IMG.base" \ +BACKING_FILE="$TEST_IMG.base" \ run_test -blockdev driver=file,filename="$TEST_IMG.base",node-name=backing-file \ -blockdev driver=$IMGFMT,file=backing-file,node-name=backing-fmt \ -blockdev driver=file,filename="$TEST_IMG",node-name=file \ @@ -142,7 +146,7 @@ echo echo "=== -blockdev with NBD server on the backing file ===" echo -IMGOPTS="backing_file=$TEST_IMG.base" _make_test_img $size +_make_test_img -b "$TEST_IMG.base" $size cat <<EOF | nbd_server_start unix:$SOCK_DIR/nbd nbd_server_add -w backing-fmt |