/* open header */
#include <glib.h>
-#include "Emf_Mapi_Account.h"
-#include "Emf_Mapi_Network.h"
+#include "email-api-account.h"
+#include "email-api-network.h"
/* internal header */
-#include "emf-test-utility.h"
-#include "emf-test-account.h"
+#include "testapp-utility.h"
+#include "testapp-account.h"
#include <sys/time.h>
#include <sys/times.h>
#define VDF_RECV_SERVER_ADDR "imap.email.vodafone.de"
#define VDF_SMTP_SERVER_ADDR "smtp.email.vodafone.de"
+/* SAMSUNG 3G TEST */
+#define S3G_RECV_SERVER_ADDR "165.213.73.235"
+#define S3G_RECV_SERVER_PORT EMF_POP3_PORT
+#define S3G_RECV_USE_SECURITY 0
+#define S3G_RECV_IMAP_USE_SECURITY 1
+#define S3G_SMTP_SERVER_ADDR "165.213.73.235"
+#define S3G_SMTP_SERVER_PORT 465
+#define S3G_SMTP_AUTH 1
+#define S3G_SMTP_USE_SECURITY 1
+#define S3G_KEEP_ON_SERVER 1
gboolean testapp_test_create_account_by_account_type(int account_type,int *account_id)
{
account->sending_auth = 0;
break;
+ case 4:/* SAMSUNG 3G TEST */
+ account->receiving_server_type = EMF_SERVER_TYPE_POP3;
+ account->receiving_server_addr = strdup(S3G_RECV_SERVER_ADDR);
+ account->port_num = S3G_RECV_SERVER_PORT;
+ account->sending_server_addr = strdup(S3G_SMTP_SERVER_ADDR);
+ account->sending_port_num = S3G_SMTP_SERVER_PORT;
+ account->use_security = S3G_RECV_USE_SECURITY;
+ account->sending_security = S3G_SMTP_USE_SECURITY;
+ account->sending_auth = S3G_SMTP_AUTH;
+ break;
+
+ case 5:/* SAMSUNG 3G TEST */
+ account->receiving_server_type = EMF_SERVER_TYPE_IMAP4;
+ account->receiving_server_addr = strdup(S3G_RECV_SERVER_ADDR);
+ account->port_num = EMF_IMAPS_PORT;
+ account->sending_server_addr = strdup(S3G_SMTP_SERVER_ADDR);
+ account->sending_port_num = S3G_SMTP_SERVER_PORT;
+ account->use_security = 1;
+ account->sending_security = S3G_SMTP_USE_SECURITY;
+ account->sending_auth = S3G_SMTP_AUTH;
+ break;
+
case 6:/* Gmail POP3 */
account->receiving_server_type = EMF_SERVER_TYPE_POP3;
account->receiving_server_addr = strdup("pop.gmail.com");
testapp_print("1. Gawab\n");
testapp_print("2. Vodafone\n");
+ testapp_print("4. SAMSUNG 3G TEST (POP)\n");
+ testapp_print("5. SAMSUNG 3G TEST (IMAP)\n");
testapp_print("6. Gmail (POP3)\n");
testapp_print("7. Gmail (IMAP4)\n");
testapp_print("8. Active Sync (dummy)\n");
return FALSE;
}
+static gboolean testapp_test_query_server_info()
+{
+ int error_code;
+ char domain_name[255];
+ emf_server_info_t *result_server_info;
+
+ testapp_print("\n input domain name\n");
+ scanf("%s", domain_name);
+
+ error_code = email_query_server_info(domain_name, &result_server_info);
+ testapp_print("email_query_server_info returned [%d]\n",error_code);
+ if(error_code == EMF_ERROR_NONE)
+ testapp_print("service_name [%s]\n", result_server_info->service_name);
+ return FALSE;
+}
static gboolean testapp_test_clear_all_notification()
{
testapp_test_get_password_length_of_account();
break;
+ case 12:
+ testapp_test_query_server_info();
+ break;
+
case 13:
testapp_test_clear_all_notification();
+ break;
case 0:
go_to_loop = FALSE;
break;
+
default:
break;
}