[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PULL for-2.0-rc0 13/31] qdev-monitor-test: Don't test huma
From: |
Andreas Färber |
Subject: |
[Qemu-devel] [PULL for-2.0-rc0 13/31] qdev-monitor-test: Don't test human-readable error message |
Date: |
Wed, 12 Mar 2014 22:09:45 +0100 |
From: Markus Armbruster <address@hidden>
Test the error class instead. Expecting a specific message is
fragile. In fact, it broke once already, in commit 75884af. Restore
the test of error member "class" dropped there, and drop the test of
error member "desc".
There are no other tests of "desc" as far as I can tell.
Signed-off-by: Markus Armbruster <address@hidden>
Reviewed-by: Eric Blake <address@hidden>
Reviewed-by: Stefan Hajnoczi <address@hidden>
Signed-off-by: Andreas Färber <address@hidden>
---
tests/qdev-monitor-test.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/tests/qdev-monitor-test.c b/tests/qdev-monitor-test.c
index eefaab8..e20ffd6 100644
--- a/tests/qdev-monitor-test.c
+++ b/tests/qdev-monitor-test.c
@@ -32,9 +32,7 @@ static void test_device_add(void)
"}}");
g_assert(response);
error = qdict_get_qdict(response, "error");
- g_assert_cmpstr(qdict_get_try_str(error, "desc"),
- ==,
- "Device needs media, but drive is empty");
+ g_assert_cmpstr(qdict_get_try_str(error, "class"), ==, "GenericError");
QDECREF(response);
/* Delete the drive */
--
1.8.4.5
- [Qemu-devel] [PULL for-2.0-rc0 00/31] QOM devices patch queue 2014-03-12, Andreas Färber, 2014/03/12
- [Qemu-devel] [PULL for-2.0-rc0 02/31] qdev: Set DeviceClass::hotpluggable default in class_init(), Andreas Färber, 2014/03/12
- [Qemu-devel] [PULL for-2.0-rc0 04/31] qom: Avoid leaking str and bool properties on failure, Andreas Färber, 2014/03/12
- [Qemu-devel] [PULL for-2.0-rc0 07/31] misc/max111x: Create abstract max111x type, Andreas Färber, 2014/03/12
- [Qemu-devel] [PULL for-2.0-rc0 05/31] ssi: Convert legacy SSI_SLAVE -> DEVICE casts, Andreas Färber, 2014/03/12
- [Qemu-devel] [PULL for-2.0-rc0 01/31] qdev: Fix bus dependency of DeviceState::hotpluggable getter, Andreas Färber, 2014/03/12
- [Qemu-devel] [PULL for-2.0-rc0 11/31] spapr-pci: Change the default PCI bus naming, Andreas Färber, 2014/03/12
- [Qemu-devel] [PULL for-2.0-rc0 12/31] qdev-monitor-test: Simplify using g_assert_cmpstr(), Andreas Färber, 2014/03/12
- [Qemu-devel] [PULL for-2.0-rc0 13/31] qdev-monitor-test: Don't test human-readable error message,
Andreas Färber <=
- [Qemu-devel] [PULL for-2.0-rc0 15/31] vl: Use MachineClass instead of global QEMUMachine list, Andreas Färber, 2014/03/12
- [Qemu-devel] [PULL for-2.0-rc0 08/31] misc/max111x: QOM casting sweep, Andreas Färber, 2014/03/12
- [Qemu-devel] [PULL for-2.0-rc0 09/31] ssi: Remove SSI_SLAVE_FROM_QDEV() macro, Andreas Färber, 2014/03/12
- [Qemu-devel] [PULL for-2.0-rc0 06/31] ssi: Convert legacy SSI_BUS -> BUS casts, Andreas Färber, 2014/03/12
- [Qemu-devel] [PULL for-2.0-rc0 03/31] qdev-monitor: Set properties after parent is assigned in device_add, Andreas Färber, 2014/03/12
- [Qemu-devel] [PULL for-2.0-rc0 17/31] qom-test: Test QOM properties, Andreas Färber, 2014/03/12
- [Qemu-devel] [PULL for-2.0-rc0 10/31] block/m25p80: Remove FROM_SSI_SLAVE() usages, Andreas Färber, 2014/03/12
- [Qemu-devel] [PULL for-2.0-rc0 20/31] tests: Add virtio-balloon qtest, Andreas Färber, 2014/03/12
- [Qemu-devel] [PULL for-2.0-rc0 14/31] hw/core: Introduce QEMU machine as QOM object, Andreas Färber, 2014/03/12
- [Qemu-devel] [PULL for-2.0-rc0 19/31] tests: Add virtio-blk qtest, Andreas Färber, 2014/03/12