diff mbox series

[38/67] iotests/194: Honor $IMGOPTS

Message ID 20191001194715.2796-39-mreitz@redhat.com
State New
Headers show
Series iotests: Honor $IMGOPTS in Python tests | expand

Commit Message

Max Reitz Oct. 1, 2019, 7:46 p.m. UTC
Signed-off-by: Max Reitz <mreitz@redhat.com>
---
 tests/qemu-iotests/194 | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)
diff mbox series

Patch

diff --git a/tests/qemu-iotests/194 b/tests/qemu-iotests/194
index c8aeb6d0e4..70cae2d8ef 100755
--- a/tests/qemu-iotests/194
+++ b/tests/qemu-iotests/194
@@ -20,19 +20,20 @@ 
 # Non-shared storage migration test using NBD server and drive-mirror
 
 import iotests
+from iotests import create_test_image
 
 iotests.script_initialize(supported_fmts=['qcow2', 'qed', 'raw'])
 
-with iotests.FilePath('source.img') as source_img_path, \
-     iotests.FilePath('dest.img') as dest_img_path, \
+with iotests.ImagePath('source.img') as source_img_path, \
+     iotests.ImagePath('dest.img') as dest_img_path, \
      iotests.FilePath('migration.sock') as migration_sock_path, \
      iotests.FilePath('nbd.sock') as nbd_sock_path, \
      iotests.VM('source') as source_vm, \
      iotests.VM('dest') as dest_vm:
 
     img_size = '1G'
-    iotests.qemu_img_pipe('create', '-f', iotests.imgfmt, source_img_path, img_size)
-    iotests.qemu_img_pipe('create', '-f', iotests.imgfmt, dest_img_path, img_size)
+    create_test_image(source_img_path, img_size)
+    create_test_image(dest_img_path, img_size)
 
     iotests.log('Launching VMs...')
     (source_vm.add_drive(source_img_path)