iotests: Fix 291 across more file systems
Depending on the granularity of holes and amount of metadata consumed by a file, the 'disk size:' number of 'qemu-img info' is not reliable. Adjust our test to use a different set of filters to avoid spurious failures. Reported-by: Kevin Wolf <kwolf@redhat.com> Fixes: cf2d1203dc Signed-off-by: Eric Blake <eblake@redhat.com> Message-Id: <20200608195629.3299649-1-eblake@redhat.com> Acked-by: Kevin Wolf <kwolf@redhat.com> [eblake: fix merge conflict] Signed-off-by: Eric Blake <eblake@redhat.com>
This commit is contained in:
parent
820c6bee53
commit
adf92f4645
@ -79,7 +79,7 @@ echo
|
|||||||
|
|
||||||
# Only bitmaps from the active layer are copied
|
# Only bitmaps from the active layer are copied
|
||||||
$QEMU_IMG convert --bitmaps -O qcow2 "$TEST_IMG.orig" "$TEST_IMG"
|
$QEMU_IMG convert --bitmaps -O qcow2 "$TEST_IMG.orig" "$TEST_IMG"
|
||||||
$QEMU_IMG info "$TEST_IMG" | _filter_img_info --format-specific
|
_img_info --format-specific
|
||||||
# But we can also merge in bitmaps from other layers. This test is a bit
|
# But we can also merge in bitmaps from other layers. This test is a bit
|
||||||
# contrived to cover more code paths, in reality, you could merge directly
|
# contrived to cover more code paths, in reality, you could merge directly
|
||||||
# into b0 without going through tmp
|
# into b0 without going through tmp
|
||||||
@ -89,7 +89,7 @@ $QEMU_IMG bitmap --add --merge b0 -b "$TEST_IMG.base" -F $IMGFMT \
|
|||||||
$QEMU_IMG bitmap --merge tmp -f $IMGFMT "$TEST_IMG" b0
|
$QEMU_IMG bitmap --merge tmp -f $IMGFMT "$TEST_IMG" b0
|
||||||
$QEMU_IMG bitmap --remove --image-opts \
|
$QEMU_IMG bitmap --remove --image-opts \
|
||||||
driver=$IMGFMT,file.driver=file,file.filename="$TEST_IMG" tmp
|
driver=$IMGFMT,file.driver=file,file.filename="$TEST_IMG" tmp
|
||||||
$QEMU_IMG info "$TEST_IMG" | _filter_img_info --format-specific
|
_img_info --format-specific
|
||||||
echo "Check resulting qcow2 header extensions:"
|
echo "Check resulting qcow2 header extensions:"
|
||||||
$PYTHON qcow2.py "$TEST_IMG" dump-header-exts
|
$PYTHON qcow2.py "$TEST_IMG" dump-header-exts
|
||||||
|
|
||||||
|
@ -43,7 +43,7 @@ qemu-img: Format driver 'raw' does not support bitmaps
|
|||||||
image: TEST_DIR/t.IMGFMT
|
image: TEST_DIR/t.IMGFMT
|
||||||
file format: IMGFMT
|
file format: IMGFMT
|
||||||
virtual size: 10 MiB (10485760 bytes)
|
virtual size: 10 MiB (10485760 bytes)
|
||||||
disk size: 4.39 MiB
|
cluster_size: 65536
|
||||||
Format specific information:
|
Format specific information:
|
||||||
compat: 1.1
|
compat: 1.1
|
||||||
compression type: zlib
|
compression type: zlib
|
||||||
@ -63,7 +63,7 @@ Format specific information:
|
|||||||
image: TEST_DIR/t.IMGFMT
|
image: TEST_DIR/t.IMGFMT
|
||||||
file format: IMGFMT
|
file format: IMGFMT
|
||||||
virtual size: 10 MiB (10485760 bytes)
|
virtual size: 10 MiB (10485760 bytes)
|
||||||
disk size: 4.48 MiB
|
cluster_size: 65536
|
||||||
Format specific information:
|
Format specific information:
|
||||||
compat: 1.1
|
compat: 1.1
|
||||||
compression type: zlib
|
compression type: zlib
|
||||||
|
Loading…
x
Reference in New Issue
Block a user