mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-03-03 14:42:10 +01:00
Use the C gdbus-testserver in tests
This commit is contained in:
parent
416fa3b9ef
commit
663ed23bc5
@ -121,7 +121,7 @@ main (int argc,
|
|||||||
session_bus_up ();
|
session_bus_up ();
|
||||||
|
|
||||||
/* this is safe; testserver will exit once the bus goes away */
|
/* this is safe; testserver will exit once the bus goes away */
|
||||||
g_assert (g_spawn_command_line_async (SRCDIR "/gdbus-testserver.py", NULL));
|
g_assert (g_spawn_command_line_async (SRCDIR "/gdbus-testserver", NULL));
|
||||||
|
|
||||||
/* wait for the service to come up */
|
/* wait for the service to come up */
|
||||||
usleep (500 * 1000);
|
usleep (500 * 1000);
|
||||||
|
@ -173,7 +173,7 @@ test_connection_large_message (void)
|
|||||||
session_bus_up ();
|
session_bus_up ();
|
||||||
|
|
||||||
/* this is safe; testserver will exit once the bus goes away */
|
/* this is safe; testserver will exit once the bus goes away */
|
||||||
g_assert (g_spawn_command_line_async (SRCDIR "/gdbus-testserver.py", NULL));
|
g_assert (g_spawn_command_line_async (SRCDIR "/gdbus-testserver", NULL));
|
||||||
|
|
||||||
watcher_id = g_bus_watch_name (G_BUS_TYPE_SESSION,
|
watcher_id = g_bus_watch_name (G_BUS_TYPE_SESSION,
|
||||||
"com.example.TestService",
|
"com.example.TestService",
|
||||||
|
@ -924,7 +924,7 @@ test_connection_filter (void)
|
|||||||
g_assert_cmpint (data.num_outgoing, ==, 4);
|
g_assert_cmpint (data.num_outgoing, ==, 4);
|
||||||
|
|
||||||
/* this is safe; testserver will exit once the bus goes away */
|
/* this is safe; testserver will exit once the bus goes away */
|
||||||
g_assert (g_spawn_command_line_async (SRCDIR "/gdbus-testserver.py", NULL));
|
g_assert (g_spawn_command_line_async (SRCDIR "/gdbus-testserver", NULL));
|
||||||
/* wait for service to be available */
|
/* wait for service to be available */
|
||||||
signal_handler_id = g_dbus_connection_signal_subscribe (c,
|
signal_handler_id = g_dbus_connection_signal_subscribe (c,
|
||||||
"org.freedesktop.DBus", /* sender */
|
"org.freedesktop.DBus", /* sender */
|
||||||
|
@ -125,7 +125,7 @@ test_introspection_parser (void)
|
|||||||
g_assert_no_error (error);
|
g_assert_no_error (error);
|
||||||
|
|
||||||
/* this is safe; testserver will exit once the bus goes away */
|
/* this is safe; testserver will exit once the bus goes away */
|
||||||
g_assert (g_spawn_command_line_async (SRCDIR "/gdbus-testserver.py", NULL));
|
g_assert (g_spawn_command_line_async (SRCDIR "/gdbus-testserver", NULL));
|
||||||
|
|
||||||
_g_assert_property_notify (proxy, "g-name-owner");
|
_g_assert_property_notify (proxy, "g-name-owner");
|
||||||
|
|
||||||
|
@ -98,7 +98,7 @@ test_proxy_well_known_name (void)
|
|||||||
g_assert (g_dbus_proxy_get_cached_property_names (ap) == NULL);
|
g_assert (g_dbus_proxy_get_cached_property_names (ap) == NULL);
|
||||||
|
|
||||||
/* this is safe; testserver will exit once the bus goes away */
|
/* this is safe; testserver will exit once the bus goes away */
|
||||||
g_assert (g_spawn_command_line_async (SRCDIR "/gdbus-testserver.py", NULL));
|
g_assert (g_spawn_command_line_async (SRCDIR "/gdbus-testserver", NULL));
|
||||||
|
|
||||||
/* check that we get the notify::g-name-owner signal */
|
/* check that we get the notify::g-name-owner signal */
|
||||||
_g_assert_property_notify (p, "g-name-owner");
|
_g_assert_property_notify (p, "g-name-owner");
|
||||||
|
@ -784,7 +784,7 @@ test_proxy (void)
|
|||||||
g_assert_no_error (error);
|
g_assert_no_error (error);
|
||||||
|
|
||||||
/* this is safe; testserver will exit once the bus goes away */
|
/* this is safe; testserver will exit once the bus goes away */
|
||||||
g_assert (g_spawn_command_line_async (SRCDIR "/gdbus-testserver.py", NULL));
|
g_assert (g_spawn_command_line_async (SRCDIR "/gdbus-testserver", NULL));
|
||||||
|
|
||||||
_g_assert_property_notify (proxy, "g-name-owner");
|
_g_assert_property_notify (proxy, "g-name-owner");
|
||||||
|
|
||||||
|
@ -587,7 +587,7 @@ main (int argc,
|
|||||||
session_bus_up ();
|
session_bus_up ();
|
||||||
|
|
||||||
/* this is safe; testserver will exit once the bus goes away */
|
/* this is safe; testserver will exit once the bus goes away */
|
||||||
g_assert (g_spawn_command_line_async (SRCDIR "/gdbus-testserver.py", NULL));
|
g_assert (g_spawn_command_line_async (SRCDIR "/gdbus-testserver", NULL));
|
||||||
|
|
||||||
/* wait for the service to come up */
|
/* wait for the service to come up */
|
||||||
usleep (500 * 1000);
|
usleep (500 * 1000);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user