Blob Blame Raw
From b1ee83f0ffaac613717792a9681b0f1f79fcc108 Mon Sep 17 00:00:00 2001
From: Max Reitz <mreitz@redhat.com>
Date: Sun, 29 Dec 2013 22:06:55 +0100
Subject: [PATCH 4/8] qemu-iotests: Remaining error propagation adjustments

RH-Author: Max Reitz <mreitz@redhat.com>
Message-id: <1388354817-3013-4-git-send-email-mreitz@redhat.com>
Patchwork-id: 56445
O-Subject: [RHEL-7.0 qemu-kvm PATCH 3/5] qemu-iotests: Remaining error propagation adjustments
Bugzilla: 1004347
RH-Acked-by: Stefan Hajnoczi <stefanha@redhat.com>
RH-Acked-by: Fam Zheng <famz@redhat.com>
RH-Acked-by: Kevin Wolf <kwolf@redhat.com>

BZ: 1004347

This downstream-only patch contains the hunks which have been omitted
when aaf2d00ea8cd6479c5dd15773660e0699472af1c was cherry-picked from
2c78857bf6a9b5d06e17533b8f40fee14e087987, i.e., fixes tests 054 and 060.

Furthermore, this sets the executable bit for the tests 060, 063 and 067
(which, for some reason, have been cleared until now).

Signed-off-by: Max Reitz <mreitz@redhat.com>
---
 tests/qemu-iotests/054.out | 4 ++--
 tests/qemu-iotests/060     | 2 +-
 tests/qemu-iotests/060.out | 3 +--
 tests/qemu-iotests/063     | 0
 tests/qemu-iotests/067     | 0
 5 files changed, 4 insertions(+), 5 deletions(-)
 mode change 100644 => 100755 tests/qemu-iotests/060
 mode change 100644 => 100755 tests/qemu-iotests/063
 mode change 100644 => 100755 tests/qemu-iotests/067

diff --git a/tests/qemu-iotests/060 b/tests/qemu-iotests/060
old mode 100644
new mode 100755
index 65bb09f..9bbc43b
diff --git a/tests/qemu-iotests/063 b/tests/qemu-iotests/063
old mode 100644
new mode 100755
diff --git a/tests/qemu-iotests/067 b/tests/qemu-iotests/067
old mode 100644
new mode 100755

Signed-off-by: Miroslav Rezanina <mrezanin@redhat.com>
---
 tests/qemu-iotests/054.out |    4 ++--
 tests/qemu-iotests/060     |    2 +-
 tests/qemu-iotests/060.out |    3 +--
 3 files changed, 4 insertions(+), 5 deletions(-)

diff --git a/tests/qemu-iotests/054.out b/tests/qemu-iotests/054.out
index 0b2fe30..7161d6e 100644
--- a/tests/qemu-iotests/054.out
+++ b/tests/qemu-iotests/054.out
@@ -1,10 +1,10 @@
 QA output created by 054
 
 creating too large image (1 EB)
-qemu-img: The image size is too large for file format 'qcow2'
+qemu-img: TEST_DIR/t.IMGFMT: The image size is too large for file format 'IMGFMT' (try using a larger cluster size)
 Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1152921504606846976 
 
 creating too large image (1 EB) using qcow2.py
 Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=4294967296 
-qemu-img: Could not open 'TEST_DIR/t.qcow2': File too large
+qemu-img: Could not open 'TEST_DIR/t.qcow2': Image is too big
 *** done
diff --git a/tests/qemu-iotests/060 b/tests/qemu-iotests/060
index 65bb09f..9bbc43b 100644
--- a/tests/qemu-iotests/060
+++ b/tests/qemu-iotests/060
@@ -71,7 +71,7 @@ $QEMU_IO -c "write -P 0x2a 0 512" "$TEST_IMG" | _filter_qemu_io
 ./qcow2.py "$TEST_IMG" dump-header | grep incompatible_features
 
 # Try to open the image R/W (which should fail)
-$QEMU_IO -c "read 0 512" "$TEST_IMG" 2>&1 | _filter_qemu_io | sed -e "s/can't open device .*$/can't open device/"
+$QEMU_IO -c "read 0 512" "$TEST_IMG" 2>&1 | _filter_qemu_io | _filter_testdir | _filter_imgfmt
 
 # Try to open it RO (which should succeed)
 $QEMU_IO -c "read 0 512" -r "$TEST_IMG" | _filter_qemu_io
diff --git a/tests/qemu-iotests/060.out b/tests/qemu-iotests/060.out
index ca4583a..648f743 100644
--- a/tests/qemu-iotests/060.out
+++ b/tests/qemu-iotests/060.out
@@ -11,8 +11,7 @@ incompatible_features     0x0
 qcow2: Preventing invalid write on metadata (overlaps with active L1 table); image marked as corrupt.
 write failed: Input/output error
 incompatible_features     0x2
-qcow2: Image is corrupt; cannot be opened read/write.
-qemu-io: can't open device
+qemu-io: can't open device TEST_DIR/t.IMGFMT: IMGFMT: Image is corrupt; cannot be opened read/write
 no file open, try 'help open'
 read 512/512 bytes at offset 0
 512 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-- 
1.7.1