//
// Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
// All rights reserved.
// This component and the accompanying materials are made available
// under the terms of "Eclipse Public License v1.0"
// which accompanies this distribution, and is available
// at the URL "http://www.eclipse.org/legal/epl-v10.html".
//
// Initial Contributors:
// Nokia Corporation - initial contribution.
//
// Contributors:
//
// Description:
//
//! @file

RUN_UTILS DeleteFile c:\messaging.db

LOAD_SUITE 	T_MsgCommonServer	-SharedData
LOAD_SUITE 	T_MsgImapServer		-SharedData
LOAD_SUITE  	T_MsgSmtpServer		-SharedData


START_TESTCASE MSG-IMAP-Offline-Populate-0013
//! @SYMTestCaseID		MSG-IMAP-Offline-Populate-0013
//! @SYMTestType		CIT
//! @SYMTestPriority		High
//! @SYMTestStatus 		Implemented
//! @SYMTestCaseDependencies
//! @SYMTestCaseDesc		Verification:
//!		This test tests if Offline Populate downloads the message. It also compares the received messages with sent 
//!		messages based on the Download limits set. Download Limit is set to download only Attachments
//!	@SYMTestCaseDependencies	requires ced -i c:\ced_default_ras.cfg to set comms.
//! @SYMTestActions
//!	The Local Inbox and Sent Item folders and the remote Inbox folder of IMAP4 
//!	account are cleaned up before starting the test.
//! ------------------------------------------
//!	1.  Create emails from data file and send emails to the same account
//!	2.  Set the download limits
//!	3.  Download the mails with IMAP4 KIMAP4MTMPopulate command
//!	4.  Compare the received messages with sent messages based on the Download limits set
//! 	Implementation and execution:
//!	The emails are sent to the sender's address only.
//!	New messages are created, sent and received.  The received messages are compared with 
//!	the sent messages, based on the download limits set, for size and contents.
//!   Download Limits set:
//!	TImImap4GetPartialMailInfo::iTotalSizeLimit = Default Value (KMaxInt)
//!	TImImap4GetPartialMailInfo::iBodyTextSizeLimit = Default Value (KMaxInt)
//!	TImImap4GetPartialMailInfo::iAttachmentSizeLimit = 6000
//!	TImImap4PartialMailOptions::EAttachmentsOnly
//!	Destination Folder : Remote Inbox folder
//! ------------------------------------------
//! @SYMTestExpectedResults
//!	All The Attachments having size <= TImImap4GetPartialMailInfo::iAttachmentSizeLimit
//!	will be downloaded. There will be no footer string information.
//!	@SYMREQ				5578
//!	@SYMPREQ			1160

PRINT Setup Begins #####################################################

RUN_TEST_STEP	300	T_MsgCommonServer  	StartUp
RUN_TEST_STEP	300	T_MsgImapServer	StartUp
RUN_TEST_STEP	300	T_MsgSmtpServer	StartUp

RUN_TEST_STEP 300 T_MsgCommonServer	InitNtRas			c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0001-InitNtRas
RUN_TEST_STEP 300 T_MsgCommonServer	ResetMessageStore		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0001-ResetMessageStore
RUN_TEST_STEP 300 T_MsgImapServer	CreateImapAccount		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0001-CreateImapAccount
RUN_TEST_STEP 	100 	T_MsgImapServer		ChangeImap4SubAndSyncSettings	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0001-ChangeSubAndSyncSettings
RUN_TEST_STEP 	100 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0001-ConnectImap4Server
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0001-DoFullImap4Synchronisation
RUN_TEST_STEP 	100 	T_MsgImapServer		InitialiseImap4Account		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0001-InitialiseImap4Account
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0001-DoFullImap4Synchronisation
RUN_TEST_STEP 300 T_MsgImapServer	DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0001-DisConnectImap4Server
RUN_TEST_STEP 300 T_MsgImapServer	CheckChildrenCountImap		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0001-CheckChildrenCountRemoteInbox0
RUN_TEST_STEP 300 T_MsgSmtpServer	CreateSmtpMessageFromEmailFile	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0001-CreateSmtpMessageFromEmailFile
RUN_TEST_STEP 300 T_MsgSmtpServer	SendSmtpMessage			c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0001-SendSmtpMessage
RUN_TEST_STEP 300 T_MsgImapServer	SetImap4PartialDownloadLimits	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0001-SetImap4PartialDownloadLimits
RUN_TEST_STEP 300 T_MsgImapServer	ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0001-ConnectImap4Server
RUN_TEST_STEP 300 T_MsgImapServer	DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0001-DoFullImap4Synchronisation1
RUN_TEST_STEP 300 T_MsgImapServer	DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0001-DisConnectImap4Server
//Offline Populate
RUN_TEST_STEP 300 T_MsgImapServer	ImapInvokeAsyncFunction		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0001-ImapInvokeAsyncFunction
RUN_TEST_STEP 300 T_MsgImapServer	ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0001-ConnectImap4Server
RUN_TEST_STEP 300 T_MsgImapServer	DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0001-DoFullImap4Synchronisation1
RUN_TEST_STEP 300 T_MsgImapServer 	CompareEmailMessages		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0001-CompareEmailMessages
RUN_TEST_STEP 300 T_MsgImapServer	DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0001-DisConnectImap4Server
RUN_TEST_STEP 300 T_MsgImapServer	CheckChildrenCountImap		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0001-CheckChildrenCountRemoteInbox1

RUN_TEST_STEP	300	T_MsgCommonServer	ShutDown
RUN_TEST_STEP	300	T_MsgImapServer		ShutDown
RUN_TEST_STEP	300	T_MsgSmtpServer		ShutDown

PRINT Execute Completed ################################################
END_TESTCASE MSG-IMAP-Offline-Populate-0013


START_TESTCASE MSG-IMAP-Offline-Populate-0014
//! @SYMTestCaseID		MSG-IMAP-Offline-Populate-0014
//! @SYMTestType		CIT
//! @SYMTestPriority		High
//! @SYMTestStatus 		Implemented
//! @SYMTestCaseDependencies
//! @SYMTestCaseDesc		Verification:
//!		This test tests offline Operation with download limit set.It tests Populate command used in conjunction with 
//!		Partial Mail Download Option set to EAttachmentsOnly. All The Attachments having 
//!		size <= TImImap4GetPartialMailInfo::iAttachmentSizeLimit will be downloaded. There will be no footer
//!		string information.
//!	@SYMTestCaseDependencies	requires ced -i c:\ced_default_ras.cfg to set comms.
//! @SYMTestActions
//!	The Local Inbox and Sent Item folders and the remote Inbox folder of IMAP4 
//!	account are cleaned up before starting the test.
//! ------------------------------------------
//!	1.  Create emails from data file and send emails to the same account
//!	2.  Set the download limits
//!	3.  Download the mails with IMAP4 KIMAP4MTMPopulate command
//!	4.  Compare the received messages with sent messages based on the Download limits set
//! Implementation and execution:
//!	The emails are sent to the sender's address only.
//!	New messages are created, sent and received.  The received messages are compared with 
//!	the sent messages, based on the download limits set, for size and contents.
//! Download Limits set:
//! 	TImImap4GetPartialMailInfo::iTotalSizeLimit = Default Value (KMaxInt)
//!	TImImap4GetPartialMailInfo::iBodyTextSizeLimit = Default value (KMaxInt)
//!	TImImap4GetPartialMailInfo::iAttachmentSizeLimit = 8000
//!	TImImap4PartialMailOptions::EAttachmentsOnly
//! ------------------------------------------
//! @SYMTestExpectedResults
//!	All The Attachments having size <= TImImap4GetPartialMailInfo::iAttachmentSizeLimit
//!	will be downloaded. There will be no footer string information.
//!	@SYMREQ				5578
//!	@SYMPREQ			1160

PRINT Setup Begins #####################################################

RUN_TEST_STEP	300	T_MsgCommonServer  	StartUp
RUN_TEST_STEP	300	T_MsgImapServer	StartUp
RUN_TEST_STEP	300	T_MsgSmtpServer	StartUp

RUN_TEST_STEP 300 T_MsgCommonServer	InitNtRas			c:\msgtest\email\imap\offline\msg-imap-offline3.ini    0002-InitNtRas
RUN_TEST_STEP 300 T_MsgCommonServer	ResetMessageStore		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     0002-ResetMessageStore
RUN_TEST_STEP 300 T_MsgImapServer	CreateImapAccount		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     0002-CreateImapAccount
RUN_TEST_STEP 	100 	T_MsgImapServer		ChangeImap4SubAndSyncSettings	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     0002-ChangeSubAndSyncSettings
RUN_TEST_STEP 	100 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     0002-ConnectImap4Server
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     0002-DoFullImap4Synchronisation
RUN_TEST_STEP 	100 	T_MsgImapServer		InitialiseImap4Account		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     0002-InitialiseImap4Account
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     0002-DoFullImap4Synchronisation
RUN_TEST_STEP 300 T_MsgImapServer	DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     0002-DisConnectImap4Server
RUN_TEST_STEP 300 T_MsgImapServer	CheckChildrenCountImap		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     0002-CheckChildrenCountRemoteInbox0
RUN_TEST_STEP 300 T_MsgSmtpServer	CreateSmtpMessageFromEmailFile	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     0002-CreateSmtpMessageFromEmailFile0
RUN_TEST_STEP 300 T_MsgSmtpServer	SendSmtpMessage			c:\msgtest\email\imap\offline\msg-imap-offline3.ini     0002-SendSmtpMessage0
RUN_TEST_STEP 300 T_MsgSmtpServer	CreateSmtpMessageFromEmailFile	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     0002-CreateSmtpMessageFromEmailFile1
RUN_TEST_STEP 300 T_MsgSmtpServer	SendSmtpMessage			c:\msgtest\email\imap\offline\msg-imap-offline3.ini     0002-SendSmtpMessage1
RUN_TEST_STEP 300 T_MsgImapServer	SetImap4PartialDownloadLimits	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     0002-SetImap4PartialDownloadLimits
RUN_TEST_STEP 300 T_MsgImapServer	ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     0002-ConnectImap4Server
RUN_TEST_STEP 300 T_MsgImapServer	DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     0002-DoFullImap4Synchronisation1
RUN_TEST_STEP 300 T_MsgImapServer	DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini    0002-DisConnectImap4Server
//Offline Populate
RUN_TEST_STEP 300 T_MsgImapServer	ImapInvokeAsyncFunction		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     0002-ImapInvokeAsyncFunction
RUN_TEST_STEP 300 T_MsgImapServer	ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     0002-ConnectImap4Server
RUN_TEST_STEP 300 T_MsgImapServer	DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     0002-DoFullImap4Synchronisation1
RUN_TEST_STEP 300 T_MsgImapServer 	CompareEmailMessages		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     0002-CompareEmailMessages
RUN_TEST_STEP 300 T_MsgImapServer	DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini    0002-DisConnectImap4Server
RUN_TEST_STEP 300 T_MsgImapServer	CheckChildrenCountImap		c:\msgtest\email\imap\offline\msg-imap-offline3.ini    0002-CheckChildrenCountRemoteInbox1

RUN_TEST_STEP	300	T_MsgCommonServer	ShutDown
RUN_TEST_STEP	300	T_MsgImapServer		ShutDown
RUN_TEST_STEP	300	T_MsgSmtpServer		ShutDown

PRINT Execute Completed ################################################
END_TESTCASE MSG-IMAP-Offline-Populate-0014


START_TESTCASE MSG_IMAP_Offline_Populate-0015
//! @SYMTestCaseID		MSG-IMAP-Offline-Populate-0015
//! @SYMTestType		CIT
//! @SYMTestPriority		High
//! @SYMTestStatus 		Implemented
//! @SYMTestCaseDependencies
//! @SYMTestCaseDesc		Verification:
//!		This test tests if Offline Populate downloads the message. It also compares the received messages with sent 
//!		messages based on the Download limits set.Body text size of <= TImImap4GetPartialMailInfo::iBodyTextSizeLimit,
//!		is downloaded
//!	@SYMTestCaseDependencies	requires ced -i c:\ced_default_ras.cfg to set comms.
//! @SYMTestActions
//!	The Local Inbox and Sent Item folders and the remote Inbox folder of IMAP4 
//!	account are cleaned up before starting the test.
//! ------------------------------------------
//!	1.  Create emails from data file and send emails to the same account
//!	2.  Set the download limits
//!	3.  Download the mails with IMAP4 KIMAP4MTMPopulate command
//!	4.  Compare the received messages with sent messages based on the Download limits set
//! Implementation and execution:
//!	The emails are sent to the sender's address only.
//!	New messages are created, sent and received.  The received messages are compared with 
//!	the sent messages, based on the download limits set, for size and contents.
//! Download Limits set:
//!	TImImap4GetPartialMailInfo::iTotalSizeLimit = Default Value
//!	TImImap4GetPartialMailInfo::iBodyTextSizeLimit = 20000
//!	TImImap4GetPartialMailInfo::iAttachmentSizeLimit = Default Value
//!	TImImap4PartialMailOptions::EBodyTextAndAttachments  
//!	Destination Folder : Remote Inbox folder
//! ------------------------------------------
//! @SYMTestExpectedResults
//!	If body text size of email <= TImImap4GetPartialMailInfo::iBodyTextSizeLimit
//!	The email should be completely downloaded with no footer string Information.
//!	If body text size of email > TImImap4GetPartialMailInfo::iBodyTextSizeLimit
//!	mail will be downloaded partially containing the footer string information
//!	All The Attachments will be downloaded.
//!	@SYMREQ				5578
//!	@SYMPREQ			1160

PRINT Setup Begins #####################################################

RUN_TEST_STEP	300	T_MsgCommonServer  	StartUp
RUN_TEST_STEP	300	T_MsgImapServer	StartUp
RUN_TEST_STEP	300	T_MsgSmtpServer	StartUp

RUN_TEST_STEP 300 T_MsgCommonServer 	InitNtRas			c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0003-InitNtRas
RUN_TEST_STEP 300 T_MsgCommonServer 	ResetMessageStore		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0003-ResetMessageStore
RUN_TEST_STEP 300 T_MsgImapServer	CreateImapAccount		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0003-CreateImapAccount
RUN_TEST_STEP 	100 	T_MsgImapServer		ChangeImap4SubAndSyncSettings	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0003-ChangeSubAndSyncSettings
RUN_TEST_STEP 	100 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0003-ConnectImap4Server
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0003-DoFullImap4Synchronisation
RUN_TEST_STEP 	100 	T_MsgImapServer		InitialiseImap4Account		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0003-InitialiseImap4Account
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0003-DoFullImap4Synchronisation
RUN_TEST_STEP 300 T_MsgImapServer	DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0003-DisConnectImap4Server
RUN_TEST_STEP 300 T_MsgImapServer	CheckChildrenCountImap		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0003-CheckChildrenCountRemoteInbox0
RUN_TEST_STEP 300 T_MsgSmtpServer	CreateSmtpMessageFromEmailFile	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0003-CreateSmtpMessageFromEmailFile
RUN_TEST_STEP 300 T_MsgSmtpServer	SendSmtpMessage			c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0003-SendSmtpMessage
RUN_TEST_STEP 300 T_MsgImapServer	SetImap4PartialDownloadLimits	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0003-SetImap4PartialDownloadLimits
RUN_TEST_STEP 300 T_MsgImapServer	ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0003-ConnectImap4Server
RUN_TEST_STEP 300 T_MsgImapServer	DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0003-DoFullImap4Synchronisation1
RUN_TEST_STEP 300 T_MsgImapServer	DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0003-DisConnectImap4Server
//Offline Populate
RUN_TEST_STEP 300 T_MsgImapServer	ImapInvokeAsyncFunction		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0003-ImapInvokeAsyncFunction
RUN_TEST_STEP 300 T_MsgImapServer	ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0003-ConnectImap4Server
RUN_TEST_STEP 300 T_MsgImapServer	DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0003-DoFullImap4Synchronisation1
RUN_TEST_STEP 300 T_MsgImapServer 	CompareEmailMessages		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0003-CompareEmailMessages
RUN_TEST_STEP 300 T_MsgImapServer	DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0003-DisConnectImap4Server
RUN_TEST_STEP 300 T_MsgImapServer	CheckChildrenCountImap		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0003-CheckChildrenCountRemoteInbox1

