aboutsummaryrefslogtreecommitdiff
path: root/tests/qemu-iotests/050
diff options
context:
space:
mode:
authorFam Zheng <famz@redhat.com>2015-12-22 10:49:19 +0800
committerMax Reitz <mreitz@redhat.com>2016-01-07 21:30:17 +0100
commitae7e0bf461d2e7e3779c58346ae050d19d149908 (patch)
tree01f511fa8bc8c3acd408e0ea9f1f646413091de9 /tests/qemu-iotests/050
parent1b935e1dc915a853e3d96a58657143bfad8a4012 (diff)
iotests: 050: Use TEST_IMG override instead of "mv"
Signed-off-by: Fam Zheng <famz@redhat.com> Reviewed-by: Max Reitz <mreitz@redhat.com> Message-id: 1450752561-9300-10-git-send-email-famz@redhat.com Signed-off-by: Max Reitz <mreitz@redhat.com>
Diffstat (limited to 'tests/qemu-iotests/050')
-rwxr-xr-xtests/qemu-iotests/0509
1 files changed, 7 insertions, 2 deletions
diff --git a/tests/qemu-iotests/050 b/tests/qemu-iotests/050
index 07802bc49c..13006dd1db 100755
--- a/tests/qemu-iotests/050
+++ b/tests/qemu-iotests/050
@@ -51,14 +51,19 @@ fi
echo
echo "== Creating images =="
+TEST_IMG_SAVE="$TEST_IMG"
+TEST_IMG="$TEST_IMG.old"
+
size=10M
_make_test_img $size
$QEMU_IO -c "write -P 0x40 0 1048576" "$TEST_IMG" | _filter_qemu_io
-mv "$TEST_IMG" "$TEST_IMG.old"
+
+TEST_IMG="$TEST_IMG_SAVE.new"
_make_test_img $size
$QEMU_IO -c "write -P 0x5a 0 1048576" "$TEST_IMG" | _filter_qemu_io
-mv "$TEST_IMG" "$TEST_IMG.new"
+
+TEST_IMG="$TEST_IMG_SAVE"
_make_test_img -b "$TEST_IMG.old" $size
$QEMU_IO -c "write -z 0 1048576" "$TEST_IMG" | _filter_qemu_io