|
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 // 'A' connector removal test |
|
16 // |
|
17 // |
|
18 |
|
19 |
|
20 #ifndef TESTCASE0460_H |
|
21 #define TESTCASE0460_H |
|
22 |
|
23 |
|
24 |
|
25 //---------------------------------------------------------------------------------------------- |
|
26 //! @SYMTestCaseID PBASE-T_OTGDI-0460 |
|
27 //! @SYMTestCaseDesc Must be able to detect an A plug insertion. Test proves we can subscribe for insertion events. |
|
28 //! @SYMFssID |
|
29 //! @SYMPREQ 1782 |
|
30 //! @SYMREQ 7079 |
|
31 //! @SYMTestType UT |
|
32 //! @SYMTestPriority 1 |
|
33 //! @SYMTestActions 1. Call OtgEventNotification() to register for insert/remove event. |
|
34 //! 2. Remove A-Plug, removal is detected. |
|
35 //! @SYMTestExpectedResults 2. A-Plug removal event fires when it should. |
|
36 //---------------------------------------------------------------------------------------------- |
|
37 |
|
38 class CTestCase0460 : public CTestCaseRoot |
|
39 { |
|
40 public: |
|
41 static CTestCase0460* NewL(TBool aHost); |
|
42 virtual ~CTestCase0460(); |
|
43 |
|
44 virtual void ExecuteTestCaseL(); |
|
45 void DoCancel(); |
|
46 |
|
47 void RunStepL(); |
|
48 virtual void DescribePreconditions(); |
|
49 TInt GetStepIndex() { return(iCaseStep); }; |
|
50 |
|
51 private: |
|
52 CTestCase0460(TBool aHost); |
|
53 void ConstructL(); |
|
54 |
|
55 // DATA |
|
56 public: |
|
57 |
|
58 |
|
59 private: |
|
60 TInt iDequeAttempts; |
|
61 |
|
62 enum TCaseSteps |
|
63 { |
|
64 EPreconditions, |
|
65 ELoadLdd, |
|
66 ERegisterForEvents, // QueueOtgEventRequest( event, status ); |
|
67 EDriveID_PIN, |
|
68 EWait5, |
|
69 ETestStateA, |
|
70 EUnloadLdd, |
|
71 ELastStep |
|
72 }; |
|
73 |
|
74 TCaseSteps iCaseStep; |
|
75 |
|
76 const static TTestCaseFactoryReceipt<CTestCase0460> iFactoryReceipt; |
|
77 }; |
|
78 |
|
79 |
|
80 #endif // TESTCASE0460_H |