RUN_TEST_STEP	300	T_MsgCommonServer	ShutDown
RUN_TEST_STEP	300	T_MsgImapServer		ShutDown
RUN_TEST_STEP	300	T_MsgSmtpServer		ShutDown

PRINT Execute Completed ################################################
END_TESTCASE MSG_IMAP_Offline_Populate-0015


START_TESTCASE MSG_IMAP_Offline_Populate-0016
//! @SYMTestCaseID		MSG-IMAP-Offline-Populate-0016
//! @SYMTestType		CIT
//! @SYMTestPriority		High
//! @SYMTestStatus 		Implemented
//! @SYMTestCaseDependencies
//! @SYMTestCaseDesc		Verification:
//!		This test tests if Offline Populate downloads the message. It also compares the received messages with sent 
//!		messages based on the Download limits set.All The Attachments will be downloaded.BodyText 
//!		 size of <= 10000 would be downloaded.
//!	@SYMTestCaseDependencies	requires ced -i c:\ced_default_ras.cfg to set comms.
//! @SYMTestActions
//!	The Local Inbox and Sent Item folders and the remote Inbox folder of IMAP4 
//!	account are cleaned up before starting the test.
//! ------------------------------------------
//!	1.  Create emails from data file and send emails to the same account
//!	2.  Set the download limits
//!	3.  Download the mails with IMAP4 KIMAP4MTMPopulate command
//!	4.  Copy the mails from IMAP4 Inbox folder to Local inbox folder	
//!	5.  Compare the received messages with sent messages based on the Download limits set
//! Implementation and execution:
//!	The emails are sent to the sender's address only.
//!	New messages are created, sent and received.  The received messages are compared with 
//!	the sent messages, based on the download limits set, for size and contents.
//! Download Limits set:
//!	TImImap4GetPartialMailInfo::iTotalSizeLimit = Default Value ( KMaxInt)
//!	TImImap4GetPartialMailInfo::iBodyTextSizeLimit = 10000
//!	TImImap4GetPartialMailInfo::iAttachmentSizeLimit = Default Value ( KMaxInt)
//!	TImImap4PartialMailOptions::EBodyTextAndAttachments  
//!	Destination Folder : Remote Inbox folder
//! ------------------------------------------
//! @SYMTestExpectedResults
//!	If body text size of email <= TImImap4GetPartialMailInfo::iBodyTextSizeLimit
//!	The email should be completely downloaded with no footer string Information.
//!	If body text size of email > TImImap4GetPartialMailInfo::iBodyTextSizeLimit
//!	mail will be downloaded partially containing the footer string information
//!	All The Attachments will be downloaded.
//!	@SYMREQ				5578
//!	@SYMPREQ			1160

PRINT Setup Begins #####################################################

RUN_TEST_STEP	300	T_MsgCommonServer  	StartUp
RUN_TEST_STEP	300	T_MsgImapServer	StartUp
RUN_TEST_STEP	300	T_MsgSmtpServer	StartUp

RUN_TEST_STEP 300 T_MsgCommonServer 	InitNtRas			c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0004-InitNtRas
RUN_TEST_STEP 300 T_MsgCommonServer 	ResetMessageStore		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0004-ResetMessageStore
RUN_TEST_STEP 300 T_MsgImapServer	CreateImapAccount		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0004-CreateImapAccount
RUN_TEST_STEP 	100 	T_MsgImapServer		ChangeImap4SubAndSyncSettings	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0004-ChangeSubAndSyncSettings
RUN_TEST_STEP 	100 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0004-ConnectImap4Server
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0004-DoFullImap4Synchronisation
RUN_TEST_STEP 	100 	T_MsgImapServer		InitialiseImap4Account		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0004-InitialiseImap4Account
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0004-DoFullImap4Synchronisation
RUN_TEST_STEP 300 T_MsgImapServer	DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0004-DisConnectImap4Server
RUN_TEST_STEP 300 T_MsgImapServer	CheckChildrenCountImap		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0004-CheckChildrenCountRemoteInbox0
RUN_TEST_STEP 300 T_MsgSmtpServer	CreateSmtpMessageFromEmailFile	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0004-CreateSmtpMessageFromEmailFile
RUN_TEST_STEP 300 T_MsgSmtpServer	SendSmtpMessage			c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0004-SendSmtpMessage
RUN_TEST_STEP 300 T_MsgImapServer	SetImap4PartialDownloadLimits	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0004-SetImap4PartialDownloadLimits
RUN_TEST_STEP 300 T_MsgImapServer	ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0004-ConnectImap4Server
RUN_TEST_STEP 300 T_MsgImapServer	DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0004-DoFullImap4Synchronisation1
RUN_TEST_STEP 300 T_MsgImapServer	DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0004-DisConnectImap4Server
//Offline Populate
RUN_TEST_STEP 300 T_MsgImapServer	ImapInvokeAsyncFunction		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0004-ImapInvokeAsyncFunction
RUN_TEST_STEP 300 T_MsgImapServer	ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     0004-ConnectImap4Server
RUN_TEST_STEP 300 T_MsgImapServer	DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0004-DoFullImap4Synchronisation1
RUN_TEST_STEP 300 T_MsgImapServer 	CompareEmailMessages		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0004-CompareEmailMessages
RUN_TEST_STEP 300 T_MsgImapServer	DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0004-DisConnectImap4Server
RUN_TEST_STEP 300 T_MsgImapServer	CheckChildrenCountImap		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0004-CheckChildrenCountRemoteInbox1

RUN_TEST_STEP	300	T_MsgCommonServer	ShutDown
RUN_TEST_STEP	300	T_MsgImapServer		ShutDown
RUN_TEST_STEP	300	T_MsgSmtpServer		ShutDown

PRINT Execute Completed ################################################
END_TESTCASE MSG_IMAP_Offline_Populate-0016


START_TESTCASE	MSG_IMAP_Offline_Populate-0017
//!	@SYMTestCaseID			MSG-IMAP-Offline-Populate-0017
//!	@SYMTestCaseDesc		Verification:
//!		This test tests if Offline Populate downloads the message. It also compares the received messages with sent 
//!		messages based on the Download limits set. Only Body Text would be downloaded, partial Mail download Option is
//!		set to EBodyTextOnly
//!	@SYMTestPriority		Critical
//!   	@SYMTestType			CIT
//!  	@SYMTestStatus			Implemented   
//!	@SYMTestCaseDependencies	requires ced -i c:\ced_default_ras.cfg to set comms.
//!	@SYMTestActions			
//!		The Local Inbox and Sent Item folders and the remote Inbox folder of IMAP4 
//!		account are cleaned up before starting the test.
//! 	------------------------------------------
//!		1.  Create emails from RFC822 file and send emails to the same account
//!		2.  Set the download limits
//!		3.  Download the mails with IMAP4 KIMAP4MTMPopulate command and Partial download limits set
//!		4.  Compare the populated messages with sent messages based on the Download limits set
//! 		Implementation and execution:
//!			The emails are sent to the sender's address only.
//!			New messages are created, sent and received.  The received messages are compared with 
//!     		the sent messages, based on the download limits set, for size and contents.
//!		Download limits set: Parital Download limits is set
//!			MaxEmailSize = Default (KMaxInt)
//!			BodyTextSizeLimit = 2000
//!			AttachmentSizeLimit = 10000
//!			ImapPartialMailOption = TImImap4PartialMailOptions::EBodyTextOnly
//!			Destination Folder : Remote Inbox folder
//!	@SYMTestExpectedResults		EPass, The message is sent and received and also present in the local inbox folder.
//!					If body text size of email <= TImImap4GetPartialMailInfo::iBodyTextSizeLimit
//!					The email should be completely downloaded with no footer string Information.
//!					If body text size of email > TImImap4GetPartialMailInfo::iBodyTextSizeLimit
//!					mail will be downloaded partially containing the footer string information	
//!         				No Attachments will be downloaded.
//!	@SYMAuthor			Mrudul V. Pendharkar
//!	@SYMREQ				5578
//!	@SYMPREQ			1160

PRINT Setup Begins #####################################################

RUN_TEST_STEP	300	T_MsgCommonServer  	StartUp
RUN_TEST_STEP	300	T_MsgImapServer	StartUp
RUN_TEST_STEP	300	T_MsgSmtpServer	StartUp

RUN_TEST_STEP	300	T_MsgCommonServer	InitNtRas			c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0005-InitNtRas
RUN_TEST_STEP	300	T_MsgCommonServer	ResetMessageStore		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0005-ResetMessageStore
RUN_TEST_STEP 	300 	T_MsgImapServer		CreateImapAccount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0005-CreateImapAccount 
RUN_TEST_STEP 	100 	T_MsgImapServer		ChangeImap4SubAndSyncSettings	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0005-ChangeSubAndSyncSettings
RUN_TEST_STEP 	100 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0005-ConnectImap4Server
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0005-DoFullImap4Synchronisation
RUN_TEST_STEP 	100 	T_MsgImapServer		InitialiseImap4Account		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0005-InitialiseImap4Account
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0005-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0005-DisConnectImap4Server
PRINT Setup Completed
PRINT Execute begins
RUN_TEST_STEP 	300 	T_MsgSmtpServer		CreateSmtpMessageFromEmailFile 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0005-CreateSmtpMessageFromEmailFile
RUN_TEST_STEP 	300 	T_MsgCommonServer  	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0005-CheckChildrenCountOutbox
RUN_TEST_STEP 	300 	T_MsgSmtpServer		SendSmtpMessage 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0005-SendSmtpMessage
RUN_TEST_STEP 	300 	T_MsgCommonServer  	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0005-CheckChildrenCountSentItems
RUN_TEST_STEP 	300 	T_MsgImapServer		SetImap4PartialDownloadLimits 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0005-SetImap4PartialDownloadLimits
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0005-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0005-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0005-DisConnectImap4Server
//Offline Populate
RUN_TEST_STEP 	300 	T_MsgImapServer		ImapInvokeAsyncFunction      	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0005-ImapInvokeAsyncFunction
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0005-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0005-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer 	CompareEmailMessages		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0005-CompareEmailMessages
RUN_TEST_STEP 	300 	T_MsgImapServer		CopyImapSelection		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0005-CopyImapSelection
RUN_TEST_STEP 	300 	T_MsgCommonServer	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0005-CheckChildrenCountInbox
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0005-DisConnectImap4Server

RUN_TEST_STEP	300	T_MsgCommonServer	ShutDown
RUN_TEST_STEP	300	T_MsgImapServer		ShutDown
RUN_TEST_STEP	300	T_MsgSmtpServer		ShutDown

PRINT Execute Completed ################################################
END_TESTCASE	MSG_IMAP_Offline_Populate-0017


START_TESTCASE MSG-IMAP-Offline-Populate-0018
//!	@SYMTestCaseID			MSG-IMAP-Offline-Populate-0018
//!	@SYMTestCaseDesc		Verification:
//!		This test tests if Offline Populate downloads the message. It also compares the received messages with sent 
//!		messages based on the Download limits set.Body Text Size <= 30000 would be downloaded. Also No Attachment would
//!		be downloaded
//!	@SYMTestPriority		Critical
//!   	@SYMTestType			CIT
//!  	@SYMTestStatus			Implemented   
//!	@SYMTestCaseDependencies	requires ced -i c:\ced_default_ras.cfg to set comms.
//!	@SYMTestActions			
//!		The Local Inbox and Sent Item folders and the remote Inbox folder of IMAP4 
//!		account are cleaned up before starting the test.
//! 	------------------------------------------
//!		1.  Create emails from RFC822 file and send emails to the same account
//!		2.  Set the download limits
//!		3.  Download the mails with IMAP4 KIMAP4MTMPopulate command and Partial download limits set
//!		4.  Compare the populated messages with sent messages based on the Download limits set
//! 		Implementation and execution:
//!			The emails are sent to the sender's address only.
//!			New messages are created, sent and received.  The received messages are compared with 
//!     		the sent messages, based on the download limits set, for size and contents.
//!		Download limits set: Parital Download limits is set
//!			MaxEmailSize = Default (KMaxInt)
//!			BodyTextSizeLimit = 30000
//!			AttachmentSizeLimit = Default (KMaxInt)
//!			ImapPartialMailOption = TImImap4PartialMailOptions::EBodyTextOnly
//!			Destination Folder : Remote Inbox folder
//!	@SYMTestExpectedResults		EPass, The message is sent and received and also present in the local inbox folder.
//!					If body text size of email <= TImImap4GetPartialMailInfo::iBodyTextSizeLimit
//!					The email should be completely downloaded with no footer string Information.
//!					If body text size of email > TImImap4GetPartialMailInfo::iBodyTextSizeLimit
//!					mail will be downloaded partially containing the footer string information
//!					No Attachments will be downloaded.
//!	@SYMAuthor			Mrudul V. Pendharkar
//!	@SYMREQ				5578
//!	@SYMPREQ			1160

PRINT Setup Begins #####################################################

RUN_TEST_STEP	300	T_MsgCommonServer  	StartUp
RUN_TEST_STEP	300	T_MsgImapServer	StartUp
RUN_TEST_STEP	300	T_MsgSmtpServer	StartUp

RUN_TEST_STEP	300	T_MsgCommonServer	InitNtRas			c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0006-InitNtRas
RUN_TEST_STEP	300	T_MsgCommonServer	ResetMessageStore		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0006-ResetMessageStore
RUN_TEST_STEP 	300 	T_MsgImapServer		CreateImapAccount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0006-CreateImapAccount 
RUN_TEST_STEP 	100 	T_MsgImapServer		ChangeImap4SubAndSyncSettings	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0006-ChangeSubAndSyncSettings
RUN_TEST_STEP 	100 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0006-ConnectImap4Server
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0006-DoFullImap4Synchronisation
RUN_TEST_STEP 	100 	T_MsgImapServer		InitialiseImap4Account		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0006-InitialiseImap4Account
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0006-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0006-DisConnectImap4Server
PRINT Setup Completed
PRINT Execute begins
RUN_TEST_STEP 	300 	T_MsgSmtpServer		CreateSmtpMessageFromEmailFile 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0006-CreateSmtpMessageFromEmailFile
RUN_TEST_STEP 	300 	T_MsgCommonServer	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0006-CheckChildrenCountOutbox
RUN_TEST_STEP 	300 	T_MsgSmtpServer		SendSmtpMessage 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0006-SendSmtpMessage
RUN_TEST_STEP 	300 	T_MsgCommonServer 	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0006-CheckChildrenCountSentItems
RUN_TEST_STEP 	300 	T_MsgImapServer		SetImap4PartialDownloadLimits 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0006-SetImap4PartialDownloadLimits
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0006-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0006-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0006-DisConnectImap4Server
//Offline Populate
RUN_TEST_STEP 	300 	T_MsgImapServer		ImapInvokeAsyncFunction      	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0006-ImapInvokeAsyncFunction
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0006-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0006-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer 	CompareEmailMessages		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0006-CompareEmailMessages
RUN_TEST_STEP 	300 	T_MsgImapServer		CopyImapSelection		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0006-CopyImapSelection
RUN_TEST_STEP 	300 	T_MsgCommonServer  	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0006-CheckChildrenCountInbox
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0006-DisConnectImap4Server

