[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 25/67] iotests/118: Honor $IMGOPTS
From: |
Max Reitz |
Subject: |
[PATCH 25/67] iotests/118: Honor $IMGOPTS |
Date: |
Tue, 1 Oct 2019 21:46:33 +0200 |
Signed-off-by: Max Reitz <address@hidden>
---
tests/qemu-iotests/118 | 26 +++++++++++++-------------
1 file changed, 13 insertions(+), 13 deletions(-)
diff --git a/tests/qemu-iotests/118 b/tests/qemu-iotests/118
index ea0b326ae0..634a0b6445 100755
--- a/tests/qemu-iotests/118
+++ b/tests/qemu-iotests/118
@@ -23,7 +23,7 @@ import os
import stat
import time
import iotests
-from iotests import qemu_img
+from iotests import create_test_image, remove_test_image
old_img = os.path.join(iotests.test_dir, 'test0.img')
new_img = os.path.join(iotests.test_dir, 'test1.img')
@@ -301,8 +301,8 @@ class TestInitiallyFilled(GeneralChangeTestsBaseClass):
was_empty = False
def setUp(self):
- qemu_img('create', '-f', iotests.imgfmt, old_img, '1440k')
- qemu_img('create', '-f', iotests.imgfmt, new_img, '1440k')
+ create_test_image(old_img, '1440k')
+ create_test_image(new_img, '1440k')
self.vm = iotests.VM()
if self.use_drive:
self.vm.add_drive(old_img, 'media=%s' % self.media, 'none')
@@ -320,8 +320,8 @@ class TestInitiallyFilled(GeneralChangeTestsBaseClass):
def tearDown(self):
self.vm.shutdown()
- os.remove(old_img)
- os.remove(new_img)
+ remove_test_image(old_img)
+ remove_test_image(new_img)
def test_insert_on_filled(self):
result = self.vm.qmp('blockdev-add',
@@ -344,7 +344,7 @@ class TestInitiallyEmpty(GeneralChangeTestsBaseClass):
was_empty = True
def setUp(self):
- qemu_img('create', '-f', iotests.imgfmt, new_img, '1440k')
+ create_test_image(new_img, '1440k')
self.vm = iotests.VM()
if self.use_drive:
self.vm.add_drive(None, 'media=%s' % self.media, 'none')
@@ -358,7 +358,7 @@ class TestInitiallyEmpty(GeneralChangeTestsBaseClass):
def tearDown(self):
self.vm.shutdown()
- os.remove(new_img)
+ remove_test_image(new_img)
def test_remove_on_empty(self):
result = self.vm.qmp('blockdev-open-tray', id=self.device_name)
@@ -394,16 +394,16 @@ class TestChangeReadOnly(ChangeBaseClass):
device_name = 'qdev0'
def setUp(self):
- qemu_img('create', '-f', iotests.imgfmt, old_img, '1440k')
- qemu_img('create', '-f', iotests.imgfmt, new_img, '1440k')
+ create_test_image(old_img, '1440k')
+ create_test_image(new_img, '1440k')
self.vm = iotests.VM()
def tearDown(self):
self.vm.shutdown()
os.chmod(old_img, 0o666)
os.chmod(new_img, 0o666)
- os.remove(old_img)
- os.remove(new_img)
+ remove_test_image(old_img)
+ remove_test_image(new_img)
def test_ro_ro_retain(self):
os.chmod(old_img, 0o444)
@@ -640,7 +640,7 @@ class TestBlockJobsAfterCycle(ChangeBaseClass):
device_name = 'qdev0'
def setUp(self):
- qemu_img('create', '-f', iotests.imgfmt, old_img, '1440K')
+ create_test_image(old_img, '1440k')
self.vm = iotests.VM()
self.vm.add_drive_raw("id=drive0,driver=null-co,if=none")
@@ -674,7 +674,7 @@ class TestBlockJobsAfterCycle(ChangeBaseClass):
def tearDown(self):
self.vm.shutdown()
- os.remove(old_img)
+ remove_test_image(old_img)
try:
os.remove(new_img)
except OSError:
--
2.21.0
- [PATCH 15/67] iotests/030: Honor $IMGOPTS, (continued)
- [PATCH 15/67] iotests/030: Honor $IMGOPTS, Max Reitz, 2019/10/01
- [PATCH 18/67] iotests/044: Honor $IMGOPTS, Max Reitz, 2019/10/01
- [PATCH 16/67] iotests/040: Honor $IMGOPTS, Max Reitz, 2019/10/01
- [PATCH 17/67] iotests/041: Honor $IMGOPTS, Max Reitz, 2019/10/01
- [PATCH 19/67] iotests/045: Honor $IMGOPTS, Max Reitz, 2019/10/01
- [PATCH 21/67] iotests/056: Honor $IMGOPTS, Max Reitz, 2019/10/01
- [PATCH 22/67] iotests/057: Honor $IMGOPTS, Max Reitz, 2019/10/01
- [PATCH 23/67] iotests/065: Honor $IMGOPTS, Max Reitz, 2019/10/01
- [PATCH 20/67] iotests/055: Honor $IMGOPTS, Max Reitz, 2019/10/01
- [PATCH 24/67] iotests/096: Honor $IMGOPTS, Max Reitz, 2019/10/01
- [PATCH 25/67] iotests/118: Honor $IMGOPTS,
Max Reitz <=
- [PATCH 28/67] iotests/132: Honor $IMGOPTS, Max Reitz, 2019/10/01
- [PATCH 26/67] iotests/124: Honor $IMGOPTS, Max Reitz, 2019/10/01
- [PATCH 27/67] iotests/129: Honor $IMGOPTS, Max Reitz, 2019/10/01
- [PATCH 29/67] iotests/139: Honor $IMGOPTS, Max Reitz, 2019/10/01
- [PATCH 30/67] iotests/147: Honor $IMGOPTS, Max Reitz, 2019/10/01
- [PATCH 32/67] iotests/151: Honor $IMGOPTS, Max Reitz, 2019/10/01
- [PATCH 31/67] iotests/148: Honor $IMGOPTS, Max Reitz, 2019/10/01
- [PATCH 33/67] iotests/152: Honor $IMGOPTS, Max Reitz, 2019/10/01
- [PATCH 34/67] iotests/155: Honor $IMGOPTS, Max Reitz, 2019/10/01
- [PATCH 35/67] iotests/163: Honor $IMGOPTS, Max Reitz, 2019/10/01