[gtk+] testsuite/builder: Use g_assert_no_error to check GError



commit f00ccd32592335d49ed59dcac9375b6fd16e9293
Author: Timm Bäder <mail baedert org>
Date:   Sun Jan 8 12:02:48 2017 +0100

    testsuite/builder: Use g_assert_no_error to check GError
    
    So we get a proper error message.

 testsuite/gtk/builder.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)
---
diff --git a/testsuite/gtk/builder.c b/testsuite/gtk/builder.c
index 327bc9b..24c43b6 100644
--- a/testsuite/gtk/builder.c
+++ b/testsuite/gtk/builder.c
@@ -1945,8 +1945,7 @@ test_add_objects (void)
   error = NULL;
   builder = gtk_builder_new ();
   ret = gtk_builder_add_objects_from_string (builder, buffer, -1, objects, &error);
-  g_assert (ret);
-  g_assert (error == NULL);
+  g_assert_no_error (error);
   obj = gtk_builder_get_object (builder, "window");
   g_assert (obj == NULL);
   obj = gtk_builder_get_object (builder, "window2");


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]