X-Git-Url: http://git.maemo.org/git/?p=modest;a=blobdiff_plain;f=tests%2Fcheck_account-mgr.c;h=dd4e6e16d2c9e487a654fa9f13746854b2f4edb7;hp=ffb052df0be8f4adae35b1e03e06fa0c67ea98ab;hb=3695dda9d436bd66b8800ff9a73173ccace4d55d;hpb=1acc7e369b8bba314daf3027023a001a1c733a7b diff --git a/tests/check_account-mgr.c b/tests/check_account-mgr.c index ffb052d..dd4e6e1 100644 --- a/tests/check_account-mgr.c +++ b/tests/check_account-mgr.c @@ -31,6 +31,7 @@ #include #include #include +#include /* ----------------------- Defines ---------------------- */ @@ -105,7 +106,7 @@ START_TEST (test_add_exists_remove_account_regular) gchar *hostname = NULL; gchar *username = NULL; gchar *password = NULL; - gchar *proto = NULL; + ModestProtocol proto; GError *error = NULL; gboolean result; @@ -152,7 +153,7 @@ START_TEST (test_add_exists_remove_account_regular) hostname = g_strdup ("myhostname.mydomain.com"); username = g_strdup ("myusername"); password = g_strdup ("mypassword"); - proto = g_strdup ("smtp"); + proto = MODEST_PROTOCOL_TRANSPORT_SMTP; result = modest_account_mgr_add_server_account (account_mgr, name, hostname, @@ -167,7 +168,6 @@ START_TEST (test_add_exists_remove_account_regular) g_free (hostname); g_free (username); g_free (password); - g_free (proto); /* Test 5 */ result = modest_account_mgr_account_exists (account_mgr, @@ -273,7 +273,7 @@ START_TEST (test_add_exists_remove_account_invalid) "hostname", "username", "password", - "proto"); + MODEST_PROTOCOL_STORE_IMAP); fail_unless (!result, "modest_account_mgr_add_server_account does not return " \ "FALSE when passing a NULL ModestAccountMgr"); @@ -284,7 +284,7 @@ START_TEST (test_add_exists_remove_account_invalid) "hostname", "username", "password", - "proto"); + MODEST_PROTOCOL_STORE_IMAP); fail_unless (!result, "modest_account_mgr_add_server_account does not return " \ "FALSE when passing a NULL account name"); @@ -295,7 +295,7 @@ START_TEST (test_add_exists_remove_account_invalid) "hostname", "username", "password", - "proto"); + MODEST_PROTOCOL_STORE_IMAP); fail_unless (!result, "modest_account_mgr_add_server_account does not return " \ "FALSE when passing an invalid account name");