messagingfw/msgtestfw/TestCases/ScriptedTestCases/ConnectAndPopulateAllStayOnlineImap4Email.script
changeset 0 8e480a14352b
equal deleted inserted replaced
-1:000000000000 0:8e480a14352b
       
     1 //
       
     2 // Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
       
     3 // All rights reserved.
       
     4 // This component and the accompanying materials are made available
       
     5 // under the terms of "Eclipse Public License v1.0"
       
     6 // which accompanies this distribution, and is available
       
     7 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 //
       
     9 // Initial Contributors:
       
    10 // Nokia Corporation - initial contribution.
       
    11 //
       
    12 // Contributors:
       
    13 //
       
    14 // Description:
       
    15 //
       
    16 // Test Case Name:
       
    17 //	ConnectAndPopulateAllStayOnlineImap4Email.script
       
    18 // ------------------------------------------
       
    19 // Component Under Test:
       
    20 //	Email
       
    21 // ------------------------------------------
       
    22 // API function under test:
       
    23 //	CImap4ClientMtm::InvokeAsyncFunctionL()
       
    24 //	with IMAP4 command KIMAP4MTMConnectAndPopulateAllMailAndStayOnline
       
    25 // ------------------------------------------
       
    26 // Requirement/Use Case/Functional Spec:
       
    27 //	DEF 045525 
       
    28 // ------------------------------------------
       
    29 // Polarity:
       
    30 //	Positive
       
    31 // ------------------------------------------
       
    32 // Test Type (unit, integration, panic, performance, conformance, stress, or interoperability):
       
    33 //	Integration
       
    34 // ------------------------------------------
       
    35 // Expected Panic ID (if a panic test, only for non-scripted test cases):
       
    36 //	n/a
       
    37 // ------------------------------------------
       
    38 // Interface Dependencies (does it require connection, which subsystems does it require):
       
    39 // 	NTRAS
       
    40 // ------------------------------------------
       
    41 // Importance (critical, high, or low):
       
    42 //	High
       
    43 // ------------------------------------------
       
    44 // Execution Time (fast, medium, or slow):
       
    45 //	medium
       
    46 // ------------------------------------------
       
    47 // Pre-condition description:
       
    48 //	1.  Set the SMTP and IMAP4 service settings for an IMAP4 account
       
    49 //	2.  Connect to IMAP4 server and synchronise with the IMAP4 server 
       
    50 //	3.  Delete all mails in the Inbox on the server
       
    51 //	4.  Disconnect from IMAP4 server
       
    52 //
       
    53 //	The Local Inbox and Sent Item folders and the remote Inbox folder of IMAP4 
       
    54 //	account are cleaned up before starting the test.
       
    55 // ------------------------------------------
       
    56 // Action Description:
       
    57 // 	Main purpose of test that to check that emails marked as New get populated (and stay as
       
    58 //  as new after ConnectAndPopulateAllMailAndStayOnline operation. Before bug was fixed the New
       
    59 //  flag would be cleared after any connection. (i.e. should be only cleared before 1st Sync
       
    60 //  after connection).
       
    61 //	
       
    62 // 	Implementation and execution:
       
    63 //	1.  Create 2 emails from data file and send emails to the same account
       
    64 //	2.  Synchronise Inbox 
       
    65 //  3.  Send 2 more emails to the same account
       
    66 //	4.  Synchronise Inbox 
       
    67 //	5.  Fetch the mails with IMAP4 KIMAP4MTMConnectAndPopulateAllMailAndStayOnline command
       
    68 //	6.  Disconnect from IMAP4 server
       
    69 //	7.  Check the received messages' flags. 
       
    70 //		
       
    71 // ------------------------------------------
       
    72 // Post-condition description (i.e., expected outcome):
       
    73 //      Should have 4 messages, 2 New, 4 Complete (fetched)
       
    74 //		
       
    75 // ------------------------------------------
       
    76 // Reference to a review document:
       
    77 //	
       
    78 // ------------------------------------------
       
    79 // Full pathname of an epoc.ini (if there are special epoc.ini requirements)
       
    80 // 	For emulator, an epoc.ini that creates an emulated external drive (drive letter 
       
    81 //	between D: and Y:) is required. Optionally, an environment variable can be defined.
       
    82 // ------------------------------------------
       
    83 // Any CommDb restrictions:
       
    84 //	NTRAS CommDb (should have reasonably long idle timeout values to avoid disconnection during
       
    85 //  Sleep actions
       
    86 // ------------------------------------------
       
    87 // Build Requirements (e.g., no watchers):
       
    88 //	No Watchers and Phone Book Synchroniser
       
    89 // ------------------------------------------
       
    90 // Hardware Requirements
       
    91 //	Null Modem Cable for NT RAS connection
       
    92 // ------------------------------------------
       
    93 RUN_UTILS DeleteFile c:\messaging.db
       
    94 LOAD_SUITE MessagingTestServer -SharedData
       
    95 
       
    96 //CED c:\msgtest\TestFramework\Configurations\CommDbSettings\NtRasLongIdleTimeout.cfg
       
    97 PREFIX RUN_TEST_STEP 100 MessagingTestServer 
       
    98 BEGIN_TEST_CASE
       
    99 SETUP_TEST_CASE
       
   100 GetBaseConstants				c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini GetBaseConstants
       
   101 InitNtRas						c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini InitNtRas
       
   102 CreateSession					c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini CreateSession
       
   103 ResetMessageStore				c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini ResetMessageStore
       
   104 CreateImap4Service				c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini CreateImap4Service
       
   105 CreateSmtpService				c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini CreateSmtpService
       
   106 CreateRegistry					c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini CreateRegistry
       
   107 CreateImap4Mtm					c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini CreateImap4Mtm
       
   108 CreateSmtpMtm					c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini CreateSmtpMtm
       
   109 GetDefaultSmtpService				c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini GetDefaultSmtpService
       
   110 SetImap4ServiceParameters		c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini SetImap4ServiceParameters
       
   111 SetSmtpServiceParameters		c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini SetSmtpServiceParameters
       
   112 SetDefaultConfiguration			c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini SetDefaultConfiguration2
       
   113 ConnectImap4Server   			c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini ConnectImap4Server0
       
   114 DoFullImap4Synchronisation		c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini DoFullImap4Synchronisation0
       
   115 FindEntryByName					c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini FindEntryByName0
       
   116 DeleteChildren					c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini DeleteChildren
       
   117 CheckChildrenCount				c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini CheckChildrenCount0
       
   118 DisconnectImap4Server			c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini DisconnectImap4Server0
       
   119 EXECUTE_TEST_CASE
       
   120 CreateSmtpMessageFromEmailFile	c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini CreateSmtpMessageFromEmailFile0
       
   121 CopyEntry						c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini CopyEntry0
       
   122 CreateSmtpMessageFromEmailFile	c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini CreateSmtpMessageFromEmailFile1
       
   123 CopyEntry						c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini CopyEntry1
       
   124 Sleep		   					c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini Sleep5
       
   125 ConnectImap4Server		   		c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini ConnectImap4Server1
       
   126 DoFullImap4Synchronisation   	c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini DoFullImap4Synchronisation1
       
   127 DisconnectImap4Server			c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini DisconnectImap4Server1
       
   128 CreateSmtpMessageFromEmailFile	c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini CreateSmtpMessageFromEmailFile0
       
   129 CopyEntry						c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini CopyEntry0
       
   130 CreateSmtpMessageFromEmailFile	c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini CreateSmtpMessageFromEmailFile1
       
   131 CopyEntry						c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini CopyEntry1
       
   132 Sleep		   					c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini Sleep5
       
   133 ConnectImap4Server		   		c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini ConnectImap4Server1
       
   134 DoFullImap4Synchronisation   	c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini DoFullImap4Synchronisation1
       
   135 DisconnectImap4Server			c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini DisconnectImap4Server1
       
   136 SetImap4FullDownloadLimits		c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini SetImap4FullDownloadLimits1 
       
   137 DoImap4ConnectAndPopulateAllMailAndStayOnline   		c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini ConnPopulateAllMailAndStayOnline
       
   138 DisconnectImap4Server			c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini DisconnectImap4Server1
       
   139 CHECK_POSTCONDITIONS
       
   140 CheckChildrenCount		   		c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini CheckChildrenCount4
       
   141 CheckChildrenCountWithFlagNew		   		c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini CheckChildrenCountWithFlagNew2
       
   142 CheckChildrenCountWithFlagComplete			c:\msgtest\TestFramework\ScriptedTestCases\ConnectAndPopulateImap4EmailTests.ini CheckChildrenCountWithFlagComp4
       
   143 END_TEST_CASE