Skip to contentSkip to conversation

iotests: Check for quorum support in test 139

PATCH Applied Alberto Garcia 2 participants 2 messages Nov 10, 2015 – Nov 11, 2015

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 iotests: Check for quorum support in test 139

The quorum driver is always built in, but it is disabled during run-time if there's no SHA256 support available (see commit e94867e).

This patch skips the quorum test in iotest 139 in that case.

---
 tests/qemu-iotests/139 | 2 ++
 1 file changed, 2 insertions(+)
tests/qemu-iotests/139 +2 -0
index b5470f7..42f78c7 100644
@@ -400,6 +400,8 @@ class TestBlockdevDel(iotests.QMPTestCase):
         self.checkBlockDriverState('node1', False)
 
     def testQuorum(self):
+        if not 'quorum' in iotests.qemu_img_pipe('--help'):
+            return
         self.addQuorum('quorum0', 'node0', 'node1')
         # We cannot remove the children of a Quorum device
         self.delBlockDriverState('node0', expect_error = True)
Signature · 1 line
2.6.2
Applied
#1 lore raw
Quoted 15 lines · Alberto Garcia

The quorum driver is always built in, but it is disabled during run-time if there's no SHA256 support available (see commit e94867e).

This patch skips the quorum test in iotest 139 in that case.

---
 tests/qemu-iotests/139 | 2 ++
 1 file changed, 2 insertions(+)
tests/qemu-iotests/139 +0 -0
index b5470f7..42f78c7 100644

tests/qemu-iotests/139 class TestBlockdevDel(iotests.QMPTestCase): · line 407

Quoted 8 lines
tests/qemu-iotests/139 +2 -0
@@ -400,6 +400,8 @@ class TestBlockdevDel(iotests.QMPTestCase):
         self.checkBlockDriverState('node1', False)
 
     def testQuorum(self):
+        if not 'quorum' in iotests.qemu_img_pipe('--help'):
+            return
         self.addQuorum('quorum0', 'node0', 'node1')
         # We cannot remove the children of a Quorum device
         self.delBlockDriverState('node0', expect_error = True)

Thanks, applied to my block tree:

https://github.com/XanClic/qemu/commits/block

Max