Imported Upstream version 2.67.0
[platform/upstream/glib.git] / gio / tests / gdbus-exit-on-close.c
index c431331..4241fc7 100644 (file)
@@ -5,7 +5,7 @@
  * This library is free software; you can redistribute it and/or
  * modify it under the terms of the GNU Lesser General Public
  * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
+ * version 2.1 of the License, or (at your option) any later version.
  *
  * This library is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -13,9 +13,7 @@
  * Lesser General Public License for more details.
  *
  * You should have received a copy of the GNU Lesser General
- * Public License along with this library; if not, write to the
- * Free Software Foundation, Inc., 59 Temple Place, Suite 330,
- * Boston, MA 02111-1307, USA.
+ * Public License along with this library; if not, see <http://www.gnu.org/licenses/>.
  *
  * Author: David Zeuthen <davidz@redhat.com>
  */
@@ -59,11 +57,9 @@ quit_later_cb (gpointer data G_GNUC_UNUSED)
 {
   g_main_loop_quit (loop);
 
-  return FALSE;
+  return G_SOURCE_REMOVE;
 }
 
-#define VANISHED_PATTERN "*Remote peer vanished with error: Underlying GIOStream returned 0 bytes on an async read (g-io-error-quark, 0). Exiting.*"
-
 static void
 closed_cb (GDBusConnection  *c G_GNUC_UNUSED,
            gboolean          remote_peer_vanished,
@@ -190,15 +186,9 @@ test_exit_on_close (gconstpointer test_data)
 
   if (td->exit_on_close == EXPLICITLY_FALSE ||
       td->who_closes == LOCAL)
-    {
-      g_test_trap_assert_stderr_unmatched (VANISHED_PATTERN);
-      g_test_trap_assert_passed ();
-    }
+    g_test_trap_assert_passed ();
   else
-    {
-      g_test_trap_assert_stderr (VANISHED_PATTERN);
-      g_test_trap_assert_failed();
-    }
+    g_test_trap_assert_failed();
 }
 
 /* ---------------------------------------------------------------------------------------------------- */