[lasem] tests: better use of GTest API



commit c2da9144d8a7171d5c2933ba80b44e386af6829e
Author: Emmanuel Pacaud <emmanuel gnome org>
Date:   Sun Feb 15 23:40:32 2015 +0100

    tests: better use of GTest API

 tests/suite.c |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/tests/suite.c b/tests/suite.c
index 87e83a1..6f93f84 100644
--- a/tests/suite.c
+++ b/tests/suite.c
@@ -82,10 +82,10 @@ render_test (gconstpointer user_data)
        if (cairo_status (cairo) == CAIRO_STATUS_SUCCESS) {
                lsm_dom_view_render (LSM_DOM_VIEW (view), cairo, 1, 1);
 
-               if (!g_key_file_get_boolean (suite_options, basename, "ignore-cairo-status", NULL)) {
-                       if (cairo_status (cairo) != CAIRO_STATUS_SUCCESS)
-                               printf ("cairo_status = %s\n", cairo_status_to_string (cairo_status (cairo)));
-                       g_assert (cairo_status (cairo) == CAIRO_STATUS_SUCCESS);
+               if (cairo_status (cairo) != CAIRO_STATUS_SUCCESS) {
+                       g_test_message ("cairo_status = %s", cairo_status_to_string (cairo_status (cairo)));
+                       if (!g_key_file_get_boolean (suite_options, basename, "ignore-cairo-status", NULL))
+                               g_test_fail ();
                }
        }
 


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