RUN_TEST_STEP	300	T_MsgCommonServer	ShutDown
RUN_TEST_STEP	300	T_MsgImapServer		ShutDown
RUN_TEST_STEP	300	T_MsgSmtpServer		ShutDown

PRINT Execute Completed ################################################
END_TESTCASE	MSG-IMAP-Offline-Populate-0018


START_TESTCASE	MSG_IMAP_Offline_Populate-0019
//!	@SYMTestCaseID			MSG-IMAP-Offline-Populate-0019
//!	@SYMTestCaseDesc		Verification:
//!		This test tests if Offline Populate downloads the message. It also compares the received messages with sent 
//!		messages based on the Download limits set.It uses EBodyTextOnly option for downloading of Messages.
//!	@SYMTestPriority		Critical
//!   	@SYMTestType			CIT
//!  	@SYMTestStatus			Implemented   
//!	@SYMTestCaseDependencies	requires ced -i c:\ced_default_ras.cfg to set comms.
//!	@SYMTestActions			
//!		The Local Inbox and Sent Item folders and the remote Inbox folder of IMAP4 
//!		account are cleaned up before starting the test.
//! 	------------------------------------------
//!		1.  Create emails from RFC822 file and send emails to the same account
//!		2.  Set the download limits
//!		3.  Download the mails with IMAP4 KIMAP4MTMPopulate command and Partial download limits set
//!		4.  Compare the populated messages with sent messages based on the Download limits set
//! 		Implementation and execution:
//!			The emails are sent to the sender's address only.
//!			New messages are created, sent and received.  The received messages are compared with 
//!     		the sent messages, based on the download limits set, for size and contents.
//!		Download limits set: Parital Download limits is set
//!			MaxEmailSize = Default (KMaxInt)
//!			BodyTextSizeLimit = 4000
//!			AttachmentSizeLimit = Default (KMaxInt)
//!			ImapPartialMailOption = TImImap4PartialMailOptions::EBodyTextOnly
//!			Destination Folder : Remote Inbox folder
//!	@SYMTestExpectedResults		EPass, The message is sent ,received and also present in the local inbox folder.
//!					If body text size of email <= TImImap4GetPartialMailInfo::iBodyTextSizeLimit
//!					The email should be completely downloaded with no footer string Information.
//!					If body text size of email > TImImap4GetPartialMailInfo::iBodyTextSizeLimit
//!					mail will be downloaded partially containing the footer string information
//!					No Attachments will be downloaded.
//!	@SYMAuthor			Mrudul V. Pendharkar
//!	@SYMREQ				5578
//!	@SYMPREQ			1160

PRINT Setup Begins #####################################################

RUN_TEST_STEP	300	T_MsgCommonServer  	StartUp
RUN_TEST_STEP	300	T_MsgImapServer	StartUp
RUN_TEST_STEP	300	T_MsgSmtpServer	StartUp

RUN_TEST_STEP	300	T_MsgCommonServer	InitNtRas			c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0007-InitNtRas
RUN_TEST_STEP	300	T_MsgCommonServer	ResetMessageStore		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0007-ResetMessageStore
RUN_TEST_STEP 	300 	T_MsgImapServer		CreateImapAccount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0007-CreateImapAccount 
RUN_TEST_STEP 	100 	T_MsgImapServer		ChangeImap4SubAndSyncSettings	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0007-ChangeSubAndSyncSettings
RUN_TEST_STEP 	100 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0007-ConnectImap4Server
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0007-DoFullImap4Synchronisation
RUN_TEST_STEP 	100 	T_MsgImapServer		InitialiseImap4Account		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0007-InitialiseImap4Account
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0007-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0007-DisConnectImap4Server
PRINT Setup Completed
PRINT Execute begins
RUN_TEST_STEP 	300 	T_MsgSmtpServer		CreateSmtpMessageFromEmailFile 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0007-CreateSmtpMessageFromEmailFile
RUN_TEST_STEP 	300 	T_MsgCommonServer	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0007-CheckChildrenCountOutbox
RUN_TEST_STEP 	300 	T_MsgSmtpServer		SendSmtpMessage 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0007-SendSmtpMessage
RUN_TEST_STEP 	300 	T_MsgCommonServer	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0007-CheckChildrenCountSentItems
RUN_TEST_STEP 	300 	T_MsgImapServer		SetImap4PartialDownloadLimits 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0007-SetImap4PartialDownloadLimits
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0007-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0007-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0007-DisConnectImap4Server
//Offline Populate
RUN_TEST_STEP 	300 	T_MsgImapServer		ImapInvokeAsyncFunction      	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0007-ImapInvokeAsyncFunction
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0007-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0007-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer 	CompareEmailMessages		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0007-CompareEmailMessages
RUN_TEST_STEP 	300 	T_MsgImapServer		CopyImapSelection		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0007-CopyImapSelection
RUN_TEST_STEP 	300 	T_MsgCommonServer	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0007-CheckChildrenCountInbox
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0007-DisConnectImap4Server

RUN_TEST_STEP	300	T_MsgCommonServer	ShutDown
RUN_TEST_STEP	300	T_MsgImapServer		ShutDown
RUN_TEST_STEP	300	T_MsgSmtpServer		ShutDown

PRINT Execute Completed ################################################
END_TESTCASE	MSG_IMAP_Offline_Populate-0019


START_TESTCASE	MSG_IMAP_Offline_Populate-0020
//!	@SYMTestCaseID			MSG-IMAP-Offline-Populate-0020
//!	@SYMTestCaseDesc		Verification:
//!		This test tests if Offline Populate downloads the message. It also compares the received messages with sent 
//!		messages based on the Download limits set. It sends two Messages and Compares for download Limit set a EBodyTextOnly.
//!	@SYMTestPriority		Critical
//!   	@SYMTestType			CIT
//!  	@SYMTestStatus			Implemented
//!	@SYMTestCaseDependencies	requires ced -i c:\ced_default_ras.cfg to set comms.
//!	@SYMTestActions			
//!		The Local Inbox and Sent Item folders and the remote Inbox folder of IMAP4 
//!		account are cleaned up before starting the test.
//! 	------------------------------------------
//!		1.  Create emails from RFC822 file and send emails to the same account
//!		2.  Set the download limits
//!		3.  Download the mails with IMAP4 KIMAP4MTMPopulate command and Partial download limits set
//!		4.  Compare the populated messages with sent messages based on the Download limits set
//! 		Implementation and execution:
//!			The emails are sent to the sender's address only.
//!			New messages are created, sent and received.  The received messages are compared with 
//!     		the sent messages, based on the download limits set, for size and contents.
//!		Download limits set: Parital Download limits is set
//!			MaxEmailSize = Default (KMaxInt)
//!			BodyTextSizeLimit = 4000
//!			AttachmentSizeLimit = Default (KMaxInt)
//!			ImapPartialMailOption = TImImap4PartialMailOptions::EBodyTextOnly
//!			Destination Folder : Remote Inbox folder
//!	@SYMTestExpectedResults		EPass, The message is sent and received and also present in the local inbox folder.
//!					If body text size of email <= TImImap4GetPartialMailInfo::iBodyTextSizeLimit
//!					All the email should be completely downloaded with no footer string Information.
//!					If body text size of email > TImImap4GetPartialMailInfo::iBodyTextSizeLimit
//!					mail will be downloaded partially containing the footer string information
//!          				No Attachments will be downloaded.
//!	@SYMAuthor			Mrudul V. Pendharkar
//!	@SYMREQ				5578
//!	@SYMPREQ			1160

PRINT Setup Begins #####################################################

RUN_TEST_STEP	300	T_MsgCommonServer  	StartUp
RUN_TEST_STEP	300	T_MsgImapServer	StartUp
RUN_TEST_STEP	300	T_MsgSmtpServer	StartUp

RUN_TEST_STEP	300	T_MsgCommonServer	InitNtRas			c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0008-InitNtRas
RUN_TEST_STEP	300	T_MsgCommonServer	ResetMessageStore		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0008-ResetMessageStore
RUN_TEST_STEP 	300 	T_MsgImapServer		CreateImapAccount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0008-CreateImapAccount 
RUN_TEST_STEP 	100 	T_MsgImapServer		ChangeImap4SubAndSyncSettings	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0008-ChangeSubAndSyncSettings
RUN_TEST_STEP 	100 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0008-ConnectImap4Server
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0008-DoFullImap4Synchronisation
RUN_TEST_STEP 	100 	T_MsgImapServer		InitialiseImap4Account		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0008-InitialiseImap4Account
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0008-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0008-DisConnectImap4Server
PRINT Setup Completed
PRINT Execute begins
RUN_TEST_STEP 	300 	T_MsgSmtpServer		CreateSmtpMessageFromEmailFile 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0008-CreateSmtpMessageFromEmailFile
RUN_TEST_STEP 	300 	T_MsgCommonServer	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0008-CheckChildrenCountOutbox
RUN_TEST_STEP 	300 	T_MsgSmtpServer		SendSmtpMessage 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0008-SendSmtpMessage
RUN_TEST_STEP 	300 	T_MsgCommonServer	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0008-CheckChildrenCountSentItems
RUN_TEST_STEP 	300 	T_MsgSmtpServer		CreateSmtpMessageFromEmailFile 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0008-CreateSmtpMessageFromEmailFile1
RUN_TEST_STEP 	300 	T_MsgCommonServer	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0008-CheckChildrenCountOutbox1
RUN_TEST_STEP 	300 	T_MsgSmtpServer		SendSmtpMessage 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0008-SendSmtpMessage1
RUN_TEST_STEP 	300 	T_MsgCommonServer	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0008-CheckChildrenCountSentItems1
RUN_TEST_STEP 	300 	T_MsgImapServer		SetImap4PartialDownloadLimits 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0008-SetImap4PartialDownloadLimits
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0008-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0008-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0008-DisConnectImap4Server
//Offline Populate
RUN_TEST_STEP 	300 	T_MsgImapServer		ImapInvokeAsyncFunction      	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0008-ImapInvokeAsyncFunction
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0008-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0008-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer 	CompareEmailMessages		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      		0008-CompareEmailMessages
RUN_TEST_STEP 	300 	T_MsgImapServer		CopyImapSelection		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0008-CopyImapSelection
RUN_TEST_STEP 	300 	T_MsgCommonServer	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0008-CheckChildrenCountInbox
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0008-DisConnectImap4Server

RUN_TEST_STEP	300	T_MsgCommonServer	ShutDown
RUN_TEST_STEP	300	T_MsgImapServer		ShutDown
RUN_TEST_STEP	300	T_MsgSmtpServer		ShutDown

PRINT Execute Completed ################################################
END_TESTCASE	MSG_IMAP_Offline_Populate-0020


START_TESTCASE	MSG_IMAP_Offline_Populate-0021
//!	@SYMTestCaseID			MSG-IMAP-Offline-Populate-0021
//!	@SYMTestCaseDesc		Verification:
//!		This test tests if Offline Populate downloads the message. It also compares the received messages with sent 
//!		messages based on the Download limits set. It tries to validate ENoSizeLimits Option for Downloading
//!	@SYMTestPriority		Critical
//!   	@SYMTestType			CIT
//!  	@SYMTestStatus			Implemented   
//!	@SYMTestCaseDependencies	requires ced -i c:\ced_default_ras.cfg to set comms.
//!	@SYMTestActions			
//!		The Local Inbox and Sent Item folders and the remote Inbox folder of IMAP4 
//!		account are cleaned up before starting the test.
//! 	------------------------------------------
//!		1.  Create emails from RFC822 file and send emails to the same account
//!		2.  Set the download limits
//!		3.  Download the mails with IMAP4 KIMAP4MTMPopulate command and Partial download limits set
//!		4.  Compare the populated messages with sent messages based on the Download limits set
//! 		Implementation and execution:
//!			The emails are sent to the sender's address only.
//!			New messages are created, sent and received.  The received messages are compared with 
//!     		the sent messages, based on the download limits set, for size and contents.
//!		Download limits set: Parital Download limits is set
//!			MaxEmailSize = Default (KMaxInt)
//!			BodyTextSizeLimit = Default (KMaxInt)
//!			AttachmentSizeLimit = Default (KMaxInt)
//!			ImapPartialMailOption = TImImap4PartialMailOptions::ENoSizeLimits
//!			Destination Folder : Remote Inbox folder
//!	@SYMTestExpectedResults		EPass, The message is sent and received and also present in the local inbox folder.
//!					All The Mails along all the attachments 
//!					will be downloaded without any footer string information.
//!	@SYMAuthor			Mrudul V. Pendharkar
//!	@SYMREQ				5578
//!	@SYMPREQ			1160

PRINT Setup Begins #####################################################

RUN_TEST_STEP	300	T_MsgCommonServer  	StartUp
RUN_TEST_STEP	300	T_MsgImapServer	StartUp
RUN_TEST_STEP	300	T_MsgSmtpServer	StartUp

RUN_TEST_STEP	300	T_MsgCommonServer  	InitNtRas			c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0009-InitNtRas
RUN_TEST_STEP	300	T_MsgCommonServer  	ResetMessageStore		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0009-ResetMessageStore
RUN_TEST_STEP 	300 	T_MsgImapServer		CreateImapAccount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0009-CreateImapAccount 
RUN_TEST_STEP 	100 	T_MsgImapServer		ChangeImap4SubAndSyncSettings	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0009-ChangeSubAndSyncSettings
RUN_TEST_STEP 	100 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0009-ConnectImap4Server
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0009-DoFullImap4Synchronisation
RUN_TEST_STEP 	100 	T_MsgImapServer		InitialiseImap4Account		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0009-InitialiseImap4Account
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0009-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0009-DisConnectImap4Server
PRINT Setup Completed
PRINT Execute begins
RUN_TEST_STEP 	300 	T_MsgSmtpServer    	CreateSmtpMessageFromEmailFile 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0009-CreateSmtpMessageFromEmailFile
RUN_TEST_STEP 	300 	T_MsgCommonServer  	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0009-CheckChildrenCountOutbox
RUN_TEST_STEP 	300 	T_MsgSmtpServer    	SendSmtpMessage 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0009-SendSmtpMessage
RUN_TEST_STEP 	300 	T_MsgCommonServer  	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0009-CheckChildrenCountSentItems
RUN_TEST_STEP 	300 	T_MsgSmtpServer    	CreateSmtpMessageFromEmailFile 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0009-CreateSmtpMessageFromEmailFile1
RUN_TEST_STEP 	300 	T_MsgCommonServer  	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0009-CheckChildrenCountOutbox1
RUN_TEST_STEP 	300 	T_MsgSmtpServer    	SendSmtpMessage 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0009-SendSmtpMessage1
RUN_TEST_STEP 	300 	T_MsgCommonServer  	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0009-CheckChildrenCountSentItems1
RUN_TEST_STEP 	300 	T_MsgImapServer		SetImap4PartialDownloadLimits 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0009-SetImap4PartialDownloadLimits
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0009-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0009-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0009-DisConnectImap4Server
//Offline Populate
RUN_TEST_STEP 	300 	T_MsgImapServer		ImapInvokeAsyncFunction      	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0009-ImapInvokeAsyncFunction
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0009-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0009-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer 	CompareEmailMessages		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      		0009-CompareEmailMessages
RUN_TEST_STEP 	300 	T_MsgImapServer		CopyImapSelection		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0009-CopyImapSelection
RUN_TEST_STEP 	300 	T_MsgCommonServer  	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0009-CheckChildrenCountInbox
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0009-DisConnectImap4Server

