diff -r c1f20ce4abcf -r 3e88ff8f41d5 kerneltest/e32test/usbho/t_otgdi/src/testcase0466.cpp --- a/kerneltest/e32test/usbho/t_otgdi/src/testcase0466.cpp Tue Aug 31 16:34:26 2010 +0300 +++ b/kerneltest/e32test/usbho/t_otgdi/src/testcase0466.cpp Wed Sep 01 12:34:56 2010 +0100 @@ -1,4 +1,4 @@ -// Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies). +// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies). // All rights reserved. // This component and the accompanying materials are made available // under the terms of the License "Eclipse Public License v1.0" @@ -24,10 +24,6 @@ #include "testcaseroot.h" #include "testcasewd.h" #include "testcase0466.h" -#include "OstTraceDefinitions.h" -#ifdef OST_TRACE_COMPILER_IN_USE -#include "testcase0466Traces.h" -#endif @@ -38,10 +34,7 @@ CTestCase0466* CTestCase0466::NewL(TBool aHost) { - if(gVerboseOutput) - { - OstTraceFunctionEntry0(CTESTCASE0466_NEWL); - } + LOG_FUNC CTestCase0466* self = new (ELeave) CTestCase0466(aHost); CleanupStack::PushL(self); self->ConstructL(); @@ -53,10 +46,7 @@ CTestCase0466::CTestCase0466(TBool aHost) : CTestCaseRoot(KTestCaseId, aHost) { - if(gVerboseOutput) - { - OstTraceFunctionEntry0(CTESTCASE0466_CTESTCASE0466); - } + LOG_FUNC } @@ -66,10 +56,7 @@ */ void CTestCase0466::ConstructL() { - if(gVerboseOutput) - { - OstTraceFunctionEntry0(CTESTCASE0466_CONSTRUCTL); - } + LOG_FUNC iWDTimer = CTestCaseWatchdog::NewL(); BaseConstructL(); @@ -78,10 +65,7 @@ CTestCase0466::~CTestCase0466() { - if(gVerboseOutput) - { - OstTraceFunctionEntry0(CTESTCASE0466_DCTESTCASE0466); - } + LOG_FUNC Cancel(); delete iWDTimer; @@ -90,10 +74,7 @@ void CTestCase0466::ExecuteTestCaseL() { - if(gVerboseOutput) - { - OstTraceFunctionEntry0(CTESTCASE0466_EXECUTETESTCASEL); - } + LOG_FUNC iCaseStep = EPreconditions; iRepeats = KOperationRetriesMax; @@ -107,38 +88,23 @@ void CTestCase0466::DescribePreconditions() { test.Printf(_L("BEFORE running this test\n")); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_DESCRIBEPRECONDITIONS, "BEFORE running this test\n"); test.Printf(_L("\n")); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_DESCRIBEPRECONDITIONS_DUP01, "\n"); test.Printf(_L("Insert the connector\n")); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_DESCRIBEPRECONDITIONS_DUP02, "Insert the connector\n"); test.Printf(_L("from the OET with SW9\n")); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_DESCRIBEPRECONDITIONS_DUP03, "from the OET with SW9\n"); test.Printf(_L("set to 'A-DEVICE' and\n")); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_DESCRIBEPRECONDITIONS_DUP04, "set to 'A-DEVICE' and\n"); test.Printf(_L("all other switches OFF\n")); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_DESCRIBEPRECONDITIONS_DUP05, "all other switches OFF\n"); test.Printf(_L("\n")); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_DESCRIBEPRECONDITIONS_DUP06, "\n"); test.Printf(_L("Confirm passing tests\n")); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_DESCRIBEPRECONDITIONS_DUP07, "Confirm passing tests\n"); test.Printf(_L("\n")); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_DESCRIBEPRECONDITIONS_DUP08, "\n"); test.Printf(_L("ID_PIN detection\n")); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_DESCRIBEPRECONDITIONS_DUP09, "ID_PIN detection\n"); test.Printf(_L("VBus Driving\n")); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_DESCRIBEPRECONDITIONS_DUP10, "VBus Driving\n"); test.Printf(_L("\n")); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_DESCRIBEPRECONDITIONS_DUP11, "\n"); } void CTestCase0466::DoCancel() { - if(gVerboseOutput) - { - OstTraceFunctionEntry0(CTESTCASE0466_DOCANCEL); - } + LOG_FUNC // cancel our timer iTimer.Cancel(); @@ -157,10 +123,7 @@ // handle event completion void CTestCase0466::RunStepL() { - if(gVerboseOutput) - { - OstTraceFunctionEntry0(CTESTCASE0466_RUNSTEPL); - } + LOG_FUNC // Obtain the completion code for this CActive obj. TInt completionCode(iStatus.Int()); TBuf aDescription; @@ -178,15 +141,10 @@ } // prompt to insert connector test.Printf(_L("\n")); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_RUNSTEPL_DUP01, "\n"); test.Printf(KInsertAConnectorPrompt); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_RUNSTEPL_DUP02, KInsertAConnectorPrompt); test.Printf(_L("\n")); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_RUNSTEPL_DUP03, "\n"); test.Printf(KPressAnyKeyToContinue); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_RUNSTEPL_DUP04, KPressAnyKeyToContinue); test.Printf(_L("\n")); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_RUNSTEPL_DUP05, "\n"); RequestCharacter(); break; @@ -224,17 +182,11 @@ // ...and tell user to apply load test.Printf(_L("\n")); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_RUNSTEPL_DUP06, "\n"); test.Printf(_L("************************\n")); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_RUNSTEPL_DUP07, "************************\n"); test.Printf(_L("* Using SW4 on the OET *\n")); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_RUNSTEPL_DUP08, "* Using SW4 on the OET *\n"); test.Printf(_L("* Apply 100mA LOAD now *\n")); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_RUNSTEPL_DUP09, "* Apply 100mA LOAD now *\n"); test.Printf(_L("************************\n")); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_RUNSTEPL_DUP10, "************************\n"); test.Printf(_L("\n")); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_RUNSTEPL_DUP11, "\n"); iCaseStep = EVerifyBusFail; @@ -244,7 +196,6 @@ OtgMessageString(iOTGMessage, aDescription); test.Printf(_L("Received message %d '%S' status(%d)\n"), iOTGMessage, &aDescription, completionCode); - OstTraceExt3(TRACE_NORMAL, CTESTCASE0466_RUNSTEPL_DUP12, "Received message %d '%S' status(%d)\n", iOTGMessage, aDescription, completionCode); if (RUsbOtgDriver::EMessageVbusError == iOTGMessage) { @@ -283,22 +234,15 @@ // remove 100ma Load - this reminds the user test.Printf(_L("\n")); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_RUNSTEPL_DUP13, "\n"); test.Printf(_L("************************\n")); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_RUNSTEPL_DUP14, "************************\n"); test.Printf(_L("* Using SW4 on the OET *\n")); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_RUNSTEPL_DUP15, "* Using SW4 on the OET *\n"); test.Printf(_L("* Remove 100mA LOAD! *\n")); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_RUNSTEPL_DUP16, "* Remove 100mA LOAD! *\n"); test.Printf(_L("************************\n")); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_RUNSTEPL_DUP17, "************************\n"); test.Printf(_L("\n")); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_RUNSTEPL_DUP18, "\n"); iCaseStep = ELastStep; // press any key test.Printf(KPressAnyKeyToContinue); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_RUNSTEPL_DUP19, KPressAnyKeyToContinue); RequestCharacter(); break; @@ -307,7 +251,6 @@ default: test.Printf(_L(" unknown test step")); - OstTrace0(TRACE_NORMAL, CTESTCASE0466_RUNSTEPL_DUP20, " unknown test step"); Cancel(); return (TestFailed(KErrCorrupt, _L(" unknown test step")));