From: Thomas Huth <[email protected]>
A bunch of tests are currently failing e.g. on FreeBSD like this:
082 fail [13:38:58] [13:38:59] 0.5s output
mismatch (see .../build/tests/qemu-iotests/scratch/qcow2-file-082/082.out.bad)
--- .../src/tests/qemu-iotests/082.out
+++ .../build/tests/qemu-iotests/scratch/qcow2-file-082/082.out.bad
@@ -17,7 +17,7 @@
cluster_size: 4096
Format specific information:
compat: 1.1
- compression type: COMPRESSION_TYPE
+ compression type: zlib
lazy refcounts: true
refcount bits: 16
corrupt: false
This happens because the sed statements require GNU sed. Let's use
gsed in these spots to get it fixed.
Signed-off-by: Thomas Huth <[email protected]>
Reviewed-by: Daniel P. Berrangé <[email protected]>
Reviewed-by: Michael Tokarev <[email protected]>
Signed-off-by: Michael Tokarev <[email protected]>
---
tests/qemu-iotests/286 | 2 +-
tests/qemu-iotests/common.rc | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/tests/qemu-iotests/286 b/tests/qemu-iotests/286
index 38216c2a0e..cc6aacf022 100755
--- a/tests/qemu-iotests/286
+++ b/tests/qemu-iotests/286
@@ -62,7 +62,7 @@ wait=yes _cleanup_qemu
echo 'Output structure:'
$QEMU_IMG snapshot -l "$TEST_IMG" | tail -n 1 | tr -s ' ' \
- | sed -e 's/\S\+/./g' \
+ | gsed -e 's/\S\+/./g' \
| sed -e 's/\./(snapshot ID)/' \
-e 's/\./(snapshot name)/' \
-e 's/\./(VM state size value)/' \
diff --git a/tests/qemu-iotests/common.rc b/tests/qemu-iotests/common.rc
index c0f8f0f8df..731e4b2b99 100644
--- a/tests/qemu-iotests/common.rc
+++ b/tests/qemu-iotests/common.rc
@@ -719,7 +719,7 @@ _img_info()
regex_json_spec_start='^ *"format-specific": \{'
regex_json_child_start='^ *"children": \['
$QEMU_IMG info $QEMU_IMG_EXTRA_ARGS "$@" "$TEST_IMG" 2>&1 | \
- sed -e "s#$REMOTE_TEST_DIR#TEST_DIR#g" \
+ gsed -e "s#$REMOTE_TEST_DIR#TEST_DIR#g" \
-e "s#$IMGPROTO:$TEST_DIR#TEST_DIR#g" \
-e "s#$TEST_DIR#TEST_DIR#g" \
-e "s#$SOCK_DIR/fuse-#TEST_DIR/#g" \
--
2.47.3