aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/service-manager-connect.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/tests/service-manager-connect.c b/tests/service-manager-connect.c
index 4519b83..91d2bad 100644
--- a/tests/service-manager-connect.c
+++ b/tests/service-manager-connect.c
@@ -17,6 +17,20 @@ timeout (gpointer data)
void
connection (IndicatorServiceManager * sm, gboolean connected, gpointer user_data)
{
+ static gboolean has_connected = FALSE;
+
+ if (has_connected && connected) {
+ g_warning("We got two connected signals. FAIL.");
+ passed = FALSE;
+ return;
+ }
+
+ if (!connected) {
+ g_debug("Not connected");
+ return;
+ }
+
+ has_connected = TRUE;
g_debug("Connection");
passed = TRUE;
g_main_loop_quit(mainloop);