RUN_TEST_STEP	300	T_MsgCommonServer	ShutDown
RUN_TEST_STEP	300	T_MsgImapServer		ShutDown
RUN_TEST_STEP	300	T_MsgSmtpServer		ShutDown

PRINT Execute Completed ################################################
END_TESTCASE	MSG_IMAP_Offline_Populate-0021


START_TESTCASE MSG_IMAP_Offline_Populate-0022
//! @SYMTestCaseID		MSG-IMAP-Offline-Populate-0022
//! @SYMTestType		CIT
//! @SYMTestPriority		High
//! @SYMTestStatus 		Implemented
//! @SYMTestCaseDependencies
//! @SYMTestCaseDesc		Verification:
//!		This test tests if Offline Populate downloads the message. It also compares the received messages with sent 
//!		messages based on the Download limits set. It tries to validate Populate command for Partial and full download
//!		Limits set as EBodyTextAndAttachments & EGetImap4EmailBodyTextAndAttachments respectively.
//!	@SYMTestCaseDependencies	requires ced -i c:\ced_default_ras.cfg to set comms.
//! @SYMTestActions
//!	The Local Inbox and Sent Item folders and the remote Inbox folder of IMAP4 
//!	account are cleaned up before starting the test.
//! ------------------------------------------
//! 	1.  Create emails from data file and send emails to the same account
//!	2.  Set the download limits
//!	3.  Download the mails by calling asynchronous function KIMAP4MTMPopulate
//!	    and KIMAP4MTMPopulateMailSelectionWhenAlreadyConnected command
//!	4.  Copy the mails from IMAP4 Inbox folder to Local inbox folder.
//!	5.  Disconnect from the IMAP4 server
//!	6.  Compare the received messages with sent messages based on the Download limits set
//! Implementation and execution:
//!	The emails are sent to the sender's address only.
//!	New messages are created, sent and received.  The received messages are compared with 
//!	the sent messages, based on the download limits set, for size and contents.
//! Download Limits set:
//!	TImImap4GetPartialMailInfo::iTotalSizeLimit = Default
//!	TImImap4GetPartialMailInfo::iBodyTextSizeLimit = Default
//!	TImImap4GetPartialMailInfo::iAttachmentSizeLimit = Default
//!	TImImap4PartialMailOptions::EBodyTextAndAttachments
//!	TImap4GetMailOptions::EGetImap4EmailBodyTextAndAttachments
//!	Destination Folder : Remote Inbox folder
//! ------------------------------------------
//! @SYMTestExpectedResults
//!	If body text size of email <= TImImap4GetPartialMailInfo::iBodyTextSizeLimit
//!	All the email should be completely downloaded with no footer string Information.
//!	If body text size of email > TImImap4GetPartialMailInfo::iBodyTextSizeLimit
//!	mail will be downloaded partially containing the footer string information
//!	All The Attachments having size <= TImImap4GetPartialMailInfo::iAttachmentSizeLimit
//!	will be downloaded.
//!	@SYMREQ				5578
//!	@SYMPREQ			1160

PRINT Setup Begins #####################################################

RUN_TEST_STEP	300	T_MsgCommonServer  	StartUp
RUN_TEST_STEP	300	T_MsgImapServer	StartUp
RUN_TEST_STEP	300	T_MsgSmtpServer	StartUp

RUN_TEST_STEP 220 T_MsgCommonServer 	InitNtRas			c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0010-InitNtRas
RUN_TEST_STEP 220 T_MsgCommonServer 	ResetMessageStore		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0010-ResetMessageStore
RUN_TEST_STEP 220 T_MsgImapServer	CreateImapAccount		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0010-CreateImapAccount
RUN_TEST_STEP 	100 	T_MsgImapServer		ChangeImap4SubAndSyncSettings	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0010-ChangeSubAndSyncSettings
RUN_TEST_STEP 	100 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0010-ConnectImap4Server
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0010-DoFullImap4Synchronisation
RUN_TEST_STEP 	100 	T_MsgImapServer		InitialiseImap4Account		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0010-InitialiseImap4Account
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0010-DoFullImap4Synchronisation
RUN_TEST_STEP 220 T_MsgImapServer	DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0010-DisConnectImap4Server
RUN_TEST_STEP 220 T_MsgImapServer	CheckChildrenCountImap		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0010-CheckChildrenCountRemoteInbox0
RUN_TEST_STEP 220 T_MsgSmtpServer    	CreateSmtpMessageFromEmailFile	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0010-CreateSmtpMessageFromEmailFile0
RUN_TEST_STEP 220 T_MsgSmtpServer    	SendSmtpMessage			c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0010-SendSmtpMessage0
RUN_TEST_STEP 220 T_MsgSmtpServer    	CreateSmtpMessageFromEmailFile	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     0010-CreateSmtpMessageFromEmailFile1
RUN_TEST_STEP 220 T_MsgSmtpServer    	SendSmtpMessage			c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0010-SendSmtpMessage1
RUN_TEST_STEP 220 T_MsgImapServer	SetImap4PartialDownloadLimits	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0010-SetImap4PartialDownloadLimits
RUN_TEST_STEP 220 T_MsgImapServer	ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0010-ConnectImap4Server
RUN_TEST_STEP 220 T_MsgImapServer	DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0010-DoFullImap4Synchronisation1
RUN_TEST_STEP 220 T_MsgImapServer	DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0010-DisConnectImap4Server
//Offline Populate
RUN_TEST_STEP 220 T_MsgImapServer	ImapInvokeAsyncFunction		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0010-ImapInvokeAsyncFunction0
RUN_TEST_STEP 220 T_MsgImapServer	ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0010-ConnectImap4Server
RUN_TEST_STEP 220 T_MsgImapServer	DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0010-DoFullImap4Synchronisation1
RUN_TEST_STEP 220 T_MsgImapServer 	CompareEmailMessages		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0010-CompareEmailMessages
RUN_TEST_STEP 220 T_MsgImapServer	SetImap4FullDownloadLimits	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0010-SetImap4FullDownloadLimits
RUN_TEST_STEP 220 T_MsgImapServer	ImapInvokeAsyncFunction		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0010-ImapInvokeAsyncFunction1
RUN_TEST_STEP 220 T_MsgImapServer	DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0010-DisConnectImap4Server
RUN_TEST_STEP 220 T_MsgImapServer	CheckChildrenCountImap		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0010-CheckChildrenCountRemoteInbox1

RUN_TEST_STEP	300	T_MsgCommonServer	ShutDown
RUN_TEST_STEP	300	T_MsgImapServer		ShutDown
RUN_TEST_STEP	300	T_MsgSmtpServer		ShutDown

PRINT Execute Completed ################################################
END_TESTCASE MSG_IMAP_Offline_Populate-0022


START_TESTCASE MSG_IMAP_Offline_Populate-0023
//! @SYMTestCaseID		MSG-IMAP-Offline-Populate-0023
//! @SYMTestType		CIT
//! @SYMTestPriority		High
//! @SYMTestStatus 		Implemented
//! @SYMTestCaseDependencies
//! @SYMTestCaseDesc		Verification:
//!		This test tests if Offline Populate downloads the message. It also compares the received messages with sent 
//!		messages based on the Download limits set. It tries to validate Full Download Limits set as 
//!		EGetImap4EmailBodyTextAndAttachments for Populate.
//!	@SYMTestCaseDependencies	requires ced -i c:\ced_default_ras.cfg to set comms.
//! @SYMTestActions
//!	The Local Inbox and Sent Item folders and the remote Inbox folder of IMAP4 
//!	account are cleaned up before starting the test.
//! ------------------------------------------
//!	1.  Create emails from RFC822 file and send emails to the same account
//!	2.  Set the download limits
//!	3.  Download the mails with IMAP4 KIMAP4MTMPopulate command
//!	4.  Copy the mails from IMAP4 Inbox folder to Local inbox folder	
//!	5.  Compare the received messages with sent messages based on the Download limits set
//! Implementation and execution:
//!	The emails are sent to the sender's address only.
//!	New messages are created, sent and received.  The received messages are compared with 
//!	the sent messages, based on the download limits set, for size and contents.
//! Download Limits set: Full DownLoad limits is set as follows
//!	TImap4GetMailOptions::TotalSizeLimit = 30000
//!	TImap4GetMailOptions::EGetImap4EmailBodyTextAndAttachments
//! ------------------------------------------
//! @SYMTestExpectedResults
//!	If the Total email size <= TImap4GetMailOptions::TotalSizeLimit,
//!	complete body text and attachment should be downloaded.
//!	If the Total email size >= TImap4GetMailOptions::TotalSizeLimit,No body text and 
//!	no Attachment will be downloaded.
//!	@SYMREQ				5578
//!	@SYMPREQ			1160
PRINT Setup Begins #####################################################

RUN_TEST_STEP	300	T_MsgCommonServer  	StartUp
RUN_TEST_STEP	300	T_MsgImapServer	StartUp
RUN_TEST_STEP	300	T_MsgSmtpServer	StartUp

RUN_TEST_STEP 300 T_MsgCommonServer	InitNtRas			c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0011-InitNtRas
RUN_TEST_STEP 300 T_MsgCommonServer	ResetMessageStore		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0011-ResetMessageStore
RUN_TEST_STEP 300 T_MsgImapServer	CreateImapAccount		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0011-CreateImapAccount
RUN_TEST_STEP 	100 	T_MsgImapServer		ChangeImap4SubAndSyncSettings	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0011-ChangeSubAndSyncSettings
RUN_TEST_STEP 	100 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0011-ConnectImap4Server
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0011-DoFullImap4Synchronisation
RUN_TEST_STEP 	100 	T_MsgImapServer		InitialiseImap4Account		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     0011-InitialiseImap4Account
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0011-DoFullImap4Synchronisation
RUN_TEST_STEP 300 T_MsgImapServer	DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0011-DisConnectImap4Server
RUN_TEST_STEP 300 T_MsgImapServer	CheckChildrenCountImap		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0011-CheckChildrenCountRemoteInbox0
RUN_TEST_STEP 300 T_MsgSmtpServer 	CreateSmtpMessageFromEmailFile	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0011-CreateSmtpMessageFromEmailFile
RUN_TEST_STEP 300 T_MsgSmtpServer 	SendSmtpMessage			c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0011-SendSmtpMessage
RUN_TEST_STEP 300 T_MsgImapServer	SetImap4FullDownloadLimits	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0011-SetImap4FullDownloadLimits
RUN_TEST_STEP 300 T_MsgImapServer	ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0011-ConnectImap4Server
RUN_TEST_STEP 300 T_MsgImapServer	DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0011-DoFullImap4Synchronisation1
RUN_TEST_STEP 300 T_MsgImapServer	DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0011-DisConnectImap4Server
//Offline Populate
RUN_TEST_STEP 300 T_MsgImapServer	ImapInvokeAsyncFunction		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0011-ImapInvokeAsyncFunction
RUN_TEST_STEP 300 T_MsgImapServer	ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0011-ConnectImap4Server
RUN_TEST_STEP 300 T_MsgImapServer	DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0011-DoFullImap4Synchronisation1
RUN_TEST_STEP 300 T_MsgImapServer 	CompareEmailMessages		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0011-CompareEmailMessages
RUN_TEST_STEP 300 T_MsgImapServer	DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0011-DisConnectImap4Server
RUN_TEST_STEP 300 T_MsgImapServer	CheckChildrenCountImap		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0011-CheckChildrenCountRemoteInbox1

RUN_TEST_STEP	300	T_MsgCommonServer	ShutDown
RUN_TEST_STEP	300	T_MsgImapServer		ShutDown
RUN_TEST_STEP	300	T_MsgSmtpServer		ShutDown

PRINT Execute Completed ################################################
END_TESTCASE MSG_IMAP_Offline_Populate-0023


START_TESTCASE MSG_IMAP_Offline_Populate-0024
//! @SYMTestCaseID		MSG-IMAP-Offline-Populate-0024
//! @SYMTestType		CIT
//! @SYMTestPriority		High
//! @SYMTestStatus 		Implemented
//! @SYMTestCaseDependencies
//! @SYMTestCaseDesc		Verification:
//!		This test tests if Offline Populate downloads the message. It also compares the received messages with sent 
//!		messages based on the Download limits set.It tries to validate Populate command for Full Download Limit set
//!		as EGetImap4EmailAttachments. This Option will only download Attachments
//!	@SYMTestCaseDependencies	requires ced -i c:\ced_default_ras.cfg to set comms.
//! @SYMTestActions
//!	The Local Inbox and Sent Item folders and the remote Inbox folder of IMAP4 
//!	account are cleaned up before starting the test.
//! ------------------------------------------
//!	1.  Create emails from data file and send emails to the same account
//!	2.  Set the download limits
//!	3.  Download the mails with IMAP4 KIMAP4MTMPopulate command
//!	4.  Copy the mails from IMAP4 Inbox folder to Local inbox folder	
//!	5.  Compare the received messages with sent messages based on the Download limits set
//! Implementation and execution:
//!	The emails are sent to the sender's address only.
//!	New messages are created, sent and received.  The received messages are compared with 
//!	the sent messages, based on the download limits set, for size and contents.
//! Download Limits set: Full DownLoad limits is set as follows
//!	TImap4GetMailOptions::TotalSizeLimit = 20000
//!	TImap4GetMailOptions::EGetImap4EmailAttachments
//! ------------------------------------------
//! @SYMTestExpectedResults
//!	If the Total email size <= TImap4GetMailOptions::TotalSizeLimit,
//!	complete body text and attachment should be downloaded.
//!	If the Total email size >= TImap4GetMailOptions::TotalSizeLimit,No body text and 
//!	no Attachment will be downloaded.
//!	@SYMREQ				5578
//!	@SYMPREQ			1160

PRINT Setup Begins #####################################################

RUN_TEST_STEP	300	T_MsgCommonServer  	StartUp
RUN_TEST_STEP	300	T_MsgImapServer	StartUp
RUN_TEST_STEP	300	T_MsgSmtpServer	StartUp

