|
1 // Copyright (c) 2007-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 the License "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 // @internalComponent |
|
15 // Open/Close 'A' |
|
16 // |
|
17 // |
|
18 |
|
19 #ifndef TESTCASE_0456_H |
|
20 #define TESTCASE_0456_H |
|
21 |
|
22 |
|
23 |
|
24 //---------------------------------------------------------------------------------------------- |
|
25 //! @SYMTestCaseID PBASE-T_OTGDI-0456 |
|
26 //! @SYMTestType UT |
|
27 //! @SYMPREQ PREQ1782 |
|
28 //! @SYMREQ n/a |
|
29 //! @SYMTestCaseDesc OTGDI driver session can be repeatedly opened and closed without a) panicking or b) leaking resources. |
|
30 //! @SYMTestActions 1. A plug inserted. Call function to open OTGDI driver session. |
|
31 //! 2. Call function to close OTGDI driver session. |
|
32 //! 3. Repeat from step 1 (x 3) |
|
33 //! @SYMTestExpectedResults No panic occurs, no error code returned, we get session handle; session gets closed |
|
34 //! @SYMTestPriority High |
|
35 //! @SYMTestStatus Implemented |
|
36 //---------------------------------------------------------------------------------------------- |
|
37 |
|
38 class CTestCase0456 : public CTestCaseRoot |
|
39 { |
|
40 public: |
|
41 static CTestCase0456* NewL(TBool aHost); |
|
42 virtual ~CTestCase0456(); |
|
43 virtual void ExecuteTestCaseL(); |
|
44 void DoCancel(); |
|
45 void RunStepL(); |
|
46 virtual void DescribePreconditions(); |
|
47 |
|
48 TInt GetStepIndex() { return(iCaseStep); }; |
|
49 |
|
50 private: |
|
51 CTestCase0456(TBool aHost); |
|
52 void ConstructL(); |
|
53 |
|
54 |
|
55 private: |
|
56 enum TCaseSteps |
|
57 { |
|
58 EPreconditions, |
|
59 ELoadLdd, |
|
60 EUnloadLdd, |
|
61 ELoopDecrement, |
|
62 ELastStep |
|
63 }; |
|
64 |
|
65 TCaseSteps iCaseStep; |
|
66 TInt iRepeats; // loop counter, set to run 3 times over |
|
67 |
|
68 const static TTestCaseFactoryReceipt<CTestCase0456> iFactoryReceipt; |
|
69 |
|
70 }; |
|
71 |
|
72 |
|
73 #endif // TESTCASE_0456_H |