]> git.proxmox.com Git - mirror_qemu.git/commitdiff
iotest: Fix 241 to run in generic directory
authorEric Blake <eblake@redhat.com>
Wed, 10 Apr 2019 20:42:17 +0000 (15:42 -0500)
committerKevin Wolf <kwolf@redhat.com>
Fri, 12 Apr 2019 16:03:01 +0000 (18:03 +0200)
Filter the qemu-nbd server output to get rid of a direct reference
to my build directory.

Fixes: e9dce9cb
Reported-by: Max Reitz <mreitz@redhat.com>
Signed-off-by: Eric Blake <eblake@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
tests/qemu-iotests/241
tests/qemu-iotests/241.out

index 4b196857387b3253e60538a7bef97b84e71f7ba2..017a736aabaddb79ee78aef2636613a8762e215a 100755 (executable)
@@ -28,6 +28,7 @@ nbd_unix_socket=$TEST_DIR/test_qemu_nbd_socket
 _cleanup()
 {
     _cleanup_test_img
+    rm -f "$TEST_DIR/server.log"
     nbd_server_stop
 }
 trap "_cleanup; exit \$status" 0 1 2 3 15
@@ -69,12 +70,13 @@ echo
 
 # Intentionally omit '-f' to force image probing, which in turn forces
 # sector alignment, here at the server.
-nbd_server_start_unix_socket "$TEST_IMG_FILE"
+nbd_server_start_unix_socket "$TEST_IMG_FILE" 2> "$TEST_DIR/server.log"
 
 $QEMU_NBD_PROG --list -k $nbd_unix_socket | grep '\(size\|min\)'
 $QEMU_IMG map -f raw --output=json "$TEST_IMG" | _filter_qemu_img_map
 $QEMU_IO -f raw -c map "$TEST_IMG"
 nbd_server_stop
+cat "$TEST_DIR/server.log" | _filter_testdir
 
 echo
 echo "=== Exporting unaligned raw image, forced client sector alignment ==="
index f481074a02eb8216db45a61bc9fb89354ae211c7..75f9f465e522c416cf24e1d176f9216bef8d80bb 100644 (file)
@@ -10,13 +10,13 @@ QA output created by 241
 
 === Exporting unaligned raw image, forced server sector alignment ===
 
-WARNING: Image format was not specified for '/home/eblake/qemu/tests/qemu-iotests/scratch/t.raw' and probing guessed raw.
-         Automatically detecting the format is dangerous for raw images, write operations on block 0 will be restricted.
-         Specify the 'raw' format explicitly to remove the restrictions.
   size:  1024
   min block: 512
 [{ "start": 0, "length": 1024, "depth": 0, "zero": false, "data": true, "offset": OFFSET}]
 1 KiB (0x400) bytes     allocated at offset 0 bytes (0x0)
+WARNING: Image format was not specified for 'TEST_DIR/t.raw' and probing guessed raw.
+         Automatically detecting the format is dangerous for raw images, write operations on block 0 will be restricted.
+         Specify the 'raw' format explicitly to remove the restrictions.
 
 === Exporting unaligned raw image, forced client sector alignment ===