Changeset 2029
- Timestamp:
- 05/22/07 01:24:25
- Files:
-
- trunk/configure.ac (modified) (4 diffs)
- trunk/libtinymail-test/check_libtinymailui_main.c (modified) (1 diff)
- trunk/libtinymail-test/tny-folder-store-test.c (modified) (4 diffs)
- trunk/libtinymail-test/tny-folder-test.c (modified) (10 diffs)
- trunk/libtinymail-test/tny-header-test.c (modified) (1 diff)
- trunk/libtinymail-test/tny-list-test.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/configure.ac
r1957 r2029 181 181 [Build using acap features]), 182 182 [case "${enableval}" in 183 yes) 184 build_acap=true 185 ;; 183 yes) build_acap=true ;; 186 184 no) build_acap=false ;; 187 185 *) AC_MSG_ERROR(bad value ${enableval} for --enable-acap) ;; … … 194 192 [Build using queues]), 195 193 [case "${enableval}" in 196 yes) 197 build_queues=true 198 ;; 194 yes) build_queues=true ;; 199 195 no) build_queues=false ;; 200 196 *) AC_MSG_ERROR(bad value ${enableval} for --enable-queues) ;; … … 307 303 fi 308 304 fi 309 310 305 311 306 dnl ### libtinymailui, the ui abstraction library ## … … 345 340 dnl ### libtinymailui-mozembed, a library that wraps the gtkmozembed widget ## 346 341 if test x$build_mozembed = xtrue; then 342 347 343 AC_TNY_MOZ_CHECK 344 345 if test x$mozilla_nspr = xno; then 346 AC_MSG_ERROR("You need Mozilla's NSPR") 347 fi 348 if test x$mozilla_nss = xno; then 349 AC_MSG_ERROR("You need Mozilla's NSS") 350 fi 351 if test x$mozilla_xpcom = xno; then 352 AC_MSG_ERROR("You need Mozilla's XPCOM") 353 fi 354 if test x$mozilla_gtkmozembed = xno; then 355 AC_MSG_ERROR("You need Mozilla's GtkMozEmbed") 356 fi 357 348 358 extraplatpkgs="$mozilla_nspr $mozilla_nss $mozilla_xpcom $mozilla_gtkmozembed" 349 359 extratnypkgs="$extratnypkgs $extraplatpkgs" trunk/libtinymail-test/check_libtinymailui_main.c
r1309 r2029 2 2 3 3 #include "check_libtinymailui.h" 4 5 #include <gtk/gtk.h> 4 6 5 7 int trunk/libtinymail-test/tny-folder-store-test.c
r1323 r2029 19 19 #include "check_libtinymail.h" 20 20 21 #include <gtk/gtk.h> 22 21 23 #include <tny-folder.h> 22 24 #include <tny-camel-folder.h> … … 102 104 } 103 105 106 static void status_cb (GObject *self, TnyStatus *status, gpointer user_data) {} 107 104 108 START_TEST (tny_folder_store_test_get_folders_async) 105 109 { … … 113 117 114 118 folders = tny_simple_list_new (); 115 tny_folder_store_get_folders_async (account, folders, callback, NULL, NULL);119 tny_folder_store_get_folders_async (account, folders, callback, NULL, status_cb, NULL); 116 120 g_timeout_add (1000*4, timeout, NULL); 117 121 gtk_main (); … … 148 152 TnyFolder *new_folder; 149 153 const gchar *new_folder_name = "tny-folder-store-test_temp-folder"; 150 gchar *str;151 154 152 155 /* Make sure errors are set - cannot add folder to root */ trunk/libtinymail-test/tny-folder-test.c
r1738 r2029 19 19 #include "check_libtinymail.h" 20 20 21 #include <gtk/gtk.h> 22 21 23 #include <tny-folder.h> 22 24 #include <tny-camel-folder.h> … … 38 40 static GError *err; 39 41 42 40 43 typedef void (*performer) (TnyFolder *folder); 44 45 static void status_cb (GObject *self, TnyStatus *status, gpointer user_data) {} 41 46 42 47 static void … … 159 164 160 165 static void 161 message_received (TnyFolder *folder, TnyMsg *msg, GError **err, gpointer user_data)166 message_received (TnyFolder *folder, gboolean cancelled, TnyMsg *msg, GError **err, gpointer user_data) 162 167 { 163 168 fail_unless (*err == NULL, "Error receiving message async"); … … 174 179 TnyHeader *header; 175 180 TnyMsg *msg; 176 TnyHeaderFlags hflags; 177 181 178 182 if (iface == NULL) 179 183 { … … 206 210 callback_completed = FALSE; 207 211 err = NULL; 208 tny_folder_get_msg_async (iface, header, message_received, NULL);212 tny_folder_get_msg_async (iface, header, message_received, status_cb, NULL); 209 213 g_timeout_add (1000*6, timeout, NULL); 210 214 gtk_main (); … … 265 269 START_TEST (tny_folder_test_properties) 266 270 { 267 gint count;268 269 271 if (iface == NULL) 270 272 { … … 289 291 END_TEST 290 292 291 START_TEST (tny_folder_test_name)292 {293 const gchar *name = "tny-folder-iface-test";294 const gchar *temp_name = "tny-folder-iface-test_temp";295 296 if (iface == NULL)297 {298 g_warning ("Test cannot continue (are you online?)");299 return;300 }301 302 fail_unless (strcmp (tny_folder_get_name (iface), name) == 0, "Folder had wrong name property");303 err = NULL;304 tny_folder_set_name (iface, temp_name, &err);305 fail_unless (err == NULL, "An error occured while renaming folder");306 fail_unless (strcmp (tny_folder_get_name (iface), temp_name) == 0, "Folder had wrong name property");307 err = NULL;308 tny_folder_set_name (iface, name, &err);309 fail_unless (err == NULL, "An error occured while renaming folder");310 fail_unless (strcmp (tny_folder_get_name (iface), name) == 0, "Folder had wrong name property");311 }312 END_TEST313 314 293 START_TEST (tny_folder_test_subscribed) 315 294 { 316 TnyFolder *folder;317 318 295 fail_unless (tny_folder_is_subscribed (iface), "Subscription property should be set"); 319 296 recurse_folders (TNY_FOLDER_STORE (account), NULL, "INBOX/unsubscribed_folder", second_folder); … … 337 314 END_TEST 338 315 339 static void340 refresh_progress (TnyFolder *folder, const gchar *what, gint status, gint oftotal, gpointer user_data)341 {342 g_print (".");343 }344 316 345 317 static void … … 363 335 g_print ("Refreshing folder.."); 364 336 callback_completed = FALSE; 365 tny_folder_refresh_async (iface, folder_refreshed, refresh_progress, &err);337 tny_folder_refresh_async (iface, folder_refreshed, status_cb, &err); 366 338 g_timeout_add (1000*6, timeout, NULL); 367 339 gtk_main (); … … 394 366 suite_add_tcase (s, tc); 395 367 396 tc = tcase_create ("Name");397 tcase_set_timeout (tc, 15);398 tcase_add_checked_fixture (tc, tny_folder_test_setup, tny_folder_test_teardown);399 tcase_add_test (tc, tny_folder_test_name);400 suite_add_tcase (s, tc);401 402 368 tc = tcase_create ("Subscribed"); 403 369 tcase_add_checked_fixture (tc, tny_folder_test_setup, tny_folder_test_teardown); trunk/libtinymail-test/tny-header-test.c
r1738 r2029 21 21 #include <tny-msg.h> 22 22 #include <tny-header.h> 23 24 #include <tny-camel-msg.h> 25 23 26 #include <camel/camel-folder.h> 24 27 #include <camel/camel.h> trunk/libtinymail-test/tny-list-test.c
r1700 r2029 203 203 204 204 item = tny_iterator_get_current (iterator); 205 str = g_strdup_printf ("Implementation - Item should be \"4\"\n", G_OBJECT_TYPE_NAME (iface));205 str = g_strdup_printf ("Implementation %s - Item should be \"4\"\n", G_OBJECT_TYPE_NAME (iface)); 206 206 fail_unless (item == c, str); 207 207 g_free (str);
