From a4df2bae2b84a4cecbe9c1f91c0801dfafd41a44 Mon Sep 17 00:00:00 2001 From: Bastien Nocera Date: Tue, 17 Mar 2020 13:11:54 +0100 Subject: [PATCH] tests: Better failure output for test_dconf_paths Output whether we get an unexpected failure or success, and the values we passed in, to make it easy to pinpoint the failing test. --- tests/testcommon.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/tests/testcommon.c b/tests/testcommon.c index 9ce03e2a..fc7f58bc 100644 --- a/tests/testcommon.c +++ b/tests/testcommon.c @@ -1152,7 +1152,12 @@ test_dconf_paths (void) gboolean result; result = flatpak_dconf_path_is_similar (tests[i].path1, tests[i].path2); - g_assert_cmpint (result, ==, tests[i].result); + if (result != tests[i].result) + g_error ("Unexpected %s: flatpak_dconf_path_is_similar (%s, %s) = %d", + result ? "success" : "failure", + tests[i].path1, + tests[i].path2, + result); } }