RUN_TEST_STEP 300 T_MsgCommonServer 	InitNtRas			c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0012-InitNtRas
RUN_TEST_STEP 300 T_MsgCommonServer 	ResetMessageStore		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0012-ResetMessageStore
RUN_TEST_STEP 300 T_MsgImapServer 	CreateImapAccount		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0012-CreateImapAccount
RUN_TEST_STEP 	100 	T_MsgImapServer		ChangeImap4SubAndSyncSettings	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0012-ChangeSubAndSyncSettings
RUN_TEST_STEP 	100 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0012-ConnectImap4Server
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0012-DoFullImap4Synchronisation
RUN_TEST_STEP 	100 	T_MsgImapServer		InitialiseImap4Account		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0012-InitialiseImap4Account
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0012-DoFullImap4Synchronisation
RUN_TEST_STEP 300 T_MsgImapServer 	DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0012-DisConnectImap4Server
RUN_TEST_STEP 300 T_MsgImapServer 	CheckChildrenCountImap		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0012-CheckChildrenCountRemoteInbox0
RUN_TEST_STEP 300 T_MsgSmtpServer 	CreateSmtpMessageFromEmailFile	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0012-CreateSmtpMessageFromEmailFile
RUN_TEST_STEP 300 T_MsgSmtpServer 	SendSmtpMessage			c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0012-SendSmtpMessage
RUN_TEST_STEP 300 T_MsgImapServer 	SetImap4FullDownloadLimits	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0012-SetImap4FullDownloadLimits
RUN_TEST_STEP 300 T_MsgImapServer 	ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0012-ConnectImap4Server
RUN_TEST_STEP 300 T_MsgImapServer 	DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0012-DoFullImap4Synchronisation1
RUN_TEST_STEP 300 T_MsgImapServer 	DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     0012-DisConnectImap4Server
//Offline Populate
RUN_TEST_STEP 300 T_MsgImapServer 	ImapInvokeAsyncFunction		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0012-ImapInvokeAsyncFunction
RUN_TEST_STEP 300 T_MsgImapServer 	ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0012-ConnectImap4Server
RUN_TEST_STEP 300 T_MsgImapServer 	DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0012-DoFullImap4Synchronisation1
RUN_TEST_STEP 300 T_MsgImapServer 	CompareEmailMessages		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0012-CompareEmailMessages
RUN_TEST_STEP 300 T_MsgImapServer 	DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0012-DisConnectImap4Server
RUN_TEST_STEP 300 T_MsgImapServer 	CheckChildrenCountImap		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      0012-CheckChildrenCountRemoteInbox1

RUN_TEST_STEP	300	T_MsgCommonServer	ShutDown
RUN_TEST_STEP	300	T_MsgImapServer		ShutDown
RUN_TEST_STEP	300	T_MsgSmtpServer		ShutDown

PRINT Execute Completed ################################################
END_TESTCASE MSG_IMAP_Offline_Populate-0024


START_TESTCASE	MSG_IMAP_Offline_Populate-0025
//!	@SYMTestCaseID			MSG-IMAP-Offline-Populate-0025
//!	@SYMTestCaseDesc		Verification:
//!		This test tests if Offline Populate downloads the message. It also compares the received messages with sent 
//!		messages based on the Download limits set.It validates Populate command for Full Download Option set as 
//!		EGetImap4EmailHeaders. This option should download only Headers
//!	@SYMTestPriority		Critical
//!   	@SYMTestType			CIT
//!  	@SYMTestStatus			Implemented   
//!	@SYMTestCaseDependencies	requires ced -i c:\ced_default_ras.cfg to set comms.
//!	@SYMTestActions			Initialises the RAS connection
//!					Resets the message store to clean up the central repository
//!					Creates an IMAP account by reading the settings from the file mentioned
//!					thus setting the IMAP and SMTP service settings
//!					Connects to the IMAP server and performs full sync with IMAP4 server.
//!					Connects to the IMAP server and deletes all mails in the Inbox on the server.
//!					Creates a message from RFC822 file and send the message to the same IMAP account.
//!					Set the partial download limits.
//!					Download the mails with IMAP4 KIMAP4MTMPopulate command and 
//!					compares the received messages with sent messages based on the Download limits set.
//!					Copies the mails from IMAP4 Inbox folder to Local inbox folder.
//!					Download Limit:
//!						MaxEmailSize = 30000
//!						ImapMailOption = TImap4GetMailOptions::EGetImap4EmailHeaders
//!	@SYMTestExpectedResults		EPass, The message is sent and received and also present in the local inbox folder.
//!					Headers of the mails will be downloaded irrespective of the limits set for the 
//!					for the download.
//!	@SYMAuthor			Mrudul V. Pendharkar
//!	@SYMREQ				5578
//!	@SYMPREQ			1160

PRINT Setup Begins #####################################################

RUN_TEST_STEP	300	T_MsgCommonServer  	StartUp
RUN_TEST_STEP	300	T_MsgImapServer	StartUp
RUN_TEST_STEP	300	T_MsgSmtpServer	StartUp

RUN_TEST_STEP	300	T_MsgCommonServer	InitNtRas			c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0013-InitNtRas
RUN_TEST_STEP	300	T_MsgCommonServer	ResetMessageStore		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0013-ResetMessageStore
RUN_TEST_STEP 	300 	T_MsgImapServer 	CreateImapAccount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0013-CreateImapAccount 
RUN_TEST_STEP 	100 	T_MsgImapServer		ChangeImap4SubAndSyncSettings	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0013-ChangeSubAndSyncSettings
RUN_TEST_STEP 	100 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0013-ConnectImap4Server
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0013-DoFullImap4Synchronisation
RUN_TEST_STEP 	100 	T_MsgImapServer		InitialiseImap4Account		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0013-InitialiseImap4Account
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0013-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer 	DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0013-DisConnectImap4Server
PRINT Setup Completed
PRINT Execute begins
RUN_TEST_STEP 	300 	T_MsgSmtpServer		CreateSmtpMessageFromEmailFile 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0013-CreateSmtpMessageFromEmailFile
RUN_TEST_STEP 	300 	T_MsgCommonServer	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0013-CheckChildrenCountOutbox
RUN_TEST_STEP 	300 	T_MsgSmtpServer		SendSmtpMessage 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0013-SendSmtpMessage
RUN_TEST_STEP 	300 	T_MsgCommonServer	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0013-CheckChildrenCountSentItems
RUN_TEST_STEP 	300 	T_MsgImapServer 	SetImap4FullDownloadLimits 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0013-SetImap4FullDownloadLimits
RUN_TEST_STEP 	300 	T_MsgImapServer 	ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0013-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer 	DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0013-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer 	DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0013-DisConnectImap4Server
//Offline Populate
RUN_TEST_STEP 	300 	T_MsgImapServer 	ImapInvokeAsyncFunction      	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0013-ImapInvokeAsyncFunction
RUN_TEST_STEP 	300 	T_MsgImapServer 	ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0013-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer 	DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0013-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer 	CompareEmailMessages		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0013-CompareEmailMessages
RUN_TEST_STEP 	300 	T_MsgImapServer 	CopyImapSelection		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0013-CopyImapSelection
RUN_TEST_STEP 	300 	T_MsgCommonServer	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0013-CheckChildrenCountInbox
RUN_TEST_STEP 	300 	T_MsgImapServer 	DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0013-DisConnectImap4Server

RUN_TEST_STEP	300	T_MsgCommonServer	ShutDown
RUN_TEST_STEP	300	T_MsgImapServer		ShutDown
RUN_TEST_STEP	300	T_MsgSmtpServer		ShutDown

PRINT Execute Completed ################################################
END_TESTCASE	MSG_IMAP_Offline_Populate-0025


START_TESTCASE	MSG-IMAP-Offline-Populate-0026
//!	@SYMTestCaseID			MSG-IMAP-Offline-Populate-0026
//!	@SYMTestCaseDesc		Verification:
//!		This test tests offline Operation with download limit set as given below
//!	@SYMTestPriority		Critical
//!   	@SYMTestType			CIT
//!  	@SYMTestStatus			Implemented   
//!	@SYMTestCaseDependencies	requires ced -i c:\ced_default_ras.cfg to set comms.
//!	@SYMTestActions			Initialises the RAS connection
//!					Resets the message store to clean up the central repository
//!					Creates an IMAP account by reading the settings from the file mentioned
//!					thus setting the IMAP and SMTP service settings
//!					Connects to the IMAP server and performs full sync with IMAP4 server.
//!					Connects to the IMAP server and deletes all mails in the Inbox on the server.
//!					Creates a message from RFC822 file and send the message to the same IMAP account.
//!					Set the partial download limits.
//!					Download the mails with IMAP4 KIMAP4MTMPopulate command and 
//!					compares the received messages with sent messages based on the Download limits set.
//!					Copies the mails from IMAP4 Inbox folder to Local inbox folder.
//!					Download Limit:
//!						MaxEmailSize = Default
//!						BodyTextSizeLimit = Default
//!						AttachmentSizeLimit = Default
//!						ImapPartialMailOption = TImImap4PartialMailOptions::EBodyAlternativeText
//!	@SYMTestExpectedResults		EPass, The message is sent ,received and also present in the local inbox folder.
//!					Body text and HTML part should be completely downloaded and If attachment size 
//!					is fit within the iAttachmentSizeLimit, attachment should be downloaded. 
//!					No Footer string should appear. 
//!	@SYMAuthor			Mrudul V. Pendharkar
//!	@SYMREQ				5578
//!	@SYMPREQ			1160

PRINT Setup Begins #####################################################

RUN_TEST_STEP	300	T_MsgCommonServer  	StartUp
RUN_TEST_STEP	300	T_MsgImapServer	StartUp
RUN_TEST_STEP	300	T_MsgSmtpServer	StartUp

RUN_TEST_STEP	300	T_MsgCommonServer	InitNtRas			c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0014-InitNtRas
RUN_TEST_STEP	300	T_MsgCommonServer	ResetMessageStore		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0014-ResetMessageStore
RUN_TEST_STEP 	300 	T_MsgImapServer		CreateImapAccount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0014-CreateImapAccount 
RUN_TEST_STEP 	100 	T_MsgImapServer		ChangeImap4SubAndSyncSettings	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0014-ChangeSubAndSyncSettings
RUN_TEST_STEP 	100 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0014-ConnectImap4Server
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0014-DoFullImap4Synchronisation
RUN_TEST_STEP 	100 	T_MsgImapServer		InitialiseImap4Account		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0014-InitialiseImap4Account
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0014-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0014-DisConnectImap4Server
PRINT Setup Completed
PRINT Execute begins
RUN_TEST_STEP 	300 	T_MsgSmtpServer		CreateSmtpMessageFromEmailFile 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0014-CreateSmtpMessageFromEmailFile
RUN_TEST_STEP 	300 	T_MsgCommonServer	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0014-CheckChildrenCountOutbox
RUN_TEST_STEP 	300 	T_MsgSmtpServer		SendSmtpMessage 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0014-SendSmtpMessage
RUN_TEST_STEP 	300 	T_MsgCommonServer	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0014-CheckChildrenCountSentItems
RUN_TEST_STEP 	300 	T_MsgImapServer		SetImap4PartialDownloadLimits 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0014-SetImap4PartialDownloadLimits
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0014-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0014-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0014-DisConnectImap4Server
//Offline Populate
RUN_TEST_STEP 	300 	T_MsgImapServer		ImapInvokeAsyncFunction      	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0014-ImapInvokeAsyncFunction
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0014-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0014-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer 	CompareEmailMessages		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0014-CompareEmailMessages
RUN_TEST_STEP 	300 	T_MsgImapServer		CopyImapSelection		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0014-CopyImapSelection
RUN_TEST_STEP 	300 	T_MsgCommonServer	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0014-CheckChildrenCountInbox
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0014-DisConnectImap4Server

RUN_TEST_STEP	300	T_MsgCommonServer	ShutDown
RUN_TEST_STEP	300	T_MsgImapServer		ShutDown
RUN_TEST_STEP	300	T_MsgSmtpServer		ShutDown

PRINT Execute Completed ################################################
END_TESTCASE	MSG-IMAP-Offline-Populate-0026


START_TESTCASE	MSG_IMAP_Offline_Populate-0027
//!	@SYMTestCaseID			MSG-IMAP-Offline-Populate-0027
//!	@SYMTestCaseDesc		Verification:
//!		This test tests if Offline Populate downloads the message. It also compares the received messages with sent 
//!		messages based on the Download limits set. This tests Populate Command for Partial Mail Option set as
//!		EBodyAlternativeText
//!	@SYMTestPriority		Critical
//!   	@SYMTestType			CIT
//!  	@SYMTestStatus			Implemented   
//!	@SYMTestCaseDependencies	requires ced -i c:\ced_default_ras.cfg to set comms.
//!	@SYMTestActions			
//!		The Local Inbox and Sent Item folders and the remote Inbox folder of IMAP4 
//!		account are cleaned up before starting the test.
//! 	------------------------------------------
//!		1.  Create emails from RFC822 file and send emails to the same account
//!		2.  Set the download limits
//!		3.  Download the mails with IMAP4 KIMAP4MTMPopulate command and Partial download limits set
//!		4.  Compare the populated messages with sent messages based on the Download limits set
//! 		Implementation and execution:
//!			The emails are sent to the sender's address only.
//!			New messages are created, sent and received.  The received messages are compared with 
//!     		the sent messages, based on the download limits set, for size and contents.
//!		Download limits set: Parital Download limits is set
//!			MaxEmailSize = Default (KMaxInt)
//!			BodyTextSizeLimit = Default (KMaxInt)
//!			AttachmentSizeLimit = 6000
//!			ImapPartialMailOption = TImImap4PartialMailOptions::EBodyAlternativeText
//!			Destination Folder : Remote Inbox folder
//!	@SYMTestExpectedResults		EPass, The message is sent and received and also present in the local inbox folder.
//!					Gets the body text less than total size limit and all non-HTML text attachments 
//!					whose size is within total size limit minus fetched body parts.
//!	@SYMAuthor			Mrudul V. Pendharkar
//!	@SYMREQ				5578
//!	@SYMPREQ			1160

PRINT Setup Begins #####################################################

RUN_TEST_STEP	300	T_MsgCommonServer  	StartUp
RUN_TEST_STEP	300	T_MsgImapServer	StartUp
RUN_TEST_STEP	300	T_MsgSmtpServer	StartUp

RUN_TEST_STEP	300	T_MsgCommonServer 	InitNtRas			c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0015-InitNtRas
RUN_TEST_STEP	300	T_MsgCommonServer 	ResetMessageStore		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0015-ResetMessageStore
RUN_TEST_STEP 	300 	T_MsgImapServer		CreateImapAccount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0015-CreateImapAccount 
RUN_TEST_STEP 	100 	T_MsgImapServer		ChangeImap4SubAndSyncSettings	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0015-ChangeSubAndSyncSettings
RUN_TEST_STEP 	100 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0015-ConnectImap4Server
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0015-DoFullImap4Synchronisation
RUN_TEST_STEP 	100 	T_MsgImapServer		InitialiseImap4Account		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0015-InitialiseImap4Account
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0015-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0015-DisConnectImap4Server
PRINT Setup Completed
PRINT Execute begins
RUN_TEST_STEP 	300 	T_MsgSmtpServer 	CreateSmtpMessageFromEmailFile 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0015-CreateSmtpMessageFromEmailFile
RUN_TEST_STEP 	300 	T_MsgCommonServer 	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0015-CheckChildrenCountOutbox
RUN_TEST_STEP 	300 	T_MsgSmtpServer 	SendSmtpMessage 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0015-SendSmtpMessage
RUN_TEST_STEP 	300 	T_MsgCommonServer 	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0015-CheckChildrenCountSentItems
RUN_TEST_STEP 	300 	T_MsgImapServer		SetImap4PartialDownloadLimits 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0015-SetImap4PartialDownloadLimits
//Connection to get Headers
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0015-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0015-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0015-DisConnectImap4Server
//Offline Populate Command
RUN_TEST_STEP 	300 	T_MsgImapServer		ImapInvokeAsyncFunction      	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0015-ImapInvokeAsyncFunction
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0015-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0015-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer 	CompareEmailMessages		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      		0015-CompareEmailMessages
RUN_TEST_STEP 	300 	T_MsgImapServer		CopyImapSelection		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0015-CopyImapSelection
RUN_TEST_STEP 	300 	T_MsgCommonServer 	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0015-CheckChildrenCountInbox
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0015-DisConnectImap4Server

