[glib] GDBus tests: change progress noise from "if not quiet" to "if verbose"



commit bced30cfbb9d98fdaf71225bae3330e95ea548fa
Author: Simon McVittie <simon mcvittie collabora co uk>
Date:   Thu May 7 17:36:01 2015 +0100

    GDBus tests: change progress noise from "if not quiet" to "if verbose"
    
    It seems that even after Bug #711796, these can still interfere
    with TAP testing:
    
    PASS: gdbus-proxy-threads 1 /gdbus/proxy/vs-threads
    tap-driver.sh: internal error getting exit status
    tap-driver.sh: fatal: I/O or internal error
    
    Let's shut them up unless --verbose is used (which would be appropriate
    when running them interactively).
    
    Similar symptoms have been seen in Debian:
    https://buildd.debian.org/status/fetch.php?pkg=glib2.0&arch=mipsel&ver=2.39.91-1&stamp=1394394568
    and in Guix:
    https://lists.gnu.org/archive/html/bug-guix/2014-12/msg00002.html
    
    Bug: https://bugzilla.gnome.org/show_bug.cgi?id=725981
    Reviewed-by: Philip Withnall <philip withnall collabora co uk>
    Signed-off-by: Simon McVittie <simon mcvittie collabora co uk>

 gio/tests/gdbus-proxy-threads.c |    4 ++--
 gio/tests/gdbus-threading.c     |    8 ++++----
 2 files changed, 6 insertions(+), 6 deletions(-)
---
diff --git a/gio/tests/gdbus-proxy-threads.c b/gio/tests/gdbus-proxy-threads.c
index 5181a9a..a019efe 100644
--- a/gio/tests/gdbus-proxy-threads.c
+++ b/gio/tests/gdbus-proxy-threads.c
@@ -71,7 +71,7 @@ run_proxy_thread (gpointer data)
       GError *error = NULL;
       GVariant *ret;
 
-      if (!g_test_quiet ())
+      if (g_test_verbose ())
         g_print (".");
 
       proxy = g_dbus_proxy_new_sync (connection,
@@ -232,7 +232,7 @@ test_proxy (void)
   /* TODO: should call session_bus_down() but that requires waiting
    * for all the oustanding method calls to complete...
    */
-  if (!g_test_quiet ())
+  if (g_test_verbose ())
     g_print ("\n");
 }
 
diff --git a/gio/tests/gdbus-threading.c b/gio/tests/gdbus-threading.c
index c62b223..0f5253b 100644
--- a/gio/tests/gdbus-threading.c
+++ b/gio/tests/gdbus-threading.c
@@ -295,7 +295,7 @@ test_sleep_in_thread_func (gpointer _data)
                              (GAsyncReadyCallback) sleep_cb,
                              data);
           g_main_loop_run (data->thread_loop);
-          if (!g_test_quiet ())
+          if (g_test_verbose ())
             g_print ("A");
           //g_debug ("done invoking async (%p)", g_thread_self ());
         }
@@ -313,7 +313,7 @@ test_sleep_in_thread_func (gpointer _data)
                                            -1,
                                            NULL,
                                            &error);
-          if (!g_test_quiet ())
+          if (g_test_verbose ())
             g_print ("S");
           //g_debug ("done invoking sync (%p)", g_thread_self ());
           g_assert_no_error (error);
@@ -408,7 +408,7 @@ test_method_calls_on_proxy (GDBusProxy *proxy)
       g_assert_cmpint (elapsed_msec, >=, 3950);
       g_assert_cmpint (elapsed_msec,  <, 8000);
 
-      if (!g_test_quiet ())
+      if (g_test_verbose ())
         g_print (" ");
     }
 }
@@ -446,7 +446,7 @@ test_method_calls_in_thread (void)
   g_object_unref (proxy);
   g_object_unref (connection);
 
-  if (!g_test_quiet ())
+  if (g_test_verbose ())
     g_print ("\n");
 }
 


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