1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1.2 +++ b/os/kernelhwsrv/kerneltest/e32test/usbho/t_otgdi/inc/testcase0458.h Fri Jun 15 03:10:57 2012 +0200
1.3 @@ -0,0 +1,76 @@
1.4 +// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
1.5 +// All rights reserved.
1.6 +// This component and the accompanying materials are made available
1.7 +// under the terms of the License "Eclipse Public License v1.0"
1.8 +// which accompanies this distribution, and is available
1.9 +// at the URL "http://www.eclipse.org/legal/epl-v10.html".
1.10 +//
1.11 +// Initial Contributors:
1.12 +// Nokia Corporation - initial contribution.
1.13 +//
1.14 +// Contributors:
1.15 +//
1.16 +// Description:
1.17 +// @internalComponent
1.18 +// Open/Close 'powered peripheral' test
1.19 +//
1.20 +//
1.21 +
1.22 +#ifndef TESTCASE_0458_H
1.23 +#define TESTCASE_0458_H
1.24 +
1.25 +
1.26 +
1.27 +//----------------------------------------------------------------------------------------------
1.28 +//! @SYMTestCaseID PBASE-T_OTGDI-0458
1.29 +//! @SYMTestCaseDesc OTGDI driver session can be repeatedly opened and closed without a) panicking or b) leaking resources.
1.30 +//! @SYMFssID
1.31 +//! @SYMPREQ 1782
1.32 +//! @SYMREQ n/a
1.33 +//! @SYMTestType UT
1.34 +//! @SYMTestPriority 1
1.35 +//! @SYMTestActions 1. B plug and and plugged into Host. Call function to open OTGDI driver session.
1.36 +//! 2. Call function to close OTGDI driver session.
1.37 +//! 3. Repeat from step 1 (x 3)
1.38 +//! @SYMTestExpectedResults No panic occurs, no error code returned, we get session handle; session gets closed
1.39 +//! @SYMTestStatus Proto
1.40 +//----------------------------------------------------------------------------------------------
1.41 +
1.42 + class CTestCase0458 : public CTestCaseRoot
1.43 + {
1.44 +public:
1.45 + static CTestCase0458* NewL(TBool aHost);
1.46 + virtual ~CTestCase0458();
1.47 +
1.48 + virtual void ExecuteTestCaseL();
1.49 + void DoCancel();
1.50 + void RunStepL();
1.51 +
1.52 + virtual void DescribePreconditions();
1.53 + TInt GetStepIndex() { return(iCaseStep); };
1.54 +
1.55 +private:
1.56 + CTestCase0458(TBool aHost);
1.57 + void ConstructL();
1.58 +
1.59 +
1.60 + // DATA
1.61 +private:
1.62 + enum TCaseSteps
1.63 + {
1.64 + EPreconditions,
1.65 + ELoadLdd,
1.66 + EUnloadLdd,
1.67 + ELoopDecrement,
1.68 + ELastStep
1.69 + };
1.70 +
1.71 + TCaseSteps iCaseStep;
1.72 + TInt iRepeats; // loop counter, set to run 3 times over
1.73 +
1.74 + const static TTestCaseFactoryReceipt<CTestCase0458> iFactoryReceipt;
1.75 +
1.76 + };
1.77 +
1.78 +
1.79 +#endif // TESTCASE_0458_H