[gjs/wip/xulrunner-1.9.3-rebase4: 6/16] tests: Make return code error more informative



commit 19ad488ee9de0a77c7bfedd0b17cf563bdeb1c09
Author: Colin Walters <walters verbum org>
Date:   Mon Sep 20 13:54:06 2010 -0400

    tests: Make return code error more informative

 test/gjs-unit.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/test/gjs-unit.c b/test/gjs-unit.c
index 815a216..51e7a2a 100644
--- a/test/gjs-unit.c
+++ b/test/gjs-unit.c
@@ -89,7 +89,9 @@ test(GjsTestJSFixture *fix,
     if (!success)
         g_error("%s", error->message);
     g_assert(error == NULL);
-    g_assert_cmpint(code, ==, 0);
+    if (code != 0) {
+        g_error("Test script returned code %d; assertions will be in gjs.log", code);
+    }
 }
 
 static GSList *



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