|
1 /* |
|
2 * Copyright (c) 2008 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 */ |
|
17 |
|
18 |
|
19 /** |
|
20 @file |
|
21 @test |
|
22 @internalComponent |
|
23 */ |
|
24 |
|
25 #ifndef tmsteststep_ |
|
26 #define tmsteststep_ |
|
27 |
|
28 #include <test/testexecutestepbase.h> |
|
29 #include <w32std.h> |
|
30 #include <flogger.h> |
|
31 #include <badesca.h> |
|
32 |
|
33 // default name that a test will be called if not specifically set in the calling object |
|
34 _LIT(KUnknownSYMTestCaseIDName, "@SYMTestCaseID Unnamed test"); |
|
35 _LIT(KUndefinedSYMTestCaseIDName, "@SYMTestCaseID is not defined"); |
|
36 _LIT(KNotATestSYMTestCaseIDName, "This is not a test"); |
|
37 |
|
38 class CTmsTestStep : public CTestStep |
|
39 { |
|
40 public: |
|
41 IMPORT_C CTmsTestStep(); |
|
42 IMPORT_C virtual ~CTmsTestStep(); |
|
43 IMPORT_C void CloseTMSGraphicsStep(); |
|
44 IMPORT_C void MQCTest(TBool aCondition, const TText8* aFile, TInt aLine); |
|
45 IMPORT_C void MQCTestL(TBool aCondition, const TText8* aFile, TInt aLine); |
|
46 IMPORT_C void SetTestStepID(const TDesC& aStepName); |
|
47 IMPORT_C void SetOverallTestStepID(const TDesC& aStepName); |
|
48 IMPORT_C void RecordTestResultL(); |
|
49 IMPORT_C void MultipleResultsForSameID(TBool aShowMultipleResults); |
|
50 |
|
51 static void DebugLogL(const TDesC8 &aText, const TDesC8 &aText1, TInt aPos); |
|
52 static TInt DebugLogPosL(); |
|
53 protected: |
|
54 static TInt ReadNextLineL( RFile &aFile, TDes8 &aLine ); |
|
55 void CleanUpAndWriteResults(); |
|
56 TBuf8<KMaxTestExecuteNameLength> iCurrentTestStepName; |
|
57 TBool iStepPassFail; |
|
58 TBool iShowMultipleResults; |
|
59 CDesCArrayFlat* iTestStepNames; |
|
60 RArray<TInt> iTestStepPositions; |
|
61 }; |
|
62 |
|
63 #endif /*tmsteststep_*/ |