[evolution-data-server/openismus-work-master: 7/10] Make the libebook tests use direct read access by default



commit 2e172b8d21a6f1a540ca9fd5df61251c0b11f846
Author: Tristan Van Berkom <tristanvb openismus com>
Date:   Tue Nov 6 16:18:56 2012 +0900

    Make the libebook tests use direct read access by default

 tests/libebook/client/client-test-utils.c |    8 +++++++-
 1 files changed, 7 insertions(+), 1 deletions(-)
---
diff --git a/tests/libebook/client/client-test-utils.c b/tests/libebook/client/client-test-utils.c
index f9bda66..d633a1d 100644
--- a/tests/libebook/client/client-test-utils.c
+++ b/tests/libebook/client/client-test-utils.c
@@ -29,6 +29,12 @@
 
 #include "client-test-utils.h"
 
+/* This forces the GType to be registered in a way that
+ * avoids a "statement with no effect" compiler warning.
+ * FIXME Use g_type_ensure() once we require GLib 2.34. */
+#define REGISTER_TYPE(type) \
+	(g_type_class_unref (g_type_class_ref (type)))
+
 void
 report_error (const gchar *operation,
               GError **error)
@@ -331,7 +337,7 @@ create_book_idle (CreateBookData *data)
 	if (!data->source)
 		g_error ("Unable to fetch newly created source uid '%s' from the registry", data->uid);
 
-	data->book = e_book_client_new (data->source, &error);
+	data->book = e_book_client_new_direct (data->registry, data->source, &error);
 	if (!data->book)
 		g_error ("Unable to create the book: %s", error->message);
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]