diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/Makefile.am | 2 | ||||
-rw-r--r-- | tests/test-libappindicator-dbus-client.c | 2 | ||||
-rw-r--r-- | tests/test-libappindicator-dbus-server.c | 2 | ||||
-rw-r--r-- | tests/test-libappindicator-fallback-item.c | 4 | ||||
-rw-r--r-- | tests/test-libappindicator-fallback-watcher.c | 13 | ||||
-rw-r--r-- | tests/test-libappindicator-status-server.c | 2 | ||||
-rw-r--r-- | tests/test-libappindicator.c | 2 | ||||
-rw-r--r-- | tests/test-simple-app.c | 2 |
8 files changed, 18 insertions, 11 deletions
diff --git a/tests/Makefile.am b/tests/Makefile.am index d3b18d8..8d356bc 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -142,7 +142,7 @@ XML_REPORT = libappindicator-check-results.xml HTML_REPORT = libappindicator-check-results.html libappindicator-tests: libappindicator-tests-gtester Makefile.am - @echo "#!/bin/sh" > $@ + @echo "#!/bin/bash" > $@ @echo . $(srcdir)/run-xvfb.sh >> $@ @echo $(DBUS_RUNNER) --task ./libappindicator-tests-gtester >> $@ @chmod +x $@ diff --git a/tests/test-libappindicator-dbus-client.c b/tests/test-libappindicator-dbus-client.c index f5482aa..1500213 100644 --- a/tests/test-libappindicator-dbus-client.c +++ b/tests/test-libappindicator-dbus-client.c @@ -25,7 +25,7 @@ with this program. If not, see <http://www.gnu.org/licenses/>. #include <dbus/dbus-glib.h> #include <dbus/dbus-glib-bindings.h> #include <dbus/dbus-glib-lowlevel.h> -#include <libappindicator/app-indicator.h> +#include <app-indicator.h> #include "test-defines.h" #include "../src/dbus-shared.h" diff --git a/tests/test-libappindicator-dbus-server.c b/tests/test-libappindicator-dbus-server.c index 2d68950..995d49b 100644 --- a/tests/test-libappindicator-dbus-server.c +++ b/tests/test-libappindicator-dbus-server.c @@ -24,7 +24,7 @@ with this program. If not, see <http://www.gnu.org/licenses/>. #include <dbus/dbus-glib.h> #include <dbus/dbus-glib-lowlevel.h> #include <gtk/gtk.h> -#include <libappindicator/app-indicator.h> +#include <app-indicator.h> #include "test-defines.h" static GMainLoop * mainloop = NULL; diff --git a/tests/test-libappindicator-fallback-item.c b/tests/test-libappindicator-fallback-item.c index 9fd1b45..418b779 100644 --- a/tests/test-libappindicator-fallback-item.c +++ b/tests/test-libappindicator-fallback-item.c @@ -2,7 +2,7 @@ #include <glib-object.h> #include <dbus/dbus-glib.h> #include <dbus/dbus-glib-bindings.h> -#include <libappindicator/app-indicator.h> +#include <app-indicator.h> #define TEST_LIBAPPINDICATOR_FALLBACK_ITEM_TYPE (test_libappindicator_fallback_item_get_type ()) #define TEST_LIBAPPINDICATOR_FALLBACK_ITEM(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TEST_LIBAPPINDICATOR_FALLBACK_ITEM_TYPE, TestLibappindicatorFallbackItem)) @@ -138,7 +138,7 @@ main (int argc, char ** argv) GtkWidget * menu = gtk_menu_new(); app_indicator_set_menu(APP_INDICATOR(item), GTK_MENU(menu)); - g_timeout_add_seconds(1, kill_func, NULL); + g_timeout_add_seconds(2, kill_func, NULL); mainloop = g_main_loop_new(NULL, FALSE); g_main_loop_run(mainloop); diff --git a/tests/test-libappindicator-fallback-watcher.c b/tests/test-libappindicator-fallback-watcher.c index 70e01d1..5494082 100644 --- a/tests/test-libappindicator-fallback-watcher.c +++ b/tests/test-libappindicator-fallback-watcher.c @@ -27,6 +27,8 @@ with this program. If not, see <http://www.gnu.org/licenses/>. #include "../src/dbus-shared.h" +gboolean kill_func (gpointer userdata); + static GMainLoop * mainloop = NULL; static DBusHandlerResult @@ -36,6 +38,10 @@ dbus_filter (DBusConnection * connection, DBusMessage * message, void * user_dat DBusMessage * reply = dbus_message_new_method_return(message); dbus_connection_send(connection, reply, NULL); dbus_message_unref(reply); + + /* Let the messages get out, but we're done at this point */ + g_timeout_add(50, kill_func, NULL); + return DBUS_HANDLER_RESULT_HANDLED; } @@ -78,7 +84,7 @@ main (int argv, char ** argc) return 1; } - g_usleep(250000); + g_usleep(500000); g_debug("Initing"); @@ -96,8 +102,9 @@ main (int argv, char ** argc) dbus_connection_add_filter(dbus_g_connection_get_connection(session_bus), dbus_filter, NULL, NULL); - /* After we've got the name, let it unfallback, and then we'll drop again */ - g_timeout_add(250, kill_func, NULL); + /* This is the final kill function. It really shouldn't happen + unless we get an error. */ + g_timeout_add(2000, kill_func, NULL); g_debug("Entering Mainloop"); diff --git a/tests/test-libappindicator-status-server.c b/tests/test-libappindicator-status-server.c index 79b1759..8cd5571 100644 --- a/tests/test-libappindicator-status-server.c +++ b/tests/test-libappindicator-status-server.c @@ -25,7 +25,7 @@ with this program. If not, see <http://www.gnu.org/licenses/>. #include <dbus/dbus-glib.h> #include <dbus/dbus-glib-lowlevel.h> #include <glib.h> -#include <libappindicator/app-indicator.h> +#include <app-indicator.h> static GMainLoop * mainloop = NULL; static gboolean active = FALSE; diff --git a/tests/test-libappindicator.c b/tests/test-libappindicator.c index c987a8f..86879b3 100644 --- a/tests/test-libappindicator.c +++ b/tests/test-libappindicator.c @@ -23,7 +23,7 @@ with this program. If not, see <http://www.gnu.org/licenses/>. #include <glib.h> #include <glib-object.h> -#include <libappindicator/app-indicator.h> +#include <app-indicator.h> void test_libappindicator_prop_signals_status_helper (AppIndicator * ci, gchar * status, gboolean * signalactivated) diff --git a/tests/test-simple-app.c b/tests/test-simple-app.c index f5957c8..d60d9b9 100644 --- a/tests/test-simple-app.c +++ b/tests/test-simple-app.c @@ -24,7 +24,7 @@ with this program. If not, see <http://www.gnu.org/licenses/>. #include <dbus/dbus-glib-lowlevel.h> #include <glib.h> #include <libdbusmenu-glib/server.h> -#include <libappindicator/app-indicator.h> +#include <app-indicator.h> static GMainLoop * mainloop = NULL; |