kerneltest/e32test/usbho/t_otgdi/src/testpolicy.cpp
branchRCL_3
changeset 257 3e88ff8f41d5
parent 256 c1f20ce4abcf
equal deleted inserted replaced
256:c1f20ce4abcf 257:3e88ff8f41d5
     1 // Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies).
     1 // Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
     2 // All rights reserved.
     2 // All rights reserved.
     3 // This component and the accompanying materials are made available
     3 // This component and the accompanying materials are made available
     4 // under the terms of the License "Eclipse Public License v1.0"
     4 // under the terms of the License "Eclipse Public License v1.0"
     5 // which accompanies this distribution, and is available
     5 // which accompanies this distribution, and is available
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
    24 #include <e32cons.h>
    24 #include <e32cons.h>
    25 #include <e32Test.h>	// RTest headder
    25 #include <e32Test.h>	// RTest headder
    26 #include "testcaseroot.h"
    26 #include "testcaseroot.h"
    27 #include "testpolicy.h"
    27 #include "testpolicy.h"
    28 #include "testcasefactory.h"
    28 #include "testcasefactory.h"
    29 #include "OstTraceDefinitions.h"
       
    30 #ifdef OST_TRACE_COMPILER_IN_USE
       
    31 #include "testpolicyTraces.h"
       
    32 #endif
       
    33 
    29 
    34 
    30 
    35 
    31 
    36 
    32 
    37 CBasicTestPolicy* CBasicTestPolicy::NewL()
    33 CBasicTestPolicy* CBasicTestPolicy::NewL()
    51 	}
    47 	}
    52 
    48 
    53 		
    49 		
    54 void CBasicTestPolicy::ConstructL()
    50 void CBasicTestPolicy::ConstructL()
    55 	{
    51 	{
    56 	if(gVerboseOutput)
    52 	LOG_FUNC
    57 	    {
       
    58 	    OstTraceFunctionEntry0(CBASICTESTPOLICY_CONSTRUCTL);
       
    59 	    }
       
    60 
    53 
    61 	}
    54 	}
    62 	
    55 	
    63 
    56 
    64 CBasicTestPolicy::~CBasicTestPolicy()
    57 CBasicTestPolicy::~CBasicTestPolicy()
    75  the test-case may be stored in this class in future for access on ad-hoc basis as each test 
    68  the test-case may be stored in this class in future for access on ad-hoc basis as each test 
    76  case desires, without a need to modify all test cases
    69  case desires, without a need to modify all test cases
    77  */
    70  */
    78 void CBasicTestPolicy::RunTestCaseL(const TDesC& aTestCaseId, TRequestStatus* aNotifierStatus)
    71 void CBasicTestPolicy::RunTestCaseL(const TDesC& aTestCaseId, TRequestStatus* aNotifierStatus)
    79 	{
    72 	{
    80 	if(gVerboseOutput)
    73 	LOG_FUNC
    81 	    {
       
    82 	    OstTraceFunctionEntry0(CBASICTESTPOLICY_RUNTESTCASEL);
       
    83 	    }
       
    84 	iNotifierStatus = aNotifierStatus;
    74 	iNotifierStatus = aNotifierStatus;
    85 	// delete previous test run
    75 	// delete previous test run
    86 	if (iTestCase)
    76 	if (iTestCase)
    87 		{
    77 		{
    88 		delete iTestCase;
    78 		delete iTestCase;
   130 	}
   120 	}
   131 
   121 
   132 	
   122 	
   133 void CBasicTestPolicy::RunL()
   123 void CBasicTestPolicy::RunL()
   134 	{ 
   124 	{ 
   135 	if(gVerboseOutput)
   125 	LOG_FUNC
   136 	    {
       
   137 	    OstTraceFunctionEntry0(CBASICTESTPOLICY_RUNL);
       
   138 	    }
       
   139 	
   126 	
   140 	}
   127 	}
   141 
   128 
   142 
   129 
   143 TInt CBasicTestPolicy::RunError(TInt /*aError*/)
   130 TInt CBasicTestPolicy::RunError(TInt /*aError*/)