[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v2 17/25] iotests/mirror-top-perms: switch to AQMP
From: |
John Snow |
Subject: |
[PATCH v2 17/25] iotests/mirror-top-perms: switch to AQMP |
Date: |
Wed, 15 Dec 2021 14:39:31 -0500 |
Signed-off-by: John Snow <jsnow@redhat.com>
---
Note: I still need to adjust the logging. The problem now is that the
logging messages include the PID of the test process, so they need to be
filtered out. I'll investigate that for a follow-up, or for v2.
I could just add yet another filtering function somewhere, but I think
it's getting out of hand with how many filters and loggers there are, so
I want to give it a slightly more serious treatment instead of a
hackjob.
Signed-off-by: John Snow <jsnow@redhat.com>
---
tests/qemu-iotests/tests/mirror-top-perms | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/tests/qemu-iotests/tests/mirror-top-perms
b/tests/qemu-iotests/tests/mirror-top-perms
index 0a51a613f3..f394931a00 100755
--- a/tests/qemu-iotests/tests/mirror-top-perms
+++ b/tests/qemu-iotests/tests/mirror-top-perms
@@ -23,7 +23,6 @@ import os
from qemu.aqmp import ConnectError
from qemu.machine import machine
-from qemu.qmp import QMPConnectError
import iotests
from iotests import change_log_level, qemu_img
@@ -101,13 +100,13 @@ class TestMirrorTopPerms(iotests.QMPTestCase):
self.vm_b.add_device('virtio-blk,drive=drive0,share-rw=on')
try:
# Silence AQMP errors temporarily.
- # TODO: Remove this and just allow the errors to be logged when
- # AQMP fully replaces QMP.
+ # TODO: Remove change_log_level and allow the errors to be logged.
+ # This necessitates a PID filter on *all* logging output.
with change_log_level('qemu.aqmp'):
self.vm_b.launch()
print('ERROR: VM B launched successfully, '
'this should not have happened')
- except (QMPConnectError, ConnectError):
+ except ConnectError:
assert 'Is another process using the image' in self.vm_b.get_log()
result = self.vm.qmp('block-job-cancel',
--
2.31.1
- [PATCH v2 15/25] scripts/render-block-graph: switch to AQMP, (continued)
- [PATCH v2 15/25] scripts/render-block-graph: switch to AQMP, John Snow, 2021/12/15
- [PATCH v2 16/25] scripts/bench-block-job: switch to AQMP, John Snow, 2021/12/15
- [PATCH v2 18/25] iotests: switch to AQMP, John Snow, 2021/12/15
- [PATCH v2 17/25] iotests/mirror-top-perms: switch to AQMP,
John Snow <=
- [PATCH v2 19/25] python: temporarily silence pylint duplicate-code warnings, John Snow, 2021/12/15
- [PATCH v2 21/25] python/aqmp: fully separate from qmp.QEMUMonitorProtocol, John Snow, 2021/12/15
- [PATCH v2 20/25] python/aqmp: take QMPBadPortError and parse_address from qemu.qmp, John Snow, 2021/12/15