RUN_TEST_STEP	300	T_MsgCommonServer	ShutDown
RUN_TEST_STEP	300	T_MsgImapServer		ShutDown
RUN_TEST_STEP	300	T_MsgSmtpServer		ShutDown

PRINT Execute Completed ################################################
END_TESTCASE	MSG_IMAP_Offline_Populate-0027


START_TESTCASE	MSG_IMAP_Offline_Populate-0028
//!	@SYMTestCaseID			MSG-IMAP-Offline-Populate-0028
//!	@SYMTestCaseDesc		Verification:
//!		This test tests if Offline Populate downloads the message. It also compares the received messages with sent 
//!		messages based on the Download limits set.
//!	@SYMTestPriority		Critical
//!   	@SYMTestType			CIT
//!  	@SYMTestStatus			Implemented   
//!	@SYMTestCaseDependencies	requires ced -i c:\ced_default_ras.cfg to set comms.
//!	@SYMTestActions			
//!		The Local Inbox and Sent Item folders and the remote Inbox folder of IMAP4 
//!		account are cleaned up before starting the test.
//! 	------------------------------------------
//!		1.  Create emails from RFC822 file and send emails to the same account
//!		2.  Set the download limits
//!		3.  Download the mails with IMAP4 KIMAP4MTMPopulate command and Partial download limits set
//!		4.  Compare the populated messages with sent messages based on the Download limits set
//! 		Implementation and execution:
//!			The emails are sent to the sender's address only.
//!			New messages are created, sent and received.  The received messages are compared with 
//!     		the sent messages, based on the download limits set, for size and contents.
//!		Download limits set: Parital Download limits is set
//!			MaxEmailSize = Default (KMaxInt)
//!			BodyTextSizeLimit = Default (KMaxInt)
//!			AttachmentSizeLimit = Default (KMaxInt)
//!			ImapPartialMailOption = TImImap4PartialMailOptions::EBodyAlternativeText
//!			Destination Folder : Remote Inbox folder
//!	@SYMTestExpectedResults		EPass, The message is sent and received and also present in the local inbox folder.
//!					All parts of the mail is downloaded
//!	@SYMAuthor			Mrudul V. Pendharkar
//!	@SYMREQ				5578
//!	@SYMPREQ			1160

PRINT Setup Begins #####################################################

RUN_TEST_STEP	300	T_MsgCommonServer  	StartUp
RUN_TEST_STEP	300	T_MsgImapServer	StartUp
RUN_TEST_STEP	300	T_MsgSmtpServer	StartUp

RUN_TEST_STEP	300	T_MsgCommonServer 	InitNtRas			c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0016-InitNtRas
RUN_TEST_STEP	300	T_MsgCommonServer 	ResetMessageStore		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0016-ResetMessageStore
RUN_TEST_STEP 	300 	T_MsgImapServer		CreateImapAccount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0016-CreateImapAccount 
RUN_TEST_STEP 	100 	T_MsgImapServer		ChangeImap4SubAndSyncSettings	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0016-ChangeSubAndSyncSettings
RUN_TEST_STEP 	100 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0016-ConnectImap4Server
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0016-DoFullImap4Synchronisation
RUN_TEST_STEP 	100 	T_MsgImapServer		InitialiseImap4Account		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0016-InitialiseImap4Account
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0016-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0016-DisConnectImap4Server
PRINT Setup Completed
PRINT Execute begins
RUN_TEST_STEP 	300 	T_MsgSmtpServer 	CreateSmtpMessageFromEmailFile 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0016-CreateSmtpMessageFromEmailFile
RUN_TEST_STEP 	300 	T_MsgCommonServer 	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0016-CheckChildrenCountOutbox
RUN_TEST_STEP 	300 	T_MsgSmtpServer 	SendSmtpMessage 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0016-SendSmtpMessage
RUN_TEST_STEP 	300 	T_MsgCommonServer 	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0016-CheckChildrenCountSentItems
RUN_TEST_STEP 	300 	T_MsgImapServer		SetImap4PartialDownloadLimits 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0016-SetImap4PartialDownloadLimits
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0016-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0016-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0016-DisConnectImap4Server
//Offline Populate
RUN_TEST_STEP 	300 	T_MsgImapServer		ImapInvokeAsyncFunction      	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0016-ImapInvokeAsyncFunction
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0016-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0016-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer 	CompareEmailMessages		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0016-CompareEmailMessages
RUN_TEST_STEP 	300 	T_MsgImapServer		CopyImapSelection		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0016-CopyImapSelection
RUN_TEST_STEP 	300 	T_MsgCommonServer 	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0016-CheckChildrenCountInbox
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0016-DisConnectImap4Server

RUN_TEST_STEP	300	T_MsgCommonServer	ShutDown
RUN_TEST_STEP	300	T_MsgImapServer		ShutDown
RUN_TEST_STEP	300	T_MsgSmtpServer		ShutDown

PRINT Execute Completed ################################################
END_TESTCASE	MSG_IMAP_Offline_Populate-0028


START_TESTCASE	MSG_IMAP_Offline_Populate-0029
//!	@SYMTestCaseID			MSG-IMAP-Offline-Populate-0029
//!	@SYMTestCaseDesc		Verification:
//!		This test tests if Offline Populate downloads the message. It also compares the received messages with sent 
//!		messages based on the Download limits set.
//!	@SYMTestPriority		Critical
//!   	@SYMTestType			CIT
//!  	@SYMTestStatus			Implemented   
//!	@SYMTestCaseDependencies	requires ced -i c:\ced_default_ras.cfg to set comms.
//!	@SYMTestActions			
//!		The Local Inbox and Sent Item folders and the remote Inbox folder of IMAP4 
//!		account are cleaned up before starting the test.
//! 	------------------------------------------
//!		1.  Create emails from RFC822 file and send emails to the same account
//!		2.  Set the download limits
//!		3.  Download the mails with IMAP4 KIMAP4MTMPopulate command and Partial download limits set
//!		4.  Compare the populated messages with sent messages based on the Download limits set
//! 		Implementation and execution:
//!			The emails are sent to the sender's address only.
//!			New messages are created, sent and received.  The received messages are compared with 
//!     		the sent messages, based on the download limits set, for size and contents.
//!		Download limits set: Parital Download limits is set
//!			MaxEmailSize = Default (KMaxInt)
//!			BodyTextSizeLimit = Default (KMaxInt)
//!			AttachmentSizeLimit = 1000
//!			ImapPartialMailOption = TImImap4PartialMailOptions::EBodyAlternativeText
//!			Destination Folder : Remote Inbox folder
//!	@SYMTestExpectedResults		EPass, The message is sent and received and also present in the local inbox folder.
//!					All parts of the mail is downloaded
//!	@SYMAuthor			Mrudul V. Pendharkar
//!	@SYMREQ				5578
//!	@SYMPREQ			1160


PRINT Setup Begins #####################################################

RUN_TEST_STEP	300	T_MsgCommonServer  	StartUp
RUN_TEST_STEP	300	T_MsgImapServer	StartUp
RUN_TEST_STEP	300	T_MsgSmtpServer	StartUp

RUN_TEST_STEP	300	T_MsgCommonServer	InitNtRas			c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0017-InitNtRas
RUN_TEST_STEP	300	T_MsgCommonServer	ResetMessageStore		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0017-ResetMessageStore
RUN_TEST_STEP 	300 	T_MsgImapServer		CreateImapAccount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0017-CreateImapAccount 
RUN_TEST_STEP 	100 	T_MsgImapServer		ChangeImap4SubAndSyncSettings	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0017-ChangeSubAndSyncSettings
RUN_TEST_STEP 	100 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0017-ConnectImap4Server
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0017-DoFullImap4Synchronisation
RUN_TEST_STEP 	100 	T_MsgImapServer		InitialiseImap4Account		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0017-InitialiseImap4Account
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0017-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0017-DisConnectImap4Server
PRINT Setup Completed
PRINT Execute begins
RUN_TEST_STEP 	300 	T_MsgSmtpServer 	CreateSmtpMessageFromEmailFile 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0017-CreateSmtpMessageFromEmailFile
RUN_TEST_STEP 	300 	T_MsgCommonServer	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0017-CheckChildrenCountOutbox
RUN_TEST_STEP 	300 	T_MsgSmtpServer 	SendSmtpMessage 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0017-SendSmtpMessage
RUN_TEST_STEP 	300 	T_MsgCommonServer	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0017-CheckChildrenCountSentItems
RUN_TEST_STEP 	300 	T_MsgImapServer		SetImap4PartialDownloadLimits 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0017-SetImap4PartialDownloadLimits
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0017-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0017-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0017-DisConnectImap4Server
//Offline Populate Command
RUN_TEST_STEP 	300 	T_MsgImapServer		ImapInvokeAsyncFunction      	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0017-ImapInvokeAsyncFunction
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0017-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0017-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer 	CompareEmailMessages		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0017-CompareEmailMessages
RUN_TEST_STEP 	300 	T_MsgImapServer		CopyImapSelection		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0017-CopyImapSelection
RUN_TEST_STEP 	300 	T_MsgCommonServer	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0017-CheckChildrenCountInbox
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0017-DisConnectImap4Server

RUN_TEST_STEP	300	T_MsgCommonServer	ShutDown
RUN_TEST_STEP	300	T_MsgImapServer		ShutDown
RUN_TEST_STEP	300	T_MsgSmtpServer		ShutDown

PRINT Execute Completed ################################################
END_TESTCASE	MSG_IMAP_Offline_Populate-0029


START_TESTCASE	MSG_IMAP_Offline_Populate-0030
//!	@SYMTestCaseID			MSG-IMAP-Offline-Populate-0030
//!	@SYMTestCaseDesc		Verification:
//!		This test tests if Offline Populate downloads the message. It also compares the received messages with sent 
//!		messages based on the Download limits set.It tests Populate Command for FullDownload Option set as EGetImap4EmailBodyAlternativeText
//!	@SYMTestPriority		Critical
//!   	@SYMTestType			CIT
//!  	@SYMTestStatus			Implemented   
//!	@SYMTestCaseDependencies	requires ced -i c:\ced_default_ras.cfg to set comms.
//!	@SYMTestActions			
//!		The Local Inbox and Sent Item folders and the remote Inbox folder of IMAP4 
//!		account are cleaned up before starting the test.
//! 	------------------------------------------
//!		1.  Create emails from RFC822 file and send emails to the same account
//!		2.  Set the download limits
//!		3.  Download the mails with IMAP4 KIMAP4MTMPopulate command and Partial download limits set
//!		4.  Compare the populated messages with sent messages based on the Download limits set
//! 		Implementation and execution:
//!			The emails are sent to the sender's address only.
//!			New messages are created, sent and received.  The received messages are compared with 
//!     		the sent messages, based on the download limits set, for size and contents.
//!		Download limits set: Parital Download limits is set
//!			MaxEmailSize = 30000
//!			BodyTextSizeLimit = Default (KMaxInt)
//!			AttachmentSizeLimit = Default (KMaxInt)
//!			ImapPartialMailOption = TImap4GetMailOptions::EGetImap4EmailBodyAlternativeText
//!			Destination Folder : Remote Inbox folder
//!	@SYMTestExpectedResults		EPass, The message is sent and received and also present in the local inbox folder.
//!					All parts of the email should be downloaded
//!	@SYMAuthor			Mrudul V. Pendharkar
//!	@SYMREQ				5578
//!	@SYMPREQ			1160

PRINT Setup Begins #####################################################

RUN_TEST_STEP	300	T_MsgCommonServer  	StartUp
RUN_TEST_STEP	300	T_MsgImapServer	StartUp
RUN_TEST_STEP	300	T_MsgSmtpServer	StartUp

RUN_TEST_STEP	300	T_MsgCommonServer	InitNtRas			c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0018-InitNtRas
RUN_TEST_STEP	300	T_MsgCommonServer	ResetMessageStore		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0018-ResetMessageStore
RUN_TEST_STEP 	300 	T_MsgImapServer 	CreateImapAccount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0018-CreateImapAccount 
RUN_TEST_STEP 	100 	T_MsgImapServer		ChangeImap4SubAndSyncSettings	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0018-ChangeSubAndSyncSettings
RUN_TEST_STEP 	100 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0018-ConnectImap4Server
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0018-DoFullImap4Synchronisation
RUN_TEST_STEP 	100 	T_MsgImapServer		InitialiseImap4Account		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0018-InitialiseImap4Account
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0018-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer 	DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0018-DisConnectImap4Server
PRINT Setup Completed
PRINT Execute begins
RUN_TEST_STEP 	300 	T_MsgSmtpServer		CreateSmtpMessageFromEmailFile 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0018-CreateSmtpMessageFromEmailFile
RUN_TEST_STEP 	300 	T_MsgCommonServer	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0018-CheckChildrenCountOutbox
RUN_TEST_STEP 	300 	T_MsgSmtpServer		SendSmtpMessage 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0018-SendSmtpMessage
RUN_TEST_STEP 	300 	T_MsgCommonServer	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0018-CheckChildrenCountSentItems
RUN_TEST_STEP 	300 	T_MsgImapServer 	SetImap4FullDownloadLimits 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0018-SetImap4FullDownloadLimits
RUN_TEST_STEP 	300 	T_MsgImapServer 	ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0018-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer 	DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0018-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer 	DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0018-DisConnectImap4Server
//Offline Populate Command
RUN_TEST_STEP 	300 	T_MsgImapServer 	ImapInvokeAsyncFunction      	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0018-ImapInvokeAsyncFunction
RUN_TEST_STEP 	300 	T_MsgImapServer 	ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0018-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer 	DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0018-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer 	CompareEmailMessages		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0018-CompareEmailMessages
RUN_TEST_STEP 	300 	T_MsgImapServer 	CopyImapSelection		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0018-CopyImapSelection
RUN_TEST_STEP 	300 	T_MsgCommonServer	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0018-CheckChildrenCountInbox
RUN_TEST_STEP 	300 	T_MsgImapServer 	DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0018-DisConnectImap4Server

RUN_TEST_STEP	300	T_MsgCommonServer	ShutDown
RUN_TEST_STEP	300	T_MsgImapServer		ShutDown
RUN_TEST_STEP	300	T_MsgSmtpServer		ShutDown

PRINT Execute Completed ################################################
END_TESTCASE	MSG_IMAP_Offline_Populate-0030


START_TESTCASE	MSG_IMAP_Offline_Populate-0031
//!	@SYMTestCaseID			MSG-IMAP-Offline-Populate-0031
//!	@SYMTestCaseDesc		Verification:
//!		This test tests if Offline Populate downloads the message. It also compares the received messages with sent 
//!		messages based on the Download limits set.
//!	@SYMTestPriority		Critical
//!   	@SYMTestType			CIT
//!  	@SYMTestStatus			Implemented   
//!	@SYMTestCaseDependencies	requires ced -i c:\ced_default_ras.cfg to set comms.
//!	@SYMTestActions			
//!		The Local Inbox and Sent Item folders and the remote Inbox folder of IMAP4 
//!		account are cleaned up before starting the test.
//! 	------------------------------------------
//!		1.  Create emails from RFC822 file and send emails to the same account
//!		2.  Set the download limits
//!		3.  Download the mails with IMAP4 KIMAP4MTMPopulate command and Partial download limits set
//!		4.  Compare the populated messages with sent messages based on the Download limits set
//! 		Implementation and execution:
//!			The emails are sent to the sender's address only.
//!			New messages are created, sent and received.  The received messages are compared with 
//!     		the sent messages, based on the download limits set, for size and contents.
//!		Download limits set: Parital Download limits is set
//!			MaxEmailSize = 30000
//!			BodyTextSizeLimit = Default (KMaxInt)
//!			AttachmentSizeLimit = Default (KMaxInt)
//!			ImapPartialMailOption = TImap4GetMailOptions::EGetImap4EmailBodyAlternativeText
//!			Destination Folder : Remote Inbox folder
//!					Download Limit:
//!						MaxEmailSize = 30000
//!						ImapMailOption = TImap4GetMailOptions::EGetImap4EmailBodyAlternativeText
//!	@SYMTestExpectedResults		EPass, The message is sent and received and also present in the local inbox folder.
//!					All parts of the email should be downloaded
//!	@SYMAuthor			Mrudul V. Pendharkar
//!	@SYMREQ				5578
//!	@SYMPREQ			1160

PRINT Setup Begins #####################################################

RUN_TEST_STEP	300	T_MsgCommonServer  	StartUp
RUN_TEST_STEP	300	T_MsgImapServer	StartUp
RUN_TEST_STEP	300	T_MsgSmtpServer	StartUp

RUN_TEST_STEP	300	T_MsgCommonServer 	InitNtRas			c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0019-InitNtRas
RUN_TEST_STEP	300	T_MsgCommonServer 	ResetMessageStore		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0019-ResetMessageStore
RUN_TEST_STEP 	300 	T_MsgImapServer		CreateImapAccount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0019-CreateImapAccount 
RUN_TEST_STEP 	100 	T_MsgImapServer		ChangeImap4SubAndSyncSettings	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0019-ChangeSubAndSyncSettings
RUN_TEST_STEP 	100 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0019-ConnectImap4Server
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0019-DoFullImap4Synchronisation
RUN_TEST_STEP 	100 	T_MsgImapServer		InitialiseImap4Account		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0019-InitialiseImap4Account
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0019-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0019-DisConnectImap4Server
PRINT Setup Completed
PRINT Execute begins
RUN_TEST_STEP 	300 	T_MsgSmtpServer		CreateSmtpMessageFromEmailFile 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0019-CreateSmtpMessageFromEmailFile
RUN_TEST_STEP 	300 	T_MsgCommonServer 	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0019-CheckChildrenCountOutbox
RUN_TEST_STEP 	300 	T_MsgSmtpServer		SendSmtpMessage 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0019-SendSmtpMessage
RUN_TEST_STEP 	300 	T_MsgCommonServer 	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0019-CheckChildrenCountSentItems
RUN_TEST_STEP 	300 	T_MsgImapServer		SetImap4FullDownloadLimits 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0019-SetImap4FullDownloadLimits
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0019-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0019-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0019-DisConnectImap4Server
//Offline Populate
RUN_TEST_STEP 	300 	T_MsgImapServer		ImapInvokeAsyncFunction      	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0019-ImapInvokeAsyncFunction
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0019-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0019-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer 	CompareEmailMessages		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0019-CompareEmailMessages
RUN_TEST_STEP 	300 	T_MsgImapServer		CopyImapSelection		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0019-CopyImapSelection
RUN_TEST_STEP 	300 	T_MsgCommonServer 	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0019-CheckChildrenCountInbox
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0019-DisConnectImap4Server

RUN_TEST_STEP	300	T_MsgCommonServer	ShutDown
RUN_TEST_STEP	300	T_MsgImapServer		ShutDown
RUN_TEST_STEP	300	T_MsgSmtpServer		ShutDown

PRINT Execute Completed ################################################
END_TESTCASE	MSG_IMAP_Offline_Populate-0031


START_TESTCASE	MSG_IMAP_Offline_Populate-0032
//!	@SYMTestCaseID			MSG-IMAP-Offline-Populate-0032
//!	@SYMTestCaseDesc		Verification:
//!		This test tests if Offline Populate downloads the message. It also compares the received messages with sent 
//!		messages based on the Download limits set.
//!	@SYMTestPriority		Critical
//!   	@SYMTestType			CIT
//!  	@SYMTestStatus			Implemented   
//!	@SYMTestCaseDependencies	requires ced -i c:\ced_default_ras.cfg to set comms.
//!	@SYMTestActions			
//!		The Local Inbox and Sent Item folders and the remote Inbox folder of IMAP4 
//!		account are cleaned up before starting the test.
//! 	------------------------------------------
//!		1.  Create emails from RFC822 file and send emails to the same account
//!		2.  Set the download limits
//!		3.  Download the mails with IMAP4 KIMAP4MTMPopulate command and Partial download limits set
//!		4.  Compare the populated messages with sent messages based on the Download limits set
//! 		Implementation and execution:
//!			The emails are sent to the sender's address only.
//!			New messages are created, sent and received.  The received messages are compared with 
//!     		the sent messages, based on the download limits set, for size and contents.
//!		Download limits set: Parital Download limits is set
//!			MaxEmailSize = 3000
//!			BodyTextSizeLimit = Default (KMaxInt)
//!			AttachmentSizeLimit = Default (KMaxInt)
//!			ImapPartialMailOption = TImImap4PartialMailOptions::EGetImap4EmailBodyAlternativeText
//!			Destination Folder : Remote Inbox folder
//!	@SYMTestExpectedResults		EPass, The message is sent and received and also present in the local inbox folder.
//!					All parts of the email except the attachment should be downloaded.
//!	@SYMAuthor			Mrudul V. Pendharkar
//!	@SYMREQ				5578
//!	@SYMPREQ			1160

PRINT Setup Begins #####################################################

RUN_TEST_STEP	300	T_MsgCommonServer  	StartUp
RUN_TEST_STEP	300	T_MsgImapServer	StartUp
RUN_TEST_STEP	300	T_MsgSmtpServer	StartUp

RUN_TEST_STEP	300	T_MsgCommonServer 	InitNtRas			c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0020-InitNtRas
RUN_TEST_STEP	300	T_MsgCommonServer 	ResetMessageStore		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0020-ResetMessageStore
RUN_TEST_STEP 	300 	T_MsgImapServer		CreateImapAccount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0020-CreateImapAccount 
RUN_TEST_STEP 	100 	T_MsgImapServer		ChangeImap4SubAndSyncSettings	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0020-ChangeSubAndSyncSettings
RUN_TEST_STEP 	100 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0020-ConnectImap4Server
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0020-DoFullImap4Synchronisation
RUN_TEST_STEP 	100 	T_MsgImapServer		InitialiseImap4Account		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0020-InitialiseImap4Account
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0020-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0020-DisConnectImap4Server
PRINT Setup Completed
PRINT Execute begins
RUN_TEST_STEP 	300 	T_MsgSmtpServer 	CreateSmtpMessageFromEmailFile 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0020-CreateSmtpMessageFromEmailFile
RUN_TEST_STEP 	300 	T_MsgCommonServer 	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0020-CheckChildrenCountOutbox
RUN_TEST_STEP 	300 	T_MsgSmtpServer 	SendSmtpMessage 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0020-SendSmtpMessage
RUN_TEST_STEP 	300 	T_MsgCommonServer 	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0020-CheckChildrenCountSentItems
RUN_TEST_STEP 	300 	T_MsgImapServer		SetImap4FullDownloadLimits 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0020-SetImap4FullDownloadLimits
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0020-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0020-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0020-DisConnectImap4Server
//Offline Populate
RUN_TEST_STEP 	300 	T_MsgImapServer		ImapInvokeAsyncFunction      	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0020-ImapInvokeAsyncFunction
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0020-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0020-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer 	CompareEmailMessages		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0020-CompareEmailMessages
RUN_TEST_STEP 	300 	T_MsgImapServer		CopyImapSelection		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0020-CopyImapSelection
RUN_TEST_STEP 	300 	T_MsgCommonServer 	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini      	0020-CheckChildrenCountInbox
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     	0020-DisConnectImap4Server

RUN_TEST_STEP	300	T_MsgCommonServer	ShutDown
RUN_TEST_STEP	300	T_MsgImapServer		ShutDown
RUN_TEST_STEP	300	T_MsgSmtpServer		ShutDown

PRINT Execute Completed ################################################
END_TESTCASE	MSG_IMAP_Offline_Populate-0032


START_TESTCASE	MSG-IMAP-OFFLINE-UNDELETEALL-0001
//!	@SYMTestCaseID			MSG-IMAP-OFFLINE-UNDELETEALL-0001
//!	@SYMTestCaseDesc		Verification:
//!					This Test Deletes Single Message & UndeletesAll & checks if the delete operation is reverted
//!	@SYMTestPriority		High
//!   	@SYMTestType			CIT
//!  	@SYMTestStatus			Implemented   
//!	@SYMTestCaseDependencies	requires ced -i c:\ced_default_ras.cfg to set comms.
//!	@SYMTestActions			Initialise the RAS connection
//!					Reset the message store to clean up the central repository
//!					Create an IMAP account
//!					Connect to the IMAP server 
//!					Perform full sync with IMAP4 server.
//!					Initialises Imap Account
//!					Disconnect
//!					Create messages from RFC822 file and sends the messages to the same IMAP account.
//!					Set the full download limits.
//!					Download Limits:
//!					MaxEmailSize = Default (KMaxInt)
//!					ImapMailOption = TImap4GetMailOptions::EGetImap4EmailBodyTextAndAttachments
//!					Connect
//!					Download the mails
//!					Check the Children Count on Imap remote Folder
//!					Disconnect
//!					Delete Message from specified Folder
//!					UnDeleteAll
//!					Connect to the Imap Server
//!					Do full Synchronisation
//!					Check the message is not deleted.
//!	@SYMTestExpectedResults		EPass,The message is not deleted from the specified(Inbox) folder.
//!	@SYMAuthor			Mrudul Pendharkar
//!	@SYMREQ				5585
//!	@SYMPREQ			1160


PRINT Setup Begins #####################################################

RUN_TEST_STEP	300	T_MsgCommonServer  	StartUp
RUN_TEST_STEP	300	T_MsgImapServer	StartUp
RUN_TEST_STEP	300	T_MsgSmtpServer	StartUp

RUN_TEST_STEP	300	T_MsgCommonServer  	InitNtRas			c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0021-InitNtRas
RUN_TEST_STEP	300	T_MsgCommonServer  	ResetMessageStore		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0021-ResetMessageStore
RUN_TEST_STEP 	300 	T_MsgImapServer		CreateImapAccount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0021-CreateImapAccount 
RUN_TEST_STEP 	100 	T_MsgImapServer		ChangeImap4SubAndSyncSettings	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0021-ChangeSubAndSyncSettings
RUN_TEST_STEP 	100 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0021-ConnectImap4Server
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0021-DoFullImap4Synchronisation
RUN_TEST_STEP 	100 	T_MsgImapServer		InitialiseImap4Account		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0021-InitialiseImap4Account
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0021-DoFullImap4Synchronisation
RUN_TEST_STEP  	300 	T_MsgImapServer		CheckChildrenCountImap 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0021-CheckChildrenCountRemoteInbox0
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0021-DisConnectImap4Server
PRINT Setup Completed
PRINT Execute begins
RUN_TEST_STEP 	300 	T_MsgSmtpServer		CreateSmtpMessageFromEmailFile 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0021-CreateSmtpMessageFromEmailFile
RUN_TEST_STEP 	300 	T_MsgCommonServer  	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0021-CheckChildrenCountOutbox1
RUN_TEST_STEP 	300 	T_MsgSmtpServer		SendSmtpMessage 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0021-SendSmtpMessage
RUN_TEST_STEP 	300 	T_MsgImapServer		SetImap4FullDownloadLimits 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0021-SetImap4FullDownloadLimits
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0021-ConnectImap4Server
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0021-DoFullImap4Synchronisation
RUN_TEST_STEP	300	T_MsgImapServer		ImapInvokeAsyncFunction		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0021-ImapInvokeAsyncFunction
RUN_TEST_STEP  	300 	T_MsgImapServer		CheckChildrenCountImap 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0021-CheckChildrenCountRemoteInbox1
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0021-DisConnectImap4Server
//Delete Offline
RUN_TEST_STEP 	300 	T_MsgImapServer		DeleteMessage			c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0021-DeleteMessage
//Undelete to revert the delete operation
RUN_TEST_STEP 	300 	T_MsgImapServer		UnDeleteAll			c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0021-UnDeleteAll
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0021-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0021-DoFullImap4Synchronisation
//Verify the delete operation is reverted
RUN_TEST_STEP  	300 	T_MsgImapServer		CheckChildrenCountImap 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0021-CheckChildrenCountRemoteInbox1
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0021-DisConnectImap4Server

RUN_TEST_STEP	300	T_MsgCommonServer	ShutDown
RUN_TEST_STEP	300	T_MsgImapServer		ShutDown
RUN_TEST_STEP	300	T_MsgSmtpServer		ShutDown

PRINT Execute Completed ################################################
END_TESTCASE	MSG-IMAP-OFFLINE-UNDELETEALL-0001


START_TESTCASE	MSG-IMAP-OFFLINE-UNDELETEALL-0002
//!	@SYMTestCaseID			MSG-IMAP-OFFLINE-UNDELETEALL-0002
//!	@SYMTestCaseDesc		Verification:
//!					This Test Deletes Multiple Messages, Sends UndeleteAll command & checks if the messages and undeleted
//!	@SYMTestPriority		High
//!   	@SYMTestType			CIT
//!  	@SYMTestStatus			Implemented   
//!	@SYMTestCaseDependencies	requires ced -i c:\ced_default_ras.cfg to set comms.
//!	@SYMTestActions			Initialise the RAS connection
//!					Reset the message store to clean up the central repository
//!					Create an IMAP account
//!					Connect to the IMAP server 
//!					Perform full sync with IMAP4 server.
//!					Initialises Imap Account
//!					Disconnect
//!					Create multiple messages from RFC822 file and sends the messages to the same IMAP account.
//!					Set the full download limits.
//!					Download Limits:
//!					MaxEmailSize = Default (KMaxInt)
//!					ImapMailOption = TImap4GetMailOptions::EGetImap4EmailBodyTextAndAttachments
//!					Connect
//!					Download the mails
//!					Check the Children Count on Imap remote Folder
//!					Disconnect
//!					Delete Messages from specified Folder
//!					UnDeleteAll Messages Deleted
//!					Connect to the Imap Server
//!					Do full Synchronisation
//!					Check the messages are not deleted. (if the message deleted was from Remote Folder)
//!	@SYMTestExpectedResults		EPass,Messages are not deleted from the specified(Inbox) folder (as well as from ImapServer if the messages are in RemoteImapFolder)
//!	@SYMAuthor			Mrudul Pendharkar
//!	@SYMREQ				5585
//!	@SYMPREQ			1160

PRINT Setup Begins #####################################################

RUN_TEST_STEP	300	T_MsgCommonServer  	StartUp
RUN_TEST_STEP	300	T_MsgImapServer	StartUp
RUN_TEST_STEP	300	T_MsgSmtpServer	StartUp

RUN_TEST_STEP	300	T_MsgCommonServer  	InitNtRas			c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0022-InitNtRas
RUN_TEST_STEP	300	T_MsgCommonServer  	ResetMessageStore		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0022-ResetMessageStore
RUN_TEST_STEP 	300 	T_MsgImapServer		CreateImapAccount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0022-CreateImapAccount 
RUN_TEST_STEP 	100 	T_MsgImapServer		ChangeImap4SubAndSyncSettings	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0022-ChangeSubAndSyncSettings
RUN_TEST_STEP 	100 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0022-ConnectImap4Server
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0022-DoFullImap4Synchronisation
RUN_TEST_STEP 	100 	T_MsgImapServer		InitialiseImap4Account		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0022-InitialiseImap4Account
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0022-DoFullImap4Synchronisation
RUN_TEST_STEP  	300 	T_MsgImapServer		CheckChildrenCountImap 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0022-CheckChildrenCountRemoteInbox0
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0022-DisConnectImap4Server
PRINT Setup Completed
PRINT Execute begins
RUN_TEST_STEP 	300 	T_MsgSmtpServer		CreateSmtpMessageFromEmailFile 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0022-CreateSmtpMessageFromEmailFile0
RUN_TEST_STEP 	300 	T_MsgSmtpServer		CreateSmtpMessageFromEmailFile 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0022-CreateSmtpMessageFromEmailFile1
RUN_TEST_STEP 	300 	T_MsgSmtpServer		CreateSmtpMessageFromEmailFile 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0022-CreateSmtpMessageFromEmailFile2
RUN_TEST_STEP 	300 	T_MsgSmtpServer		CreateSmtpMessageFromEmailFile 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0022-CreateSmtpMessageFromEmailFile3
RUN_TEST_STEP 	300 	T_MsgSmtpServer		CreateSmtpMessageFromEmailFile 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0022-CreateSmtpMessageFromEmailFile4
RUN_TEST_STEP 	300 	T_MsgCommonServer  	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0022-CheckChildrenCountOutbox5
RUN_TEST_STEP 	300 	T_MsgSmtpServer		SendSmtpMessage 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0022-SendSmtpMessage
RUN_TEST_STEP 	300 	T_MsgImapServer		SetImap4FullDownloadLimits 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0022-SetImap4FullDownloadLimits
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0022-ConnectImap4Server
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0022-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer		ImapInvokeAsyncFunction		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0022-ImapInvokeAsyncFunction
RUN_TEST_STEP  	300 	T_MsgImapServer		CheckChildrenCountImap 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0022-CheckChildrenCountRemoteInbox5
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0022-DisConnectImap4Server
//Offline Delete Messages
RUN_TEST_STEP  	300 	T_MsgImapServer		DeleteAllImapChildren 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0022-DeleteAllImapChildren
//Revert delete Operation
RUN_TEST_STEP  	300 	T_MsgImapServer		UnDeleteAll			c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0022-UnDeleteAll
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0022-ConnectImap4Server
//Verify the Delete operation has reverted
RUN_TEST_STEP  	300 	T_MsgImapServer		CheckChildrenCountImap 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0022-CheckChildrenCountRemoteInbox5
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0022-DisConnectImap4Server

RUN_TEST_STEP	300	T_MsgCommonServer	ShutDown
RUN_TEST_STEP	300	T_MsgImapServer		ShutDown
RUN_TEST_STEP	300	T_MsgSmtpServer		ShutDown

PRINT Execute Completed ################################################
END_TESTCASE	MSG-IMAP-OFFLINE-UNDELETEALL-0002


START_TESTCASE	MSG-IMAP-OFFLINE-UNDELETEALL-0003
//!	@SYMTestCaseID			MSG-IMAP-OFFLINE-UNDELETEALL-0003
//!	@SYMTestCaseDesc		Negative:
//!					This Test Deletes Multiple Messages & gives two times UndeleteAll command
//!	@SYMTestPriority		High
//!   	@SYMTestType			CIT
//!  	@SYMTestStatus			Implemented   
//!	@SYMTestCaseDependencies	requires ced -i c:\ced_default_ras.cfg to set comms.
//!	@SYMTestActions			Initialise the RAS connection
//!					Reset the message store to clean up the central repository
//!					Create an IMAP account
//!					Connect to the IMAP server 
//!					Perform full sync with IMAP4 server.
//!					Initialises Imap Account
//!					Download Limits:
//!					MaxEmailSize = Default (KMaxInt)
//!					ImapMailOption = TImap4GetMailOptions::EGetImap4EmailBodyTextAndAttachments
//!					Disconnect
//!					Create multiple messages from RFC822 file and sends the messages to the same IMAP account.
//!					Set the full download limits.
//!					Connect
//!					Download the mails
//!					Check the Children Count on Imap remote Folder
//!					Disconnect
//!					Delete Messages from specified Folder
//!					UnDeleteAll Messages Deleted
//!					UnDeleteAll Messages Deleted
//!					Connect to the Imap Server
//!					Do full Synchronisation
//!					Check the messages are not deleted. (if the message deleted was from Remote Folder)
//!	@SYMTestExpectedResults		EPass,Messages are not deleted from the specified(Inbox) folder (as well as from ImapServer if the messages are in RemoteImapFolder)
//!	@SYMAuthor			Mrudul Pendharkar
//!	@SYMREQ				5585
//!	@SYMPREQ			1160


PRINT Setup Begins #####################################################

RUN_TEST_STEP	300	T_MsgCommonServer  	StartUp
RUN_TEST_STEP	300	T_MsgImapServer	StartUp
RUN_TEST_STEP	300	T_MsgSmtpServer	StartUp

RUN_TEST_STEP	300	T_MsgCommonServer  	InitNtRas			c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-InitNtRas
RUN_TEST_STEP	300	T_MsgCommonServer  	ResetMessageStore		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-ResetMessageStore
RUN_TEST_STEP 	300 	T_MsgImapServer		CreateImapAccount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-CreateImapAccount 
RUN_TEST_STEP 	100 	T_MsgImapServer		ChangeImap4SubAndSyncSettings	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-ChangeSubAndSyncSettings
RUN_TEST_STEP 	100 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-ConnectImap4Server
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-DoFullImap4Synchronisation
RUN_TEST_STEP 	100 	T_MsgImapServer		InitialiseImap4Account		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-InitialiseImap4Account
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-DoFullImap4Synchronisation
RUN_TEST_STEP  	300 	T_MsgImapServer		CheckChildrenCountImap 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-CheckChildrenCountRemoteInbox0
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-DisConnectImap4Server
PRINT Setup Completed
PRINT Execute begins
RUN_TEST_STEP 	300 	T_MsgSmtpServer		CreateSmtpMessageFromEmailFile 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-CreateSmtpMessageFromEmailFile0
RUN_TEST_STEP 	300 	T_MsgSmtpServer		CreateSmtpMessageFromEmailFile 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-CreateSmtpMessageFromEmailFile1
RUN_TEST_STEP 	300 	T_MsgSmtpServer		CreateSmtpMessageFromEmailFile 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-CreateSmtpMessageFromEmailFile2
RUN_TEST_STEP 	300 	T_MsgSmtpServer		CreateSmtpMessageFromEmailFile 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-CreateSmtpMessageFromEmailFile3
RUN_TEST_STEP 	300 	T_MsgSmtpServer		CreateSmtpMessageFromEmailFile 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-CreateSmtpMessageFromEmailFile4
RUN_TEST_STEP 	300 	T_MsgCommonServer  	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-CheckChildrenCountOutbox5
RUN_TEST_STEP 	300 	T_MsgSmtpServer		SendSmtpMessage 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-SendSmtpMessage
RUN_TEST_STEP 	300 	T_MsgImapServer		SetImap4FullDownloadLimits 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-SetImap4FullDownloadLimits
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-ConnectImap4Server
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-DoFullImap4Synchronisation
RUN_TEST_STEP	300	T_MsgImapServer		ImapInvokeAsyncFunction		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-ImapInvokeAsyncFunction
RUN_TEST_STEP  	300 	T_MsgImapServer		CheckChildrenCountImap 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-CheckChildrenCountRemoteInbox5
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-DisConnectImap4Server
//Offline Delete Operation
RUN_TEST_STEP  	300 	T_MsgImapServer		DeleteAllImapChildren 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-DeleteAllImapChildren
//Revert Delete Operation
RUN_TEST_STEP  	300 	T_MsgImapServer		UnDeleteAll			c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-UnDeleteAll
//Give the revert command once mores
RUN_TEST_STEP  	300 	T_MsgImapServer		UnDeleteAll			c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-UnDeleteAll
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-DoFullImap4Synchronisation
//Verify the delete operation is reverted
RUN_TEST_STEP  	300 	T_MsgImapServer		CheckChildrenCountImap 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-CheckChildrenCountRemoteInbox5
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini     		0023-DisConnectImap4Server

RUN_TEST_STEP	300	T_MsgCommonServer	ShutDown
RUN_TEST_STEP	300	T_MsgImapServer		ShutDown
RUN_TEST_STEP	300	T_MsgSmtpServer		ShutDown

PRINT Execute Completed ################################################
END_TESTCASE	MSG-IMAP-OFFLINE-UNDELETEALL-0003


START_TESTCASE	MSG_IMAP_OFFLINE_DELMSG_0012
//!	@SYMTestCaseID			MSG_IMAP_OFFLINE_DELMSG_0012
//!	@SYMTestCaseDesc		This test script creates a RFC822 message
//!					& sends the message to the same account.
//!					It then receives the message, by full syncronisation with Pop account.
//!					The recieved message is then deleted while offline(not connected).
//!					It then connects to Imap server and synchronises the offline folder to 
//!					delete the copy of message on Imap Server
//!	@SYMTestPriority		Critical
//!   	@SYMTestType			CIT
//!  	@SYMTestStatus			Implemented   
//!	@SYMTestCaseDependencies	requires ced -i c:\ced_default_ras.cfg to set comms.
//!	@SYMTestActions			Initialises the RAS connection
//!					Resets the message store to clean up the central repository
//!					Creates an IMAP account by reading the settings from the file mentioned
//!					thus setting the IMAP and SMTP service settings
//!					Connects to the IMAP server and performs full sync with IMAP4 server.
//!					Connects to the IMAP server and deletes all mails in the Inbox on the server.
//!					Creates messages from RFC822 file and sends the messages to the same IMAP account.
//!					Sets the full download limits.
//!					Download the mails with IMAP4 KIMAP4MTMConnectAndPopulateAllMailAndStayOnline command
//!					and compares the received messages with sent messages based on the Download limits set.
//!					Disconnect from the server
//!					Delete the message from specified folder(Inbox)
//!					Connect to the Imap Server
//!					Do Full synchronisation
//!					Disconnect from the Server
//!	@SYMTestExpectedResults		EPass,The message received has been deleted from the Imap server also.
//!	@SYMAuthor			Mrudul V. Pendharkar


PRINT Setup Begins #####################################################

RUN_TEST_STEP	300	T_MsgCommonServer  	StartUp
RUN_TEST_STEP	300	T_MsgImapServer	StartUp
RUN_TEST_STEP	300	T_MsgSmtpServer	StartUp

RUN_TEST_STEP	300	T_MsgCommonServer  	InitNtRas			c:\msgtest\email\imap\offline\msg-imap-offline3.ini		0024-InitNtRas
RUN_TEST_STEP	300	T_MsgCommonServer  	ResetMessageStore		c:\msgtest\email\imap\offline\msg-imap-offline3.ini		0024-ResetMessageStore
RUN_TEST_STEP 	300 	T_MsgImapServer		CreateImapAccount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini		0024-CreateImapAccount 
RUN_TEST_STEP 	100 	T_MsgImapServer		ChangeImap4SubAndSyncSettings	c:\msgtest\email\imap\offline\msg-imap-offline3.ini		0024-ChangeSubAndSyncSettings
RUN_TEST_STEP 	100 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini		0024-ConnectImap4Server
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini		0024-DoFullImap4Synchronisation
RUN_TEST_STEP 	100 	T_MsgImapServer		InitialiseImap4Account		c:\msgtest\email\imap\offline\msg-imap-offline3.ini		0024-InitialiseImap4Account
RUN_TEST_STEP	100	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini		0024-DoFullImap4Synchronisation
RUN_TEST_STEP  	300 	T_MsgImapServer		CheckChildrenCountImap 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini		0024-CheckChildrenCountRemoteInbox
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini		0024-DisConnectImap4Server

PRINT Setup Completed

PRINT Execute begins

RUN_TEST_STEP 	300 	T_MsgSmtpServer		CreateSmtpMessageFromEmailFile 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini		0024-CreateSmtpMessageFromEmailFile
RUN_TEST_STEP 	300 	T_MsgCommonServer  	CheckChildrenCount 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini		0024-CheckChildrenCountOutbox
RUN_TEST_STEP 	300 	T_MsgSmtpServer		SendSmtpMessage 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini		0024-SendSmtpMessage
RUN_TEST_STEP 	300 	T_MsgImapServer		SetImap4FullDownloadLimits 	c:\msgtest\email\imap\offline\msg-imap-offline3.ini		0024-SetImap4FullDownloadLimits
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini		0024-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini		0024-DoFullImap4Synchronisation
RUN_TEST_STEP 	300 	T_MsgImapServer		ImapInvokeAsyncFunction      	c:\msgtest\email\imap\offline\msg-imap-offline3.ini		0024-ImapInvokeAsyncFunction
RUN_TEST_STEP  	300 	T_MsgImapServer		CheckChildrenCountImap 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini		0024-CheckChildrenCountRemoteInbox1
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini		0024-DisConnectImap4Server
RUN_TEST_STEP 	300 	T_MsgImapServer		DeleteMessage			c:\msgtest\email\imap\offline\msg-imap-offline3.ini		0024-DeleteMessage
RUN_TEST_STEP 	300 	T_MsgImapServer		ConnectImap4Server		c:\msgtest\email\imap\offline\msg-imap-offline3.ini		0024-ConnectImap4Server
RUN_TEST_STEP	300	T_MsgImapServer		DoFullImap4Synchronisation	c:\msgtest\email\imap\offline\msg-imap-offline3.ini		0024-DoFullImap4Synchronisation
RUN_TEST_STEP  	300 	T_MsgImapServer		CheckChildrenCountImap 		c:\msgtest\email\imap\offline\msg-imap-offline3.ini		0024-CheckChildrenCountRemoteInbox
RUN_TEST_STEP 	300 	T_MsgImapServer		DisConnectImapServer		c:\msgtest\email\imap\offline\msg-imap-offline3.ini		0024-DisConnectImap4Server

RUN_TEST_STEP	300	T_MsgCommonServer	ShutDown
RUN_TEST_STEP	300	T_MsgImapServer		ShutDown
RUN_TEST_STEP	300	T_MsgSmtpServer		ShutDown

PRINT Execute Completed ################################################
END_TESTCASE	MSG_IMAP_OFFLINE_DELMSG_0012



