sl@0: // Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies). sl@0: // All rights reserved. sl@0: // This component and the accompanying materials are made available sl@0: // under the terms of the License "Eclipse Public License v1.0" sl@0: // which accompanies this distribution, and is available sl@0: // at the URL "http://www.eclipse.org/legal/epl-v10.html". sl@0: // sl@0: // Initial Contributors: sl@0: // Nokia Corporation - initial contribution. sl@0: // sl@0: // Contributors: sl@0: // sl@0: // Description: sl@0: // f32test\cfileman\t_cfileman.cpp sl@0: // sl@0: // sl@0: sl@0: #define __E32TEST_EXTENSION__ sl@0: #include sl@0: #include sl@0: sl@0: #include "t_cfileman_cases.h" sl@0: sl@0: static RArray gFailedTestCases; sl@0: sl@0: RTest test(_L("T_CFILEMAN")); sl@0: sl@0: /* sl@0: * Prints failure notification for failed test cases during test running period sl@0: */ sl@0: void DoLogTestCaseFailure(const TTestParamAll& aParam) sl@0: { sl@0: const TUint testCaseId = aParam.iTestCaseID; sl@0: test.Printf(_L("Test Failure: Case %d !\n"), testCaseId); sl@0: gFailedTestCases.Append(testCaseId); sl@0: test.Printf(_L("Print out directory contents:\n")); sl@0: PrintDir(aParam.iSrcPrsPath, *aParam.iSrcDrvChar); sl@0: PrintDir(aParam.iSrcCmpPath, *aParam.iSrcDrvChar); sl@0: if (aParam.iAPI == ECFMMove || aParam.iAPI == ECFMRename || aParam.iAPI == ECFMCopy || aParam.iAPI == ECFMCopyHandle) sl@0: { sl@0: PrintDir(aParam.iTrgPrsPath, *aParam.iTrgDrvChar); sl@0: PrintDir(aParam.iTrgCmpPath, *aParam.iTrgDrvChar); sl@0: } sl@0: } sl@0: sl@0: /* sl@0: * Overall test results logging module, prints out the failing test cases with their ID sl@0: */ sl@0: void DoPrintTestResults() sl@0: { sl@0: // if no failure found sl@0: if (gFailedTestCases.Count() == 0) sl@0: { sl@0: test.Printf(_L("All test cases have passed!\n")); sl@0: return; sl@0: } sl@0: sl@0: test.Printf(_L("Test failure(s) found in following case(s):\n")); sl@0: for (TInt i = 0; i < gFailedTestCases.Count(); i++) sl@0: { sl@0: test.Printf(_L("Test Case: %u"), gFailedTestCases[i]); sl@0: } sl@0: test(EFalse); sl@0: } sl@0: sl@0: /* sl@0: * Presetting module, presets initial source, target and comparing direcotries. sl@0: * @param aParam test param that contains all information about a test case sl@0: */ sl@0: void DoPresettings(const TTestParamAll& aParam) sl@0: { sl@0: sl@0: // Setup source files sl@0: TFileName path = aParam.iSrcPrsPath; sl@0: path[0] = (TUint16)*aParam.iSrcDrvChar; sl@0: sl@0: if(path[0] == (TUint8)gDriveToTest || path[0] == (TUint8)gFixedDriveValid) sl@0: { sl@0: SetupDirFiles(path, aParam.iSrcPrsFiles); sl@0: sl@0: // setup source cmp files sl@0: path = aParam.iSrcCmpPath; sl@0: path[0] = (TUint16)*aParam.iSrcDrvChar; sl@0: SetupDirFiles(path, aParam.iSrcCmpFiles); sl@0: } sl@0: sl@0: if (aParam.iAPI == ECFMMove || aParam.iAPI == ECFMRename || aParam.iAPI == ECFMCopy || aParam.iAPI == ECFMCopyHandle) sl@0: { sl@0: // setup trg files sl@0: path = aParam.iTrgPrsPath; sl@0: path[0] = (TUint16)*aParam.iTrgDrvChar; sl@0: sl@0: if(path[0]== (TUint8)gDriveToTest) sl@0: { sl@0: SetupDirFiles(path, aParam.iTrgPrsFiles); sl@0: sl@0: // setup trg cmp files sl@0: path = aParam.iTrgCmpPath; sl@0: path[0] = (TUint16)*aParam.iTrgDrvChar; sl@0: SetupDirFiles(path, aParam.iTrgCmpFiles); sl@0: } sl@0: } sl@0: } sl@0: sl@0: /* sl@0: * Test execution module sl@0: * @param aParam test param that contains all information about a test case sl@0: * @panic USER:84 if return codes do not match the expected values. sl@0: */ sl@0: sl@0: typedef TBuf<350> TTestFileName; sl@0: void DoCmdExecution(const TTestParamAll& aParam) sl@0: { sl@0: TTestFileName srcCmd = aParam.iSrcCmdPath; sl@0: if (srcCmd.Length() > 0) sl@0: { sl@0: srcCmd[0] = (TUint16)*aParam.iSrcDrvChar; sl@0: } sl@0: else sl@0: { sl@0: srcCmd= gSessionPath; sl@0: srcCmd[0] = (TUint16)*aParam.iSrcDrvChar; sl@0: } sl@0: TInt r = KErrNone; sl@0: switch(aParam.iAPI) sl@0: { sl@0: case ECFMDelete: sl@0: if (!gAsynch) sl@0: { sl@0: r = gFileMan->Delete(srcCmd, aParam.iSwitch); sl@0: test_Equal(r, aParam.iSyncReturn); sl@0: } sl@0: else sl@0: { sl@0: r = gFileMan->Delete(srcCmd, aParam.iSwitch, gStat); sl@0: User::WaitForRequest(gStat); sl@0: test_Equal(r , aParam.iAsyncReturn); sl@0: test(gStat == aParam.iAsyncStatus); sl@0: } sl@0: break; sl@0: sl@0: case ECFMRmDir: sl@0: if (!gAsynch) sl@0: { sl@0: r = gFileMan->RmDir(srcCmd); sl@0: test_Equal(r , aParam.iSyncReturn); sl@0: } sl@0: else sl@0: { sl@0: r = gFileMan->RmDir(srcCmd, gStat); sl@0: User::WaitForRequest(gStat); sl@0: test_Equal(r , aParam.iAsyncReturn); sl@0: test(gStat == aParam.iAsyncStatus); sl@0: } sl@0: break; sl@0: case ECFMAttribs: sl@0: if (!gAsynch) sl@0: { sl@0: r = gFileMan->Attribs(srcCmd, aParam.iSetAttribs, aParam.iClearAttribs, aParam.iSetModified, aParam.iSwitch); sl@0: test_Equal(r , aParam.iSyncReturn); sl@0: } sl@0: else sl@0: { sl@0: r = gFileMan->Attribs(srcCmd, aParam.iSetAttribs, aParam.iClearAttribs, aParam.iSetModified, aParam.iSwitch, gStat); sl@0: User::WaitForRequest(gStat); sl@0: test_Equal(r , aParam.iAsyncReturn); sl@0: test(gStat == aParam.iAsyncStatus); sl@0: } sl@0: break; sl@0: case ECFMMove: sl@0: { sl@0: TTestFileName trgCmd = aParam.iTrgCmdPath; sl@0: if (trgCmd.Length() > 0) sl@0: { sl@0: trgCmd[0] = (TUint16)*aParam.iTrgDrvChar; sl@0: } sl@0: else sl@0: { sl@0: trgCmd= gSessionPath; sl@0: } sl@0: if (!gAsynch) sl@0: { sl@0: r = gFileMan->Move(srcCmd, trgCmd, aParam.iSwitch); sl@0: test_Equal(r , aParam.iSyncReturn); sl@0: } sl@0: else sl@0: { sl@0: r = gFileMan->Move(srcCmd, trgCmd, aParam.iSwitch, gStat); sl@0: User::WaitForRequest(gStat); sl@0: test_Equal(r , aParam.iAsyncReturn); sl@0: test(gStat == aParam.iAsyncStatus); sl@0: } sl@0: break; sl@0: } sl@0: case ECFMCopy: sl@0: { sl@0: TTestFileName trgCmd = aParam.iTrgCmdPath; sl@0: if (trgCmd.Length() > 0) sl@0: { sl@0: trgCmd[0] = (TUint16)*aParam.iTrgDrvChar; sl@0: } sl@0: else sl@0: { sl@0: trgCmd= gSessionPath; sl@0: } sl@0: if (!gAsynch) sl@0: { sl@0: r = gFileMan->Copy(srcCmd, trgCmd, aParam.iSwitch); sl@0: test_Equal(r , aParam.iSyncReturn); sl@0: } sl@0: else sl@0: { sl@0: r = gFileMan->Copy(srcCmd, trgCmd,aParam.iSwitch, gStat); sl@0: User::WaitForRequest(gStat); sl@0: test_Equal(r , aParam.iAsyncReturn); sl@0: test(gStat == aParam.iAsyncStatus); sl@0: } sl@0: break; sl@0: } sl@0: case ECFMRename: sl@0: { sl@0: TTestFileName trgCmd = aParam.iTrgCmdPath; sl@0: if (trgCmd.Length() > 0) sl@0: { sl@0: trgCmd[0] = (TUint16)*aParam.iTrgDrvChar; sl@0: } sl@0: else sl@0: { sl@0: trgCmd= gSessionPath; sl@0: } sl@0: if (!gAsynch) sl@0: { sl@0: r = gFileMan->Rename(srcCmd, trgCmd, aParam.iSwitch); sl@0: test_Equal(r , aParam.iSyncReturn); sl@0: } sl@0: else sl@0: { sl@0: r = gFileMan->Rename(srcCmd, trgCmd, aParam.iSwitch, gStat); sl@0: User::WaitForRequest(gStat); sl@0: test_Equal(r , aParam.iAsyncReturn); sl@0: test(gStat == aParam.iAsyncStatus); sl@0: } sl@0: break; sl@0: } sl@0: case ECFMCopyHandle: sl@0: { sl@0: TTestFileName trgCmd = aParam.iTrgCmdPath; sl@0: if (trgCmd.Length() > 0) sl@0: { sl@0: trgCmd[0] = (TUint16)*aParam.iTrgDrvChar; sl@0: } sl@0: else sl@0: { sl@0: trgCmd= gSessionPath; sl@0: } sl@0: sl@0: if (!gAsynch) sl@0: { sl@0: RFile tryfile; sl@0: TInt ret = 0; sl@0: ret = tryfile.Open(TheFs, srcCmd, EFileRead|EFileWrite); sl@0: test_Equal(ret , KErrNone); sl@0: r = gFileMan->Copy(tryfile, trgCmd, aParam.iSwitch); sl@0: test_Equal(r , aParam.iSyncReturn); sl@0: tryfile.Close(); sl@0: } sl@0: else sl@0: { sl@0: RFile tryfile; sl@0: TInt ret = 0; sl@0: ret = tryfile.Open(TheFs, srcCmd, EFileRead|EFileWrite); sl@0: test(ret == KErrNone); sl@0: r = gFileMan->Copy(tryfile, trgCmd, aParam.iSwitch, gStat); sl@0: User::WaitForRequest(gStat); sl@0: test_Equal(r , aParam.iAsyncReturn); sl@0: test(gStat == aParam.iAsyncStatus); sl@0: tryfile.Close(); sl@0: } sl@0: } sl@0: default: sl@0: break; sl@0: sl@0: } sl@0: sl@0: } sl@0: sl@0: /* sl@0: * Result verification module. sl@0: * @param aParam test param that contains all information about a test case sl@0: * @return ETrue if test results in expected behaviour, i.e. test passes sl@0: * EFalse if test results in unexpected behaviour, i.e. test fails sl@0: */ sl@0: TBool DoResultsVerification(const TTestParamAll& aParam) sl@0: { sl@0: TFileName srcPath = aParam.iSrcPrsPath; sl@0: srcPath[0] = (TUint16)*aParam.iSrcDrvChar; sl@0: TFileName srcCmpPath = aParam.iSrcCmpPath; sl@0: srcCmpPath[0] = (TUint16)*aParam.iSrcDrvChar; sl@0: sl@0: if ((*aParam.iSrcDrvChar == gDriveToTest)) sl@0: { sl@0: TBool rel = CompareL(srcPath, srcCmpPath); sl@0: if(!rel) sl@0: return EFalse; sl@0: } sl@0: sl@0: if (aParam.iAPI == ECFMMove || aParam.iAPI == ECFMRename || aParam.iAPI == ECFMCopy || aParam.iAPI == ECFMCopyHandle) sl@0: { sl@0: TFileName trgPath = aParam.iTrgPrsPath; sl@0: trgPath[0] = (TUint16)*aParam.iTrgDrvChar; sl@0: TFileName trgCmpPath = aParam.iTrgCmpPath; sl@0: trgCmpPath[0] = (TUint16)*aParam.iTrgDrvChar; sl@0: if ((*aParam.iTrgDrvChar == gDriveToTest)) sl@0: { sl@0: TBool rel = CompareL(trgPath, trgCmpPath); sl@0: if(!rel) sl@0: return rel; sl@0: } sl@0: sl@0: } sl@0: return ETrue; sl@0: } sl@0: sl@0: /* sl@0: * Search test cases by the index of the array of test case group, overloaded version for basic unitary cases. sl@0: * @param aIdx the test case index in search sl@0: * @param aBasicUnitaryTestCaseGroup the input test group, should always be gBasicUnitaryTestCases[] sl@0: * @param aTestCaseFound contains params of the test case found by the test case Id. sl@0: * @return KErrNone if only one test case on the id is found sl@0: * KErrNotFound if no test case is found sl@0: */ sl@0: TInt SearchTestCaseByArrayIdx(TUint aIdx, const TTestCaseUnitaryBasic aBasicUnitaryTestCaseGroup[], TTestParamAll& aTestCaseFound) sl@0: { sl@0: if (aBasicUnitaryTestCaseGroup[aIdx].iBasic.iTestCaseID != 0) sl@0: { sl@0: aTestCaseFound.iTestCaseID = aBasicUnitaryTestCaseGroup[aIdx].iBasic.iTestCaseID; sl@0: aTestCaseFound.iAPI = aBasicUnitaryTestCaseGroup[aIdx].iBasic.iAPI; sl@0: aTestCaseFound.iSwitch = aBasicUnitaryTestCaseGroup[aIdx].iBasic.iSwitch; sl@0: aTestCaseFound.iSyncReturn = aBasicUnitaryTestCaseGroup[aIdx].iBasic.iSyncReturn; sl@0: aTestCaseFound.iAsyncReturn = aBasicUnitaryTestCaseGroup[aIdx].iBasic.iAsyncReturn; sl@0: aTestCaseFound.iAsyncStatus = aBasicUnitaryTestCaseGroup[aIdx].iBasic.iAsyncStatus; sl@0: sl@0: aTestCaseFound.iSrcDrvChar = aBasicUnitaryTestCaseGroup[aIdx].iSrcPrsBasic.iDrvChar; sl@0: aTestCaseFound.iSrcCmdPath.Set(aBasicUnitaryTestCaseGroup[aIdx].iSrcPrsBasic.iCmdPath); sl@0: aTestCaseFound.iSrcPrsPath.Set(aBasicUnitaryTestCaseGroup[aIdx].iSrcPrsBasic.iPrsPath); sl@0: aTestCaseFound.iSrcPrsFiles = aBasicUnitaryTestCaseGroup[aIdx].iSrcPrsBasic.iPrsFiles; sl@0: aTestCaseFound.iSrcCmpPath.Set(aBasicUnitaryTestCaseGroup[aIdx].iSrcPrsBasic.iCmpPath); sl@0: aTestCaseFound.iSrcCmpFiles = aBasicUnitaryTestCaseGroup[aIdx].iSrcPrsBasic.iCmpFiles; sl@0: } sl@0: else sl@0: return KErrNotFound; sl@0: return KErrNone; sl@0: sl@0: } sl@0: sl@0: /* sl@0: * Search test cases by the index of the array of test case group, overloaded version for basic binary cases. sl@0: * @param aIdx the test case index in search sl@0: * @param aBasicUnitaryTestCaseGroup the input test group, should always be gBasicBinaryTestCases[] sl@0: * @param aTestCaseFound contains params of the test case found by the test case Id. sl@0: * @return KErrNone if only one test case on the id is found sl@0: * KErrNotFound if no test case is found sl@0: */ sl@0: TInt SearchTestCaseByArrayIdx(TUint aIdx, const TTestCaseBinaryBasic aBasicBinaryTestCaseGroup[], TTestParamAll& aTestCaseFound) sl@0: { sl@0: if (aBasicBinaryTestCaseGroup[aIdx].iBasic.iTestCaseID != 0) sl@0: { sl@0: aTestCaseFound.iTestCaseID = aBasicBinaryTestCaseGroup[aIdx].iBasic.iTestCaseID; sl@0: aTestCaseFound.iAPI = aBasicBinaryTestCaseGroup[aIdx].iBasic.iAPI; sl@0: aTestCaseFound.iSwitch = aBasicBinaryTestCaseGroup[aIdx].iBasic.iSwitch; sl@0: aTestCaseFound.iSyncReturn = aBasicBinaryTestCaseGroup[aIdx].iBasic.iSyncReturn; sl@0: aTestCaseFound.iAsyncReturn = aBasicBinaryTestCaseGroup[aIdx].iBasic.iAsyncReturn; sl@0: aTestCaseFound.iAsyncStatus = aBasicBinaryTestCaseGroup[aIdx].iBasic.iAsyncStatus; sl@0: sl@0: aTestCaseFound.iSrcDrvChar = aBasicBinaryTestCaseGroup[aIdx].iSrcPrsBasic.iDrvChar; sl@0: aTestCaseFound.iSrcCmdPath.Set(aBasicBinaryTestCaseGroup[aIdx].iSrcPrsBasic.iCmdPath); sl@0: aTestCaseFound.iSrcPrsPath.Set(aBasicBinaryTestCaseGroup[aIdx].iSrcPrsBasic.iPrsPath); sl@0: aTestCaseFound.iSrcPrsFiles = aBasicBinaryTestCaseGroup[aIdx].iSrcPrsBasic.iPrsFiles; sl@0: aTestCaseFound.iSrcCmpPath.Set(aBasicBinaryTestCaseGroup[aIdx].iSrcPrsBasic.iCmpPath); sl@0: aTestCaseFound.iSrcCmpFiles = aBasicBinaryTestCaseGroup[aIdx].iSrcPrsBasic.iCmpFiles; sl@0: sl@0: aTestCaseFound.iTrgDrvChar = aBasicBinaryTestCaseGroup[aIdx].iTrgPrsBasic.iDrvChar; sl@0: aTestCaseFound.iTrgCmdPath.Set(aBasicBinaryTestCaseGroup[aIdx].iTrgPrsBasic.iCmdPath); sl@0: aTestCaseFound.iTrgPrsPath.Set(aBasicBinaryTestCaseGroup[aIdx].iTrgPrsBasic.iPrsPath); sl@0: aTestCaseFound.iTrgPrsFiles = aBasicBinaryTestCaseGroup[aIdx].iTrgPrsBasic.iPrsFiles; sl@0: aTestCaseFound.iTrgCmpPath.Set(aBasicBinaryTestCaseGroup[aIdx].iTrgPrsBasic.iCmpPath); sl@0: aTestCaseFound.iTrgCmpFiles = aBasicBinaryTestCaseGroup[aIdx].iTrgPrsBasic.iCmpFiles; sl@0: } sl@0: else sl@0: { sl@0: return KErrNotFound; sl@0: } sl@0: return KErrNone; sl@0: } sl@0: sl@0: /* sl@0: * Search test cases by test case Id, overloaded version for Basic unitary cases. sl@0: * @param aCaseId the test case Id in search sl@0: * @param aBasicUnitaryTestCaseGroup the input test group, should always be gBasicUnitaryTestCases[] sl@0: * @param aTestCaseFound contains params of the test case found by the test case Id. sl@0: * @return KErrNone if only one test case on the id is found sl@0: * KErrAlreadyExists if more than one test cases found by the test case Id sl@0: * KErrNotFound if no test case is found sl@0: */ sl@0: TInt SearchTestCaseByTestCaseId(TUint aCaseId, const TTestCaseUnitaryBasic aBasicUnitaryTestCaseGroup[], TTestParamAll& aTestCaseFound) sl@0: { sl@0: TBool found = EFalse; sl@0: TInt rel = KErrNone; sl@0: sl@0: // Scan through the test group by array index sl@0: for(TInt i = 0; rel == KErrNone; i++) sl@0: { sl@0: rel = SearchTestCaseByArrayIdx(i, aBasicUnitaryTestCaseGroup, aTestCaseFound); sl@0: if(aTestCaseFound.iTestCaseID == aCaseId) sl@0: { sl@0: // If more than one test cases found, return error sl@0: if(found) sl@0: { sl@0: return KErrAlreadyExists; sl@0: } sl@0: found = ETrue; sl@0: } sl@0: } sl@0: sl@0: if (!found) sl@0: { sl@0: return KErrNotFound; sl@0: } sl@0: return KErrNone; sl@0: } sl@0: sl@0: /* sl@0: * Do all basic binary test cases defined in gBasicUnitaryTestCases[] sl@0: */ sl@0: void DoAllBasicUnitaryTests(const TTestCaseUnitaryBasic aBasicUnitaryTestCaseGroup[]) sl@0: { sl@0: TTestParamAll nextTestCase; sl@0: TInt i = 0; sl@0: sl@0: while (SearchTestCaseByArrayIdx(i, aBasicUnitaryTestCaseGroup, nextTestCase) == KErrNone) sl@0: { sl@0: TTime startTime; sl@0: TTime endTime; sl@0: startTime.HomeTime(); sl@0: DoPresettings(nextTestCase); sl@0: DoCmdExecution(nextTestCase); sl@0: if (!DoResultsVerification(nextTestCase)) sl@0: { sl@0: DoLogTestCaseFailure(nextTestCase); sl@0: } sl@0: else sl@0: { sl@0: test.Printf(_L("Test ID %d passed \n"),nextTestCase.iTestCaseID); sl@0: } sl@0: endTime.HomeTime(); sl@0: TTimeIntervalMicroSeconds timeTaken(0); sl@0: timeTaken = endTime.MicroSecondsFrom(startTime); sl@0: TInt time2=0; sl@0: time2=I64LOW(timeTaken.Int64()/1000); sl@0: test.Printf(_L("Time Taken by testid %d = %d mS \n"),nextTestCase.iTestCaseID,time2); sl@0: ++i; sl@0: sl@0: } sl@0: } sl@0: sl@0: /* sl@0: * Do all basic binary test cases defined in gBasicBinaryTestCases[] sl@0: */ sl@0: void DoAllBasicBinaryTests(const TTestCaseBinaryBasic aBasicBinaryTestCaseGroup[]) sl@0: { sl@0: TTestParamAll nextTestCase; sl@0: TInt i = 0; sl@0: while (SearchTestCaseByArrayIdx(i, aBasicBinaryTestCaseGroup, nextTestCase) == KErrNone) sl@0: { sl@0: TTime startTime; sl@0: TTime endTime; sl@0: startTime.HomeTime(); sl@0: DoPresettings(nextTestCase); sl@0: DoCmdExecution(nextTestCase); sl@0: if (!DoResultsVerification(nextTestCase)) sl@0: { sl@0: DoLogTestCaseFailure(nextTestCase); sl@0: } sl@0: else sl@0: { sl@0: test.Printf(_L("Test ID %d passed \n"),nextTestCase.iTestCaseID); sl@0: } sl@0: endTime.HomeTime(); sl@0: TTimeIntervalMicroSeconds timeTaken(0); sl@0: timeTaken = endTime.MicroSecondsFrom(startTime); sl@0: sl@0: TInt time2=0; sl@0: time2=I64LOW(timeTaken.Int64()/1000); sl@0: test.Printf(_L("Time Taken by test id %d = %d mS \n"),nextTestCase.iTestCaseID,time2); sl@0: ++i; sl@0: } sl@0: } sl@0: sl@0: // Future work: provide command arguement parsing faclity so that users sl@0: // can choose specific test case(s) in ranges sl@0: // can choose specific API(s), switches, configurations, etc. for testing sl@0: /* sl@0: * Main testing control unit sl@0: */ sl@0: void TestMain() sl@0: { sl@0: //The __PERFTEST__ macro is for future use when a tests are setup to run on a performance machine sl@0: //which will be enabled to run for both WINSCW and ARMV5 sl@0: #ifndef __PERFTEST__ sl@0: //Tests are enabled to run for WINSCW only on the below specified drives due to the time constraint. sl@0: if((gDriveToTest == 'C') || (gDriveToTest == 'X') || (gDriveToTest == 'Y')) sl@0: { sl@0: DoAllBasicUnitaryTests(gBasicUnitaryTestCases); sl@0: DoAllBasicBinaryTests(gBasicBinaryTestCases); sl@0: } sl@0: else sl@0: { sl@0: test.Printf(_L("Drive %C: is not supported for this configuration, see test logs for supported configuration details"),gDriveToTest); sl@0: } sl@0: #endif sl@0: sl@0: #ifdef __PERFTEST__ sl@0: DoAllBasicUnitaryTests(gBasicUnitaryTestCases); sl@0: DoAllBasicBinaryTests(gBasicBinaryTestCases); sl@0: #endif sl@0: } sl@0: sl@0: sl@0: /* sl@0: * Initialise test, do all tests in both sync and async mode. sl@0: */ sl@0: void CallTestsL() sl@0: { sl@0: InitialiseL(); sl@0: sl@0: CreateTestDirectory(_L("\\F32-TST\\T_CFILEMAN\\")); sl@0: sl@0: gAsynch=EFalse; sl@0: test.Next(_L("Synchronous tests ...")); sl@0: TestMain(); sl@0: sl@0: DeleteTestDirectory(); sl@0: sl@0: CreateTestDirectory(_L("\\F32-TST\\T_CFILEMAN\\")); sl@0: gAsynch=ETrue; sl@0: test.Next(_L("Asynchronous tests ...")); sl@0: TestMain(); sl@0: sl@0: DoPrintTestResults(); sl@0: Cleanup(); sl@0: DeleteTestDirectory(); sl@0: }