[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 06/20] tests/qtest/migration: Print migration incoming errors
From: |
peterx |
Subject: |
[PULL 06/20] tests/qtest/migration: Print migration incoming errors |
Date: |
Tue, 16 Jan 2024 11:19:33 +0800 |
From: Fabiano Rosas <farosas@suse.de>
We're currently just asserting when incoming migration fails. Let's
print the error message from QMP as well.
Signed-off-by: Fabiano Rosas <farosas@suse.de>
Reviewed-by: Peter Xu <peterx@redhat.com>
Link: 20240104142144.9680-6-farosas@suse.de">https://lore.kernel.org/r/20240104142144.9680-6-farosas@suse.de
Signed-off-by: Peter Xu <peterx@redhat.com>
---
tests/qtest/migration-helpers.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/tests/qtest/migration-helpers.c b/tests/qtest/migration-helpers.c
index 37e8e812c5..19384e3fa6 100644
--- a/tests/qtest/migration-helpers.c
+++ b/tests/qtest/migration-helpers.c
@@ -111,6 +111,12 @@ void migrate_incoming_qmp(QTestState *to, const char *uri,
const char *fmt, ...)
rsp = qtest_qmp(to, "{ 'execute': 'migrate-incoming', 'arguments': %p}",
args);
+
+ if (!qdict_haskey(rsp, "return")) {
+ g_autoptr(GString) s = qobject_to_json_pretty(QOBJECT(rsp), true);
+ g_test_message("%s", s->str);
+ }
+
g_assert(qdict_haskey(rsp, "return"));
qobject_unref(rsp);
--
2.43.0
- [PULL 00/20] Migration 20240116 patches, peterx, 2024/01/15
- [PULL 01/20] migration: Simplify initial conditionals in migration for better readability, peterx, 2024/01/15
- [PULL 02/20] migration/multifd: Remove MultiFDPages_t::packet_num, peterx, 2024/01/15
- [PULL 04/20] migration/multifd: Change multifd_pages_init argument, peterx, 2024/01/15
- [PULL 09/20] tests/qtest: Re-enable multifd cancel test, peterx, 2024/01/15
- [PULL 03/20] migration/multifd: Remove QEMUFile from where it is not needed, peterx, 2024/01/15
- [PULL 06/20] tests/qtest/migration: Print migration incoming errors,
peterx <=
- [PULL 07/20] tests/qtest/migration: Add a wrapper to print test names, peterx, 2024/01/15
- [PULL 08/20] tests/qtest/migration: Use the new migration_test_add, peterx, 2024/01/15
- [PULL 10/20] docs/migration: Create migration/ directory, peterx, 2024/01/15
- [PULL 11/20] docs/migration: Create index page, peterx, 2024/01/15
- [PULL 12/20] docs/migration: Convert virtio.txt into rST, peterx, 2024/01/15
- [PULL 14/20] docs/migration: Split "Debugging" and "Firmware", peterx, 2024/01/15
- [PULL 13/20] docs/migration: Split "Backwards compatibility" separately, peterx, 2024/01/15
- [PULL 15/20] docs/migration: Split "Postcopy", peterx, 2024/01/15
- [PULL 17/20] docs/migration: Organize "Postcopy" page, peterx, 2024/01/15
- [PULL 16/20] docs/migration: Split "dirty limit", peterx, 2024/01/15