]> git.proxmox.com Git - mirror_qemu.git/commit
qemu-iotests: 148: properly skip test if quorum support is missing
authorSascha Silbe <silbe@linux.vnet.ibm.com>
Tue, 5 Apr 2016 09:21:46 +0000 (11:21 +0200)
committerMax Reitz <mreitz@redhat.com>
Tue, 12 Apr 2016 16:07:39 +0000 (18:07 +0200)
commit3f647b510f1f68e549425cd9671b1aa63c93ec3c
tree47bd70e425ec30546a7f145af6e220e681682eee
parentc1c71e49bcf8a0e6f5ba2a41845678d4954c8106
qemu-iotests: 148: properly skip test if quorum support is missing

qemu-iotests test case 148 already had some code for skipping the test
if quorum support is missing, but it didn't work in all
cases. TestQuorumEvents.setUp() gets run before the actual test class
(which contains the skipping code) and tries to start qemu with a drive
using the quorum driver. For some reason this works fine when using
qcow2, but fails for raw.

As the entire test case requires quorum, just check for availability
before even starting the test suite. Introduce a verify_quorum()
function in iotests.py for this purpose so future test cases can make
use of it.

Signed-off-by: Sascha Silbe <silbe@linux.vnet.ibm.com>
Reviewed-by: Bo Tu <tubo@linux.vnet.ibm.com>
Message-id: 1459848109-29756-5-git-send-email-silbe@linux.vnet.ibm.com
Reviewed-by: Max Reitz <mreitz@redhat.com>
Signed-off-by: Max Reitz <mreitz@redhat.com>
tests/qemu-iotests/148
tests/qemu-iotests/iotests.py