[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-block] [PATCH] iotests: Skip test for ENOMEM error
From: |
Eric Blake |
Subject: |
Re: [Qemu-block] [PATCH] iotests: Skip test for ENOMEM error |
Date: |
Thu, 1 Mar 2018 14:15:20 -0600 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 |
On 02/28/2018 07:14 PM, Fam Zheng wrote:
The AFL image is to exercise the code validating image size, which
doesn't work on 32 bit or when out of memory (there is a large
allocation before the interesting point). So check that and skip the
test, instead of faking the result.
Signed-off-by: Fam Zheng <address@hidden>
---
tests/qemu-iotests/059 | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
Reviewed-by: Eric Blake <address@hidden>
diff --git a/tests/qemu-iotests/059 b/tests/qemu-iotests/059
index 40f89eae18..530bbbe6ce 100755
--- a/tests/qemu-iotests/059
+++ b/tests/qemu-iotests/059
@@ -152,9 +152,8 @@ done
echo
echo "=== Testing afl image with a very large capacity ==="
_use_sample_img afl9.vmdk.bz2
-# The sed makes this test pass on machines with little RAM
-# (and also with 32 bit builds)
-_img_info | sed -e 's/Cannot allocate memory/Invalid argument/'
+_img_info | grep -q 'Cannot allocate memory' && _notrun "Insufficent memory,
skipped test"
+_img_info
_cleanup_test_img
# success, all done
--
Eric Blake, Principal Software Engineer
Red Hat, Inc. +1-919-301-3266
Virtualization: qemu.org | libvirt.org
- Re: [Qemu-block] [PATCH] iotests: Skip test for ENOMEM error,
Eric Blake <=