From: Fabiano Rosas <[email protected]> The dbus-vmstate test is currently non-deterministically emitting a "cleaning up pid" message, followed by the PID of one of the dbus-daemon processes used during the test. This is due to a race between the GTestDBus g_autoptr destructor and a child process that does cleanup when the program ends.
Add calls to g_test_dbus_down() to make the issuance of the SIGTERM to the dbus-daemon deterministic. Signed-off-by: Fabiano Rosas <[email protected]> Reviewed-by: Marc-André Lureau <[email protected]> Message-ID: <[email protected]> --- tests/qtest/dbus-vmstate-test.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/qtest/dbus-vmstate-test.c b/tests/qtest/dbus-vmstate-test.c index 05e598a3e3c..15c35e7c0fa 100644 --- a/tests/qtest/dbus-vmstate-test.c +++ b/tests/qtest/dbus-vmstate-test.c @@ -260,11 +260,12 @@ test_dbus_vmstate(Test *test) qtest_quit(src_qemu); g_bus_unown_name(ownsrcA); g_bus_unown_name(ownsrcB); + g_test_dbus_down(srcbus); g_bus_unown_name(owndstA); if (!test->without_dst_b) { g_bus_unown_name(owndstB); } - + g_test_dbus_down(dstbus); g_main_loop_quit(test->loop); } -- 2.54.0
