qemu-block
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-block] [PATCH v3 1/2] iotest 033: add misaligned write-zeroes


From: Eric Blake
Subject: Re: [Qemu-block] [PATCH v3 1/2] iotest 033: add misaligned write-zeroes test via truncate
Date: Wed, 14 Feb 2018 12:31:55 -0600
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0

On 02/14/2018 10:09 AM, Anton Nefedov wrote:
This new test case only makes sense for qcow2 while iotest 033 is generic;
however it matches the test purpose perfectly and also 033 contains those
do_test() tricks to pass the alignment, which won't look nice being
duplicated in other tests or moved to the common code.

Signed-off-by: Anton Nefedov <address@hidden>
---
  tests/qemu-iotests/033     | 29 +++++++++++++++++++++++++++++
  tests/qemu-iotests/033.out | 13 +++++++++++++
  2 files changed, 42 insertions(+)


+# only interested in qcow2 here; also other formats might respond with
+#  "not supported" error message
+if [ $IMGFMT = "qcow2" ]; then
+    do_test 512 "truncate $L2_COVERAGE" "$TEST_IMG" | _filter_qemu_io
+fi

But without an else branch that echoes the same text as the if branch generates, your .out file is now broken for other image formats. Or does 'qemu-io -c truncate' not produce output?

/me goes and tests...

Okay, looks like truncate is silent; and that the truncation (or skipping of the truncation) doesn't affect things.

Tested-by: Eric Blake <address@hidden>

--
Eric Blake, Principal Software Engineer
Red Hat, Inc.           +1-919-301-3266
Virtualization:  qemu.org | libvirt.org



reply via email to

[Prev in Thread] Current Thread [Next in Thread]