qemu with hax to log dma reads & writes jcs.org/2018/11/12/vfio

iotests: Fix cleanup path in some tests

Some iotests leave behind some external data file when run for qcow2
with -o data_file. Fix that.

Signed-off-by: Max Reitz <mreitz@redhat.com>
Message-Id: <20200224171631.384314-1-mreitz@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Signed-off-by: Max Reitz <mreitz@redhat.com>

+8 -1
+1
tests/qemu-iotests/085
··· 39 39 _cleanup() 40 40 { 41 41 _cleanup_qemu 42 + _cleanup_test_img 42 43 for i in $(seq 1 ${SNAPSHOTS}) 43 44 do 44 45 _rm_test_img "${TEST_DIR}/${i}-${snapshot_virt0}"
+6
tests/qemu-iotests/087
··· 26 26 27 27 status=1 # failure is the default! 28 28 29 + _cleanup() 30 + { 31 + _cleanup_test_img 32 + } 33 + trap "_cleanup; exit \$status" 0 1 2 3 15 34 + 29 35 # get standard environment, filters and checks 30 36 . ./common.rc 31 37 . ./common.filter
+1 -1
tests/qemu-iotests/279
··· 26 26 _cleanup() 27 27 { 28 28 _cleanup_test_img 29 - rm -f "$TEST_IMG.mid" 29 + _rm_test_img "$TEST_IMG.mid" 30 30 } 31 31 trap "_cleanup; exit \$status" 0 1 2 3 15 32 32