os/kernelhwsrv/kerneltest/e32test/usbho/t_otgdi/inc/testcase0456.h
author sl@SLION-WIN7.fritz.box
Fri, 15 Jun 2012 03:10:57 +0200 (2012-06-15)
changeset 0 bde4ae8d615e
permissions -rw-r--r--
First public contribution.
sl@0
     1
// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
sl@0
     2
// All rights reserved.
sl@0
     3
// This component and the accompanying materials are made available
sl@0
     4
// under the terms of the License "Eclipse Public License v1.0"
sl@0
     5
// which accompanies this distribution, and is available
sl@0
     6
// at the URL "http://www.eclipse.org/legal/epl-v10.html".
sl@0
     7
//
sl@0
     8
// Initial Contributors:
sl@0
     9
// Nokia Corporation - initial contribution.
sl@0
    10
//
sl@0
    11
// Contributors:
sl@0
    12
//
sl@0
    13
// Description:
sl@0
    14
// @internalComponent
sl@0
    15
// Open/Close 'A'
sl@0
    16
// 
sl@0
    17
//
sl@0
    18
sl@0
    19
#ifndef TESTCASE_0456_H
sl@0
    20
#define TESTCASE_0456_H
sl@0
    21
sl@0
    22
sl@0
    23
	
sl@0
    24
//----------------------------------------------------------------------------------------------		
sl@0
    25
//!	@SYMTestCaseID				PBASE-T_OTGDI-0456
sl@0
    26
//!	@SYMTestType				UT
sl@0
    27
//!	@SYMPREQ					PREQ1782
sl@0
    28
//!	@SYMREQ						n/a
sl@0
    29
//!	@SYMTestCaseDesc			OTGDI driver session can be repeatedly opened and closed without a) panicking or b) leaking resources.
sl@0
    30
//!	@SYMTestActions 			1. A plug inserted. Call function to open OTGDI driver session.
sl@0
    31
//!								2. Call function to close OTGDI driver session.
sl@0
    32
//!								3. Repeat from step 1 (x 3)
sl@0
    33
//!	@SYMTestExpectedResults 	No panic occurs, no error code returned, we get session handle; session gets closed
sl@0
    34
//!	@SYMTestPriority			High
sl@0
    35
//!	@SYMTestStatus				Implemented
sl@0
    36
//----------------------------------------------------------------------------------------------	
sl@0
    37
	
sl@0
    38
	class CTestCase0456 : public CTestCaseRoot
sl@0
    39
	{
sl@0
    40
public:
sl@0
    41
	static CTestCase0456* NewL(TBool aHost);
sl@0
    42
	virtual ~CTestCase0456(); 	
sl@0
    43
	virtual void ExecuteTestCaseL();
sl@0
    44
	void DoCancel();
sl@0
    45
	void RunStepL();
sl@0
    46
	virtual void DescribePreconditions();
sl@0
    47
sl@0
    48
	TInt GetStepIndex()	{ return(iCaseStep); };
sl@0
    49
	
sl@0
    50
private:
sl@0
    51
	CTestCase0456(TBool aHost);
sl@0
    52
	void ConstructL();
sl@0
    53
sl@0
    54
	
sl@0
    55
private:
sl@0
    56
	enum TCaseSteps
sl@0
    57
		{
sl@0
    58
		EPreconditions,
sl@0
    59
		ELoadLdd,
sl@0
    60
		EUnloadLdd,
sl@0
    61
		ELoopDecrement,
sl@0
    62
		ELastStep	
sl@0
    63
	};
sl@0
    64
	
sl@0
    65
	TCaseSteps iCaseStep;
sl@0
    66
	TInt       iRepeats;		// loop counter, set to run 3 times over
sl@0
    67
	
sl@0
    68
	const static TTestCaseFactoryReceipt<CTestCase0456> iFactoryReceipt;
sl@0
    69
	
sl@0
    70
	};
sl@0
    71
	
sl@0
    72
	
sl@0
    73
#endif // TESTCASE_0456_H