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>
This commit is contained in:
parent
10b612565c
commit
ecb4c1d116
@ -69,7 +69,11 @@ size=128M
|
|||||||
|
|
||||||
run_test()
|
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
|
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
|
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 \
|
run_test -blockdev driver=file,filename="$TEST_IMG.base",node-name=backing-file \
|
||||||
-blockdev driver=file,filename="$TEST_IMG",node-name=file \
|
-blockdev driver=file,filename="$TEST_IMG",node-name=file \
|
||||||
-blockdev driver=$IMGFMT,file=file,backing=backing-file,node-name=fmt
|
-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 \
|
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=$IMGFMT,file=backing-file,node-name=backing-fmt \
|
||||||
-blockdev driver=file,filename="$TEST_IMG",node-name=file \
|
-blockdev driver=file,filename="$TEST_IMG",node-name=file \
|
||||||
@ -142,7 +146,7 @@ echo
|
|||||||
echo "=== -blockdev with NBD server on the backing file ==="
|
echo "=== -blockdev with NBD server on the backing file ==="
|
||||||
echo
|
echo
|
||||||
|
|
||||||
IMGOPTS="backing_file=$TEST_IMG.base" _make_test_img $size
|
_make_test_img -b "$TEST_IMG.base" $size
|
||||||
cat <<EOF |
|
cat <<EOF |
|
||||||
nbd_server_start unix:$SOCK_DIR/nbd
|
nbd_server_start unix:$SOCK_DIR/nbd
|
||||||
nbd_server_add -w backing-fmt
|
nbd_server_add -w backing-fmt
|
||||||
|
Loading…
Reference in New Issue
Block a user