lafagnosticuifoundation/cone/tef/TConeErrorMsgStep.h
changeset 0 2f259fa3e83a
equal deleted inserted replaced
-1:000000000000 0:2f259fa3e83a
       
     1 // Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
       
     2 // All rights reserved.
       
     3 // This component and the accompanying materials are made available
       
     4 // under the terms of "Eclipse Public License v1.0"
       
     5 // which accompanies this distribution, and is available
       
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     7 //
       
     8 // Initial Contributors:
       
     9 // Nokia Corporation - initial contribution.
       
    10 //
       
    11 // Contributors:
       
    12 //
       
    13 // Description:
       
    14 //
       
    15 
       
    16 /**
       
    17  @file 
       
    18  @internalComponent - Internal Symbian test code 
       
    19 */
       
    20 
       
    21 
       
    22 #if !defined(__TCONEERRORMSGSTEP_H__)
       
    23 #define __TCONEERRORMSGSTEP_H__
       
    24 
       
    25 #include <test/testexecutestepbase.h>
       
    26 #include "TConeTestServer.h"
       
    27 #include "appfwk_test_AppUi.h"
       
    28 
       
    29 //! A CTestStep Derived Class.\n
       
    30 
       
    31 /**   Incorporates the tests to create a sample application and 
       
    32       handle the key events.\n  */
       
    33 
       
    34 class CTConeErrorMsgStep : public CTmsTestStep
       
    35 	{
       
    36 public:
       
    37 	CTConeErrorMsgStep();
       
    38 	~CTConeErrorMsgStep();
       
    39 //	virtual TVerdict doTestStepPreambleL();
       
    40 //	virtual TVerdict doTestStepPostambleL();
       
    41 	virtual TVerdict doTestStepL();
       
    42 	void ConstructAppL(CCoeEnv* aCoe);
       
    43 
       
    44 private:
       
    45 	};
       
    46 //! A CTestCoeAppUi derived Class.\n
       
    47 
       
    48 /**   App Ui class for the TConeErrorMsgStep.\n */
       
    49 
       
    50 class CConeErrorMsgTestAppUi : public CTestCoeAppUi
       
    51     {
       
    52 public:
       
    53 	CConeErrorMsgTestAppUi(CTmsTestStep* aStep);
       
    54 	~CConeErrorMsgTestAppUi();
       
    55 	void ConstructL();
       
    56 private: // utility
       
    57 	void TestCase01L();
       
    58 	void TestCase02L();
       
    59 	void TestCase03L();
       
    60 	void TestCase04L();
       
    61 	void TestCase05L();
       
    62 	void TestCase06L();
       
    63 	void TestCase07();
       
    64 	void TestCase08();
       
    65 	void RunTestStepL(TInt aStepNum);
       
    66 	void CloseDialogsL();
       
    67 	void TestErrorDialogL(const TDesC8& aTestCaseName,
       
    68 			const TDesC& aTestCompareMbm,
       
    69 			const TDesC* aDbgBmp=NULL,
       
    70 			const TDesC* aDbgConvBmp=NULL,
       
    71 			const TDesC* aDbgConvCompBmp=NULL,
       
    72 			const TDesC* aDbgMbm=NULL);
       
    73 	void TestLeaveWithErrorTextL(const TDesC& aErrorText, const TDesC* aContextErrorText=NULL, const TBool& aExceedMaxDesc=NULL);
       
    74 	void ConvertToBmpL(const CFbsBitmap* aBitmap, const TDesC* aFileName);
       
    75 	TSize CalculateScreenSize();
       
    76 private:
       
    77 	RFs iFs;
       
    78 	RWsSession iWs;
       
    79     };
       
    80 
       
    81 //! TConeErrorMsg Test Step Name
       
    82 _LIT(KTConeErrorMsgStep,"TConeErrorMsg");
       
    83 
       
    84 class CTestCoeEnv : public CCoeEnv
       
    85 	{
       
    86 	public:
       
    87 	inline TDes& TestErrorText() 	{ return CCoeEnv::ErrorText(); }
       
    88 	inline TDes& TestErrorContextText() { return CCoeEnv::ErrorContextText(); }
       
    89 	};
       
    90 
       
    91 #endif
       
    92 
       
    93