On 04.03.2020 14:27, Vladimir Sementsov-Ogievskiy wrote:
03.03.2020 16:34, Denis Plotnikov wrote:
The test checks fulfilling qcow2 requiriements for the compression
type feature and zstd compression type operability.
Signed-off-by: Denis Plotnikov
---
tests/qemu-iotests/287 | 127 +
tests/qemu-iotests/287.out | 43 +
tests/qemu-iotests/group | 1 +
3 files changed, 171 insertions(+)
create mode 100755 tests/qemu-iotests/287
create mode 100644 tests/qemu-iotests/287.out
diff --git a/tests/qemu-iotests/287 b/tests/qemu-iotests/287
new file mode 100755
index 00..39cb665c85
--- /dev/null
+++ b/tests/qemu-iotests/287
[..]
+# Test: using zstd compression, write to and read from an image
+echo
+echo "=== Testing reading and writing with zstd ==="
+echo
+
+CLUSTER_SIZE=65536
+IMGOPTS='compression_type=zstd' _make_test_img 64M
As I understand, you should define env variable assignments on the
same line
with _make_test_img so that they be passed to it, like
CLUSTER_SIZE=65536 IMGOPTS='compression_type=zstd' _make_test_img 64M
It works like a regular env variable and can be defined on another line
above.
Anyway, I'll move "CLUSTER_SIZE=65536" to the beginning of the test to
avoid any confusions.
with this:
Reviewed-by: Vladimir Sementsov-Ogievskiy
Thanks for reviewing the series! l'll send v5 with all modifications
shortly.
Denis
+$QEMU_IO -c "write -c -P 0xAC 65536 64k " "$TEST_IMG" | _filter_qemu_io
you may s/65536/64k/
+$QEMU_IO -c "read -P 0xAC 65536 65536 " "$TEST_IMG" | _filter_qemu_io
+$QEMU_IO -c "read -v 131070 8 " "$TEST_IMG" | _filter_qemu_io
+$QEMU_IO -c "read -v 65534 8" "$TEST_IMG" | _filter_qemu_io
+
[..]