summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorEmilio Pozuelo Monfort <emilio.pozuelo@collabora.co.uk>2011-05-18 09:52:10 +0100
committerNicolas Dufresne <nicolas.dufresne@collabora.com>2011-05-26 18:02:57 -0400
commit4230ec13757892520a2971dacbb82b55fda7a76e (patch)
tree84768795230a9172d08ad41bd68939054fb520fd /tests
parent7c449d62c723539ea3fa5f2508915173b73c53d9 (diff)
downloadtelepathy-logger-4230ec13757892520a2971dacbb82b55fda7a76e.tar.gz
Add a testcase for bug #37288
Diffstat (limited to 'tests')
-rw-r--r--tests/dbus/test-log-manager.c23
1 files changed, 23 insertions, 0 deletions
diff --git a/tests/dbus/test-log-manager.c b/tests/dbus/test-log-manager.c
index 0cb00eb..5deb349 100644
--- a/tests/dbus/test-log-manager.c
+++ b/tests/dbus/test-log-manager.c
@@ -414,6 +414,22 @@ test_get_filtered_events (TestCaseFixture *fixture,
static void
+get_entities_37288_cb (GObject *object,
+ GAsyncResult *result,
+ gpointer user_data)
+{
+ TestCaseFixture *fixture = user_data;
+ GError *error = NULL;
+
+ tpl_log_manager_get_entities_finish (TPL_LOG_MANAGER (object), result,
+ NULL, &error);
+
+ g_assert_no_error (error);
+ g_main_loop_quit (fixture->main_loop);
+}
+
+
+static void
get_entities_cb (GObject *object,
GAsyncResult *result,
gpointer user_data)
@@ -449,6 +465,13 @@ test_get_entities (TestCaseFixture *fixture,
g_list_foreach (fixture->ret, (GFunc) g_object_unref, NULL);
g_list_free (fixture->ret);
+
+ /* Check that the GSimpleAsyncResult res_gpointer's GDestroyNotify func
+ * is the appropriate one.
+ * Reproduces: https://bugs.freedesktop.org/show_bug.cgi?id=37288 */
+ tpl_log_manager_get_entities_async (fixture->manager, fixture->account,
+ get_entities_37288_cb, fixture);
+ g_main_loop_run (fixture->main_loop);
}