[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 02/14] iotests: replace calls to log(qemu_io(...)) with qemu_io_lo
From: |
Hanna Reitz |
Subject: |
[PULL 02/14] iotests: replace calls to log(qemu_io(...)) with qemu_io_log() |
Date: |
Mon, 25 Apr 2022 16:08:09 +0200 |
From: John Snow <jsnow@redhat.com>
This makes these callsites a little simpler, but the real motivation is
a forthcoming commit will change the return type of qemu_io(), so removing
users of the return value now is helpful.
Signed-off-by: John Snow <jsnow@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Reviewed-by: Hanna Reitz <hreitz@redhat.com>
Message-Id: <20220418211504.943969-2-jsnow@redhat.com>
Signed-off-by: Hanna Reitz <hreitz@redhat.com>
---
tests/qemu-iotests/242 | 6 +++---
tests/qemu-iotests/255 | 4 +---
tests/qemu-iotests/303 | 4 ++--
3 files changed, 6 insertions(+), 8 deletions(-)
diff --git a/tests/qemu-iotests/242 b/tests/qemu-iotests/242
index b3afd36d72..c89f0c6cb3 100755
--- a/tests/qemu-iotests/242
+++ b/tests/qemu-iotests/242
@@ -22,8 +22,8 @@
import iotests
import json
import struct
-from iotests import qemu_img_create, qemu_io, qemu_img_info, \
- file_path, img_info_log, log, filter_qemu_io
+from iotests import qemu_img_create, qemu_io_log, qemu_img_info, \
+ file_path, img_info_log, log
iotests.script_initialize(supported_fmts=['qcow2'],
supported_protocols=['file'],
@@ -61,7 +61,7 @@ def add_bitmap(bitmap_number, persistent, disabled):
def write_to_disk(offset, size):
write = 'write {} {}'.format(offset, size)
- log(qemu_io('-c', write, disk), filters=[filter_qemu_io])
+ qemu_io_log('-c', write, disk)
def toggle_flag(offset):
diff --git a/tests/qemu-iotests/255 b/tests/qemu-iotests/255
index f86fa851b6..88b29d64b4 100755
--- a/tests/qemu-iotests/255
+++ b/tests/qemu-iotests/255
@@ -95,9 +95,7 @@ with iotests.FilePath('src.qcow2') as src_path, \
iotests.qemu_img_create('-f', iotests.imgfmt, src_path, size_str)
iotests.qemu_img_create('-f', iotests.imgfmt, dst_path, size_str)
- iotests.log(iotests.qemu_io('-f', iotests.imgfmt, '-c', 'write 0 1M',
- src_path),
- filters=[iotests.filter_test_dir, iotests.filter_qemu_io])
+ iotests.qemu_io_log('-f', iotests.imgfmt, '-c', 'write 0 1M', src_path),
vm.add_object('throttle-group,x-bps-read=4096,id=throttle0')
diff --git a/tests/qemu-iotests/303 b/tests/qemu-iotests/303
index 40e947f26c..a8cc6a23df 100755
--- a/tests/qemu-iotests/303
+++ b/tests/qemu-iotests/303
@@ -21,7 +21,7 @@
import iotests
import subprocess
-from iotests import qemu_img_create, qemu_io, file_path, log, filter_qemu_io, \
+from iotests import qemu_img_create, qemu_io_log, file_path, log, \
verify_qcow2_zstd_compression
iotests.script_initialize(supported_fmts=['qcow2'],
@@ -45,7 +45,7 @@ def create_bitmap(bitmap_number, disabled):
def write_to_disk(offset, size):
write = f'write {offset} {size}'
- log(qemu_io('-c', write, disk), filters=[filter_qemu_io])
+ qemu_io_log('-c', write, disk)
def add_bitmap(num, begin, end, disabled):
--
2.35.1
- [PULL 00/14] Block patches, Hanna Reitz, 2022/04/25
- [PULL 01/14] block: add 'force' parameter to 'blockdev-change-medium' command, Hanna Reitz, 2022/04/25
- [PULL 02/14] iotests: replace calls to log(qemu_io(...)) with qemu_io_log(),
Hanna Reitz <=
- [PULL 03/14] iotests/163: Fix broken qemu-io invocation, Hanna Reitz, 2022/04/25
- [PULL 04/14] iotests: Don't check qemu_io() output for specific error strings, Hanna Reitz, 2022/04/25
- [PULL 05/14] iotests/040: Don't check image pattern on zero-length image, Hanna Reitz, 2022/04/25
- [PULL 06/14] iotests/040: Fix TestCommitWithFilters test, Hanna Reitz, 2022/04/25
- [PULL 07/14] iotests: create generic qemu_tool() function, Hanna Reitz, 2022/04/25
- [PULL 09/14] iotests/migration-permissions: use assertRaises() for qemu_io() negative test, Hanna Reitz, 2022/04/25
- [PULL 08/14] iotests: rebase qemu_io() on top of qemu_tool(), Hanna Reitz, 2022/04/25
- [PULL 10/14] iotests/image-fleecing: switch to qemu_io(), Hanna Reitz, 2022/04/25
- [PULL 12/14] iotests: remove qemu_io_silent() and qemu_io_silent_check()., Hanna Reitz, 2022/04/25
- [PULL 13/14] iotests: make qemu_io_log() check return codes by default, Hanna Reitz, 2022/04/25