sl@0: // Copyright (c) 2003-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 "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: // sl@0: sl@0: // TSU_MMF_ACOD_BASE.CPP sl@0: // sl@0: // Copyright (c) 2003 Symbian Ltd. All rights reserved. sl@0: // sl@0: sl@0: // EPOC includes sl@0: #include sl@0: sl@0: // Test system includes sl@0: #include "TSU_MMF_ACOD.h" sl@0: #include "TSU_MMF_devicesuite.h" sl@0: sl@0: #include sl@0: #include sl@0: #include sl@0: sl@0: #ifdef __WINS__ sl@0: //wins directories sl@0: _LIT(KSourceFilesDir, "c:\\mm\\mmf\\testfiles\\acod\\"); sl@0: _LIT(KComparisonFilesDir, "c:\\mm\\mmf\\ref\\acod\\"); sl@0: #else sl@0: /* sl@0: arm4 directories sl@0: All source and comparison files need to be copied manually onto the flash card. sl@0: This code assumes the flash card is represented by drive E: on the target board. sl@0: If this is not the case, the KSourceFilesDir and KComparisonFilesDir strings sl@0: need to be changed accordingly. sl@0: */ sl@0: _LIT(KSourceFilesDir, "e:\\"); sl@0: _LIT(KComparisonFilesDir, "e:\\"); sl@0: #endif sl@0: sl@0: //------------------------------------------------------------------ sl@0: // ** TEST MMF_ACOD STEPS *** sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0001::CTest_MMF_ACOD_U_0001() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0001-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * Instantiate a codec by FourCC Codes and preferred supplier sl@0: * @test Req. under test REQ172.6.3 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0001::DoTestStepL() sl@0: { sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestNewLPreferredSupplierL()); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0002::CTest_MMF_ACOD_U_0002() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0002-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * ALAW To PCM16 Instantiate codec by FourCC Codes sl@0: * @test Req. under test REQ172.6.2, REQ172.11.1 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0002::DoTestStepL() sl@0: { sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(KMMFFourCCCodeALAW, KMMFFourCCCodePCM16)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0003::CTest_MMF_ACOD_U_0003() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0003-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * ALAW To PCM16 Instantiate codec by UID sl@0: * @test Req. under test REQ172.6.1, REQ172.11.1 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0003::DoTestStepL() sl@0: { sl@0: /* const TUid codecUid = {KMmfUidHwDeviceAlawToPCM16}; sl@0: TBool testOK = EFalse; sl@0: TRAPD(err, testOK = TestNewL(codecUid)); sl@0: TInt err = KErrNone; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: */ sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0004::CTest_MMF_ACOD_U_0004() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0004-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 50; sl@0: iExpectedDstBytesAdded[i] = 100; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * ALAW To PCM16 Pass in small source buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0004::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceAlawToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KSmallBufferSize, KAlawToPCM16OptimumDst)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0005::CTest_MMF_ACOD_U_0005() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0005-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 25; sl@0: iExpectedDstBytesAdded[i] = 50; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * ALAW To PCM16 Pass in small dest buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0005::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceAlawToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KAlawToPCM16OptimumSrc, KSmallBufferSize)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0006::CTest_MMF_ACOD_U_0006() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0006-HP"); sl@0: iHeapSize = 0x20000; sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 5000; sl@0: iExpectedDstBytesAdded[i] = 10000; sl@0: sl@0: if((i%2)==0)//even i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: else //odd i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * ALAW To PCM16 Pass in large buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0006::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceAlawToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KLargeBufferSize, KLargeBufferSize)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0007::CTest_MMF_ACOD_U_0007() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0007-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x800; sl@0: iExpectedDstBytesAdded[i] = 0x1000; sl@0: sl@0: if((i%2)==0)//even i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: else //odd i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * ALAW To PCM16 Pass in default sized buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0007::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceAlawToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KDefaultBufferSize, KDefaultBufferSize)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0008::CTest_MMF_ACOD_U_0008() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0008-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x800; sl@0: iExpectedDstBytesAdded[i] = 0x1000; sl@0: sl@0: if((i%2)==0)//even i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: else //odd i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * ALAW To PCM16 Pass in buffers with different max length and length sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0008::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceAlawToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KMaxBufferLength, KDefaultBufferSize, KDefaultBufferSize)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0009::CTest_MMF_ACOD_U_0009() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0009-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x800; sl@0: iExpectedDstBytesAdded[i] = 0x1000; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * ALAW To PCM16 Pass in buffers of optimum size sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0009::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceAlawToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KAlawToPCM16OptimumSrc, KAlawToPCM16OptimumDst)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0010::CTest_MMF_ACOD_U_0010() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0010-HP"); sl@0: // iHeapSize = 0x20000; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * ALAW To PCM16 Reposition source pointer during conversion sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0010::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceAlawToPCM16}; sl@0: TBool testOK = EFalse; sl@0: INFO_PRINTF1(_L(">> The ALAW to PCM16 codec doesn't currently store data between calls to ProcessL")); sl@0: sl@0: // TRAPD(err, testOK = TestRepositionL(codecUid, KAlawToPCM16OptimumSrc, KAlawToPCM16OptimumDst+30)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0011::CTest_MMF_ACOD_U_0011() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0011-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To ALAW Instantiate codec by FourCC Codes sl@0: * @test Req. under test REQ172.6.2, REQ172.11.3 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0011::DoTestStepL() sl@0: { sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(KMMFFourCCCodePCM16, KMMFFourCCCodeALAW)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0012::CTest_MMF_ACOD_U_0012() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0012-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To ALAW Instantiate codec by UID sl@0: * @test Req. under test REQ172.6.1, REQ172.11.3 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0012::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToALaw}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(codecUid)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0013::CTest_MMF_ACOD_U_0013() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0013-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 50; sl@0: iExpectedDstBytesAdded[i] = 25; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To ALAW Pass in small source buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0013::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToALaw}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KSmallBufferSize, KPCM16ToAlawOptimumDst)); sl@0: TInt err = KErrNone ; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0014::CTest_MMF_ACOD_U_0014() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0014-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 100; sl@0: iExpectedDstBytesAdded[i] = 50; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To ALAW Pass in small dest buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0014::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToALaw}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToAlawOptimumSrc, KSmallBufferSize)); sl@0: TInt err = KErrNone ; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0015::CTest_MMF_ACOD_U_0015() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0015-HP"); sl@0: iHeapSize = 0x20000; sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 10000; sl@0: iExpectedDstBytesAdded[i] = 5000; sl@0: sl@0: if((i%2)==0)//even i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: else //odd i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To ALAW Pass in large buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0015::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToALaw}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KLargeBufferSize, KLargeBufferSize)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0016::CTest_MMF_ACOD_U_0016() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0016-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x1000; sl@0: iExpectedDstBytesAdded[i] = 0x800; sl@0: sl@0: if((i%2)==0)//even i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: else //odd i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To ALAW Pass in default sized buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0016::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToALaw}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KDefaultBufferSize, KDefaultBufferSize)); sl@0: TInt err = KErrNone ; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0017::CTest_MMF_ACOD_U_0017() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0017-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x1000; sl@0: iExpectedDstBytesAdded[i] = 0x800; sl@0: sl@0: if((i%2)==0)//even i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: else //odd i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To ALAW Pass in buffers with different max length and length sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0017::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToALaw}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KMaxBufferLength, KDefaultBufferSize, KDefaultBufferSize)); sl@0: TInt err = KErrNone ; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0018::CTest_MMF_ACOD_U_0018() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0018-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x1000; sl@0: iExpectedDstBytesAdded[i] = 0x800; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To ALAW Pass in buffers of optimum size sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0018::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToALaw}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToAlawOptimumSrc, KPCM16ToAlawOptimumDst)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0019::CTest_MMF_ACOD_U_0019() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0019-HP"); sl@0: // iHeapSize = 0x20000; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To ALAW Reposition source pointer during conversion sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0019::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToALaw}; sl@0: TBool testOK = EFalse; sl@0: sl@0: INFO_PRINTF1(_L(">> The PCM16 to ALAW codec doesn't currently store data between calls to ProcessL")); sl@0: // TRAPD(err, testOK = TestRepositionL(codecUid, KDefaultBufferSize, KDefaultBufferSize+30)); sl@0: TInt err= KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0020::CTest_MMF_ACOD_U_0020() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0020-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM8 To PCM16 Instantiate codec by FourCC Codes sl@0: * @test Req. under test REQ172.6.2, REQ172.11.4 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0020::DoTestStepL() sl@0: { sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(KMMFFourCCCodePCM8, KMMFFourCCCodePCM16)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0021::CTest_MMF_ACOD_U_0021() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0021-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM8 To PCM16 Instantiate codec by UID sl@0: * @test Req. under test REQ172.6.1, REQ172.11.4 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0021::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM8ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(codecUid)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0022::CTest_MMF_ACOD_U_0022() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0022-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 50; sl@0: iExpectedDstBytesAdded[i] = 100; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM8 To PCM16 Pass in small source buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0022::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM8ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KSmallBufferSize, KPCM8ToPCM16OptimumDst)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0023::CTest_MMF_ACOD_U_0023() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0023-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 25; sl@0: iExpectedDstBytesAdded[i] = 50; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM8 To PCM16 Pass in small dest buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0023::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDevicePCM8ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM8ToPCM16OptimumSrc, KSmallBufferSize)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0024::CTest_MMF_ACOD_U_0024() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0024-HP"); sl@0: iHeapSize = 0x20000; sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 5000; sl@0: iExpectedDstBytesAdded[i] = 10000; sl@0: sl@0: if((i%2)==0)//even i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: else //odd i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM8 To PCM16 Pass in large buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0024::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM8ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KLargeBufferSize, KLargeBufferSize)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0025::CTest_MMF_ACOD_U_0025() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0025-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x800; sl@0: iExpectedDstBytesAdded[i] = 0x1000; sl@0: sl@0: if((i%2)==0)//even i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: else //odd i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM8 To PCM16 Pass in default sized buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0025::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM8ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KDefaultBufferSize, KDefaultBufferSize)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0026::CTest_MMF_ACOD_U_0026() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0026-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x800; sl@0: iExpectedDstBytesAdded[i] = 0x1000; sl@0: sl@0: if((i%2)==0)//even i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: else //odd i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM8 To PCM16 Pass in buffers with different max length and length sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0026::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM8ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KMaxBufferLength, KDefaultBufferSize, KDefaultBufferSize)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0027::CTest_MMF_ACOD_U_0027() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0027-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x800; sl@0: iExpectedDstBytesAdded[i] = 0x1000; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM8 To PCM16 Pass in buffers of optimum size sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0027::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM8ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM8ToPCM16OptimumSrc, KPCM8ToPCM16OptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0028::CTest_MMF_ACOD_U_0028() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0028-HP"); sl@0: // iHeapSize = 0x20000; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM8 To PCM16 Reposition source pointer during conversion sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0028::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM8ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: sl@0: INFO_PRINTF1(_L(">> The PCM8 to PCM16 codec doesn't currently store data between calls to ProcessL")); sl@0: // TRAPD(err, testOK = TestRepositionL(codecUid, KPCM8ToPCM16OptimumSrc, KPCM8ToPCM16OptimumDst+30)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0029::CTest_MMF_ACOD_U_0029() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0029-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCM8 Instantiate codec by FourCC Codes sl@0: * @test Req. under test REQ172.6.2, REQ172.11.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0029::DoTestStepL() sl@0: { sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(KMMFFourCCCodePCM16, KMMFFourCCCodePCM8)); sl@0: TInt err = KErrNone ; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0030::CTest_MMF_ACOD_U_0030() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0030-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCM8 Instantiate codec by UID sl@0: * @test Req. under test REQ172.6.1, REQ172.11.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0030::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMS8}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(codecUid)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0031::CTest_MMF_ACOD_U_0031() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0031-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 50; sl@0: iExpectedDstBytesAdded[i] = 25; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCM8 Pass in small source buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0031::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMS8}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KSmallBufferSize, KPCM16ToPCM8OptimumDst)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0032::CTest_MMF_ACOD_U_0032() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0032-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 100; sl@0: iExpectedDstBytesAdded[i] = 50; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCM8 Pass in small dest buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0032::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMS8}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToPCM8OptimumSrc, KSmallBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0033::CTest_MMF_ACOD_U_0033() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0033-HP"); sl@0: iHeapSize = 0x20000; sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 10000; sl@0: iExpectedDstBytesAdded[i] = 5000; sl@0: sl@0: if((i%2)==0)//even i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: else //odd i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCM8 Pass in large buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0033::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMS8}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KLargeBufferSize, KLargeBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0034::CTest_MMF_ACOD_U_0034() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0034-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x1000; sl@0: iExpectedDstBytesAdded[i] = 0x800; sl@0: sl@0: if((i%2)==0)//even i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: else //odd i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCM8 Pass in default sized buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0034::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMS8}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KDefaultBufferSize, KDefaultBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0035::CTest_MMF_ACOD_U_0035() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0035-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x1000; sl@0: iExpectedDstBytesAdded[i] = 0x800; sl@0: sl@0: if((i%2)==0)//even i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: else //odd i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCM8 Pass in buffers with different max length and length sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0035::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMS8}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KMaxBufferLength, KDefaultBufferSize, KDefaultBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0036::CTest_MMF_ACOD_U_0036() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0036-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x1000; sl@0: iExpectedDstBytesAdded[i] = 0x800; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCM8 Pass in buffers of optimum size sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0036::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMS8}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToPCM8OptimumSrc, KPCM16ToPCM8OptimumDst)); sl@0: TInt err = KErrNone; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0037::CTest_MMF_ACOD_U_0037() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0037-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCM8 Reposition source pointer during conversion sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0037::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMS8}; sl@0: TBool testOK = EFalse; sl@0: sl@0: INFO_PRINTF1(_L(">> The PCM16 to PCM8 codec doesn't currently store data between calls to ProcessL")); sl@0: // TRAPD(err, testOK = TestRepositionL(codecUid, KDefaultBufferSize, KDefaultBufferSize+30)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0038::CTest_MMF_ACOD_U_0038() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0038-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCM16B Instantiate codec by FourCC Codes sl@0: * @test Req. under test REQ172.6.2, REQ172.11.6 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0038::DoTestStepL() sl@0: { sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(KMMFFourCCCodePCM16, KMMFFourCCCodePCM16B)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0039::CTest_MMF_ACOD_U_0039() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0039-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16B To PCM16 Instantiate codec by FourCC Codes sl@0: * @test Req. under test REQ172.6.2, REQ172.11.6 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0039::DoTestStepL() sl@0: { sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestNewL(KMMFFourCCCodePCM16B, KMMFFourCCCodePCM16)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0040::CTest_MMF_ACOD_U_0040() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0040-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16 To PCMU16B Instantiate codec by FourCC Codes sl@0: * @test Req. under test REQ172.6.2, REQ172.11.6 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0040::DoTestStepL() sl@0: { sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(KMMFFourCCCodePCMU16, KMMFFourCCCodePCMU16B)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0041::CTest_MMF_ACOD_U_0041() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0041-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16B To PCMU16 Instantiate codec by FourCC Codes sl@0: * @test Req. under test REQ172.6.2, REQ172.11.6 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0041::DoTestStepL() sl@0: { sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestNewL(KMMFFourCCCodePCMU16B, KMMFFourCCCodePCMU16)); sl@0: TInt err=KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0042::CTest_MMF_ACOD_U_0042() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0042-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCM16B Instantiate codec by UID sl@0: * @test Req. under test REQ172.6.1, REQ172.11.6 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0042::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMMFUidCodecPCM16SwapEndian}; sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16toPCM16B}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(codecUid)); sl@0: TInt err = KErrNone ; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0043::CTest_MMF_ACOD_U_0043() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0043-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 50; sl@0: iExpectedDstBytesAdded[i] = 50; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCM16B Pass in small source buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0043::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMMFUidCodecPCM16SwapEndian}; sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16toPCM16B}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KSmallBufferSize, KPCM16ToPCM16BOptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0044::CTest_MMF_ACOD_U_0044() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0044-HP"); sl@0: iHeapSize = 0x20000; sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 50; sl@0: iExpectedDstBytesAdded[i] = 50; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCM16B Pass in small dest buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0044::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMMFUidCodecPCM16SwapEndian}; sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16toPCM16B}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToPCM16BOptimumSrc, KSmallBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0045::CTest_MMF_ACOD_U_0045() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0045-HP"); sl@0: iHeapSize = 0x20000; sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 10000; sl@0: iExpectedDstBytesAdded[i] = 10000; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCM16B Pass in large buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0045::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMMFUidCodecPCM16SwapEndian}; sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16toPCM16B}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KLargeBufferSize, KLargeBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0046::CTest_MMF_ACOD_U_0046() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0046-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x1000; sl@0: iExpectedDstBytesAdded[i] = 0x1000; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCM16B Pass in default sized buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0046::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMMFUidCodecPCM16SwapEndian}; sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16toPCM16B}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KDefaultBufferSize, KDefaultBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0047::CTest_MMF_ACOD_U_0047() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0047-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x1000; sl@0: iExpectedDstBytesAdded[i] = 0x1000; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCM16B Pass in buffers with different max length and length sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0047::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMMFUidCodecPCM16SwapEndian}; sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16toPCM16B}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KMaxBufferLength, KDefaultBufferSize, KDefaultBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0048::CTest_MMF_ACOD_U_0048() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0048-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x1000; sl@0: iExpectedDstBytesAdded[i] = 0x1000; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCM16B Pass in buffers of optimum size sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0048::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMMFUidCodecPCM16SwapEndian}; sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16toPCM16B}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToPCM16BOptimumSrc, KPCM16ToPCM16BOptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0049::CTest_MMF_ACOD_U_0049() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0049-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCM16B Reposition source pointer during conversion sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0049::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMMFUidCodecPCM16SwapEndian}; sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16toPCM16B}; sl@0: TBool testOK = EFalse; sl@0: sl@0: INFO_PRINTF1(_L(">> The PCM16 to PCM16B codec doesn't currently store data between calls to ProcessL")); sl@0: // TRAPD(err, testOK = TestRepositionL(codecUid, KDefaultBufferSize, KDefaultBufferSize+30)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0050::CTest_MMF_ACOD_U_0050() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0050-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCMU16B Instantiate codec by FourCC Codes sl@0: * @test Req. under test REQ172.6.2 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0050::DoTestStepL() sl@0: { sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(KMMFFourCCCodePCM16, KMMFFourCCCodePCMU16B)); sl@0: TInt err = KErrNone ; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0051::CTest_MMF_ACOD_U_0051() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0051-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCMU16B Instantiate codec by UID sl@0: * @test Req. under test REQ172.6.1 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0051::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMMFUidHwDevicePCM16toPCMU16B}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(codecUid)); sl@0: TInt err = KErrNone ; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0052::CTest_MMF_ACOD_U_0052() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0052-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 50; sl@0: iExpectedDstBytesAdded[i] = 50; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCMU16B Pass in small source buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0052::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMMFUidHwDevicePCM16toPCMU16B}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KSmallBufferSize, KPCM16ToPCMU16BOptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0053::CTest_MMF_ACOD_U_0053() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0053-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 50; sl@0: iExpectedDstBytesAdded[i] = 50; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCMU16B Pass in small dest buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0053::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMMFUidHwDevicePCM16toPCMU16B}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToPCMU16BOptimumSrc, KSmallBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0054::CTest_MMF_ACOD_U_0054() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0054-HP"); sl@0: iHeapSize = 0x20000; sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 10000; sl@0: iExpectedDstBytesAdded[i] = 10000; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCMU16B Pass in large buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0054::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMMFUidHwDevicePCM16toPCMU16B}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KLargeBufferSize, KLargeBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0055::CTest_MMF_ACOD_U_0055() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0055-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x1000; sl@0: iExpectedDstBytesAdded[i] = 0x1000; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCMU16B Pass in default sized buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0055::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMMFUidHwDevicePCM16toPCMU16B}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KDefaultBufferSize, KDefaultBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0056::CTest_MMF_ACOD_U_0056() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0056-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x1000; sl@0: iExpectedDstBytesAdded[i] = 0x1000; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCMU16B Pass in buffers with different max length and length sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0056::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMMFUidHwDevicePCM16toPCMU16B}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KMaxBufferLength, KDefaultBufferSize, KDefaultBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0057::CTest_MMF_ACOD_U_0057() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0057-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x1000; sl@0: iExpectedDstBytesAdded[i] = 0x1000; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCMU16B Pass in buffers of optimum size sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0057::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMMFUidHwDevicePCM16toPCMU16B}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToPCMU16BOptimumSrc, KPCM16ToPCMU16BOptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0058::CTest_MMF_ACOD_U_0058() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0058-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCMU16B Reposition source pointer during conversion sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0058::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMMFUidHwDevicePCM16toPCMU16B}; sl@0: TBool testOK = EFalse; sl@0: sl@0: INFO_PRINTF1(_L(">> The PCM16 to PCMU16B codec doesn't currently store data between calls to ProcessL")); sl@0: // TRAPD(err, testOK = TestRepositionL(codecUid, KDefaultBufferSize, KDefaultBufferSize+30)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0059::CTest_MMF_ACOD_U_0059() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0059-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCMU16 Instantiate codec by FourCC Codes sl@0: * @test Req. under test REQ172.6.2, REQ172.11.7 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0059::DoTestStepL() sl@0: { sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(KMMFFourCCCodePCM16, KMMFFourCCCodePCMU16)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0060::CTest_MMF_ACOD_U_0060() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0060-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCMU16 Instantiate codec by UID sl@0: * @test Req. under test REQ172.6.1, REQ172.11.7 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0060::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMU16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(codecUid)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0061::CTest_MMF_ACOD_U_0061() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0061-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 50; sl@0: iExpectedDstBytesAdded[i] = 50; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCMU16 Pass in small source buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0061::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMU16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KSmallBufferSize, KPCM16ToPCMU16OptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0062::CTest_MMF_ACOD_U_0062() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0062-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 50; sl@0: iExpectedDstBytesAdded[i] = 50; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCMU16 Pass in small dest buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0062::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMU16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToPCMU16OptimumSrc, KSmallBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0063::CTest_MMF_ACOD_U_0063() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0063-HP"); sl@0: iHeapSize = 0x20000; sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 10000; sl@0: iExpectedDstBytesAdded[i] = 10000; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCMU16 Pass in large buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0063::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMU16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KLargeBufferSize, KLargeBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0064::CTest_MMF_ACOD_U_0064() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0064-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x1000; sl@0: iExpectedDstBytesAdded[i] = 0x1000; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCMU16 Pass in default sized buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0064::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMU16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KDefaultBufferSize, KDefaultBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0065::CTest_MMF_ACOD_U_0065() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0065-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x1000; sl@0: iExpectedDstBytesAdded[i] = 0x1000; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCMU16 Pass in buffers with different max length and length sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0065::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMU16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KMaxBufferLength, KDefaultBufferSize, KDefaultBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0066::CTest_MMF_ACOD_U_0066() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0066-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x1000; sl@0: iExpectedDstBytesAdded[i] = 0x1000; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCMU16 Pass in buffers of optimum size sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0066::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMU16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToPCMU16OptimumSrc, KPCM16ToPCMU16OptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0067::CTest_MMF_ACOD_U_0067() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0067-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCMU16 Reposition source pointer during conversion sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0067::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMU16}; sl@0: TBool testOK = EFalse; sl@0: sl@0: INFO_PRINTF1(_L(">> The PCM16 to PCMU16 codec doesn't currently store data between calls to ProcessL")); sl@0: // TRAPD(err, testOK = TestRepositionL(codecUid, KDefaultBufferSize, KDefaultBufferSize+30)); sl@0: TInt err = KErrNone ; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0068::CTest_MMF_ACOD_U_0068() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0068-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCMU8 Instantiate codec by FourCC Codes sl@0: * @test Req. under test REQ172.6.2, REQ172.11.8 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0068::DoTestStepL() sl@0: { sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(KMMFFourCCCodePCM16, KMMFFourCCCodePCMU8)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0069::CTest_MMF_ACOD_U_0069() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0069-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCMU8 Instantiate codec by UID sl@0: * @test Req. under test REQ172.6.1, REQ172.11.8 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0069::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMU8}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestNewL(codecUid)); sl@0: TInt err = KErrNone ; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0070::CTest_MMF_ACOD_U_0070() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0070-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 50; sl@0: iExpectedDstBytesAdded[i] = 25; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCMU8 Pass in small source buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0070::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMU8}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KSmallBufferSize, KPCM16ToPCMU8OptimumDst)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0071::CTest_MMF_ACOD_U_0071() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0071-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 100; sl@0: iExpectedDstBytesAdded[i] = 50; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCMU8 Pass in small dest buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0071::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMU8}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToPCMU8OptimumSrc, KSmallBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0072::CTest_MMF_ACOD_U_0072() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0072-HP"); sl@0: iHeapSize = 0x20000; sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 10000; sl@0: iExpectedDstBytesAdded[i] = 5000; sl@0: sl@0: if((i%2)==0)//even i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: else //odd i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCMU8 Pass in large buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0072::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMU8}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KLargeBufferSize, KLargeBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0073::CTest_MMF_ACOD_U_0073() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0073-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x1000; sl@0: iExpectedDstBytesAdded[i] = 0x800; sl@0: sl@0: if((i%2)==0)//even i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: else //odd i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCMU8 Pass in default sized buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0073::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMU8}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KDefaultBufferSize, KDefaultBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0074::CTest_MMF_ACOD_U_0074() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0074-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x1000; sl@0: iExpectedDstBytesAdded[i] = 0x800; sl@0: sl@0: if((i%2)==0)//even i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: else //odd i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCMU8 Pass in buffers with different max length and length sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0074::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMU8}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KMaxBufferLength, KDefaultBufferSize, KDefaultBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0075::CTest_MMF_ACOD_U_0075() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0075-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x1000; sl@0: iExpectedDstBytesAdded[i] = 0x800; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCMU8 Pass in buffers of optimum size sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0075::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMU8}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToPCMU8OptimumSrc, KPCM16ToPCMU8OptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0076::CTest_MMF_ACOD_U_0076() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0076-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To PCMU8 Reposition source pointer during conversion sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0076::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMU8}; sl@0: TBool testOK = EFalse; sl@0: sl@0: INFO_PRINTF1(_L(">> The PCM16 to PCMU8 codec doesn't currently store data between calls to ProcessL")); sl@0: // TRAPD(err, testOK = TestRepositionL(codecUid, KDefaultBufferSize, KDefaultBufferSize+30)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //----------------------------------------------------------------- sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0077::CTest_MMF_ACOD_U_0077() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0077-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16B To PCM16 Instantiate codec by FourCC Codes sl@0: * @test Req. under test REQ172.6.2, REQ172.11.9 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0077::DoTestStepL() sl@0: { sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(KMMFFourCCCodePCMU16B, KMMFFourCCCodePCM16)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0078::CTest_MMF_ACOD_U_0078() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0078-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16B To PCM16 Instantiate codec by UID sl@0: * @test Req. under test REQ172.6.1, REQ172.11.9 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0078::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceU16BEToPCMS16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(codecUid)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0079::CTest_MMF_ACOD_U_0079() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0079-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 50; sl@0: iExpectedDstBytesAdded[i] = 50; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16B To PCM16 Pass in small source buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0079::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceU16BEToPCMS16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KSmallBufferSize, KPCMU16BToPCM16OptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0080::CTest_MMF_ACOD_U_0080() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0080-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 50; sl@0: iExpectedDstBytesAdded[i] = 50; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16B To PCM16 Pass in small dest buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0080::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDeviceU16BEToPCMS16}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCMU16BToPCM16OptimumSrc, KSmallBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0081::CTest_MMF_ACOD_U_0081() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0081-HP"); sl@0: iHeapSize = 0x20000; sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 10000; sl@0: iExpectedDstBytesAdded[i] = 10000; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16B To PCM16 Pass in large buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0081::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDeviceU16BEToPCMS16}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KLargeBufferSize, KLargeBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0082::CTest_MMF_ACOD_U_0082() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0082-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x1000; sl@0: iExpectedDstBytesAdded[i] = 0x1000; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16B To PCM16 Pass in default sized buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0082::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDeviceU16BEToPCMS16}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KDefaultBufferSize, KDefaultBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0083::CTest_MMF_ACOD_U_0083() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0083-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x1000; sl@0: iExpectedDstBytesAdded[i] = 0x1000; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16B To PCM16 Pass in buffers with different max length and length sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0083::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDeviceU16BEToPCMS16}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KMaxBufferLength, KDefaultBufferSize, KDefaultBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0084::CTest_MMF_ACOD_U_0084() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0084-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x1000; sl@0: iExpectedDstBytesAdded[i] = 0x1000; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16B To PCM16 Pass in buffers of optimum size sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0084::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDeviceU16BEToPCMS16}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCMU16BToPCM16OptimumSrc, KPCMU16BToPCM16OptimumDst)); sl@0: TInt err = KErrNone; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0085::CTest_MMF_ACOD_U_0085() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0085-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16B To PCM16 Reposition source pointer during conversion sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0085::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceU16BEToPCMS16}; sl@0: TBool testOK = EFalse; sl@0: sl@0: INFO_PRINTF1(_L(">> The PCMU16B to PCM16 codec doesn't currently store data between calls to ProcessL")); sl@0: // TRAPD(err, testOK = TestRepositionL(codecUid, KDefaultBufferSize, KDefaultBufferSize+30)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0086::CTest_MMF_ACOD_U_0086() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0086-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16 To PCM16 Instantiate codec by FourCC Codes sl@0: * @test Req. under test REQ172.6.2, REQ172.11.25 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0086::DoTestStepL() sl@0: { sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(KMMFFourCCCodePCMU16, KMMFFourCCCodePCM16)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0087::CTest_MMF_ACOD_U_0087() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0087-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16 To PCM16 Instantiate codec by UID sl@0: * @test Req. under test REQ172.6.1, REQ172.11.25 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0087::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceU16ToPCMS16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(codecUid)); sl@0: TInt err = KErrNone; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0088::CTest_MMF_ACOD_U_0088() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0088-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 50; sl@0: iExpectedDstBytesAdded[i] = 50; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16 To PCM16 Pass in small source buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0088::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceU16ToPCMS16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KSmallBufferSize, KPCMU16ToPCM16OptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0089::CTest_MMF_ACOD_U_0089() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0089-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 50; sl@0: iExpectedDstBytesAdded[i] = 50; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16 To PCM16 Pass in small dest buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0089::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDeviceU16ToPCMS16}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCMU16ToPCM16OptimumSrc, KSmallBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0090::CTest_MMF_ACOD_U_0090() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0090-HP"); sl@0: iHeapSize = 0x20000; sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 10000; sl@0: iExpectedDstBytesAdded[i] = 10000; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16 To PCM16 Pass in large buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0090::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDeviceU16ToPCMS16}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KLargeBufferSize, KLargeBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0091::CTest_MMF_ACOD_U_0091() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0091-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x1000; sl@0: iExpectedDstBytesAdded[i] = 0x1000; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16 To PCM16 Pass in default sized buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0091::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDeviceU16ToPCMS16}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KDefaultBufferSize, KDefaultBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0092::CTest_MMF_ACOD_U_0092() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0092-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x1000; sl@0: iExpectedDstBytesAdded[i] = 0x1000; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16 To PCM16 Pass in buffers with different max length and length sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0092::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceU16ToPCMS16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KMaxBufferLength, KDefaultBufferSize, KDefaultBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0093::CTest_MMF_ACOD_U_0093() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0093-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x1000; sl@0: iExpectedDstBytesAdded[i] = 0x1000; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16 To PCM16 Pass in buffers of optimum size sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0093::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceU16ToPCMS16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCMU16ToPCM16OptimumSrc, KPCMU16ToPCM16OptimumDst)); sl@0: TInt err = KErrNone; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0094::CTest_MMF_ACOD_U_0094() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0094-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16 To PCM16 Reposition source pointer during conversion sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0094::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceU16ToPCMS16}; sl@0: TBool testOK = EFalse; sl@0: sl@0: INFO_PRINTF1(_L(">> The PCMU16 to PCM16 codec doesn't currently store data between calls to ProcessL")); sl@0: // TRAPD(err, testOK = TestRepositionL(codecUid, KDefaultBufferSize, KDefaultBufferSize+30)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0095::CTest_MMF_ACOD_U_0095() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0095-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU8 To PCM16 Instantiate codec by FourCC Codes sl@0: * @test Req. under test REQ172.6.2, REQ172.11.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0095::DoTestStepL() sl@0: { sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(KMMFFourCCCodePCMU8, KMMFFourCCCodePCM16)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0096::CTest_MMF_ACOD_U_0096() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0096-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU8 To PCM16 Instantiate codec by UID sl@0: * @test Req. under test REQ172.6.1, REQ172.11.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0096::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCMU8ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(codecUid)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0097::CTest_MMF_ACOD_U_0097() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0097-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 50; sl@0: iExpectedDstBytesAdded[i] = 100; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU8 To PCM16 Pass in small source buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0097::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCMU8ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KSmallBufferSize, KPCMU8ToPCM16OptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0098::CTest_MMF_ACOD_U_0098() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0098-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 25; sl@0: iExpectedDstBytesAdded[i] = 50; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU8 To PCM16 Pass in small dest buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0098::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCMU8ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCMU8ToPCM16OptimumSrc, KSmallBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0099::CTest_MMF_ACOD_U_0099() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0099-HP"); sl@0: iHeapSize = 0x20000; sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 5000; sl@0: iExpectedDstBytesAdded[i] = 10000; sl@0: sl@0: if((i%2)==0)//even i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: else //odd i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU8 To PCM16 Pass in large buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0099::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCMU8ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KLargeBufferSize, KLargeBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0100::CTest_MMF_ACOD_U_0100() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0100-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x800; sl@0: iExpectedDstBytesAdded[i] = 0x1000; sl@0: sl@0: if((i%2)==0)//even i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: else //odd i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU8 To PCM16 Pass in default sized buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0100::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDevicePCMU8ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KDefaultBufferSize, KDefaultBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0101::CTest_MMF_ACOD_U_0101() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0101-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x800; sl@0: iExpectedDstBytesAdded[i] = 0x1000; sl@0: sl@0: if((i%2)==0)//even i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: else //odd i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU8 To PCM16 Pass in buffers with different max length and length sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0101::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDevicePCMU8ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KMaxBufferLength, KDefaultBufferSize, KDefaultBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0102::CTest_MMF_ACOD_U_0102() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0102-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x800; sl@0: iExpectedDstBytesAdded[i] = 0x1000; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU8 To PCM16 Pass in buffers of optimum size sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0102::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDevicePCMU8ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCMU8ToPCM16OptimumSrc, KPCMU8ToPCM16OptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0103::CTest_MMF_ACOD_U_0103() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0103-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU8 To PCM16 Reposition source pointer during conversion sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0103::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCMU8ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: INFO_PRINTF1(_L(">> The PCMU8 to PCM16 codec doesn't currently store data between calls to ProcessL")); sl@0: sl@0: // TRAPD(err, testOK = TestRepositionL(codecUid, KPCMU8ToPCM16OptimumSrc, KPCMU8ToPCM16OptimumDst+30)); sl@0: TInt err = KErrNone ; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0104::CTest_MMF_ACOD_U_0104() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0104-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * MULAW To PCM16 Instantiate codec by FourCC Codes sl@0: * @test Req. under test REQ172.6.2, REQ172.11.13 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0104::DoTestStepL() sl@0: { sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(KMMFFourCCCodeMuLAW, KMMFFourCCCodePCM16)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0105::CTest_MMF_ACOD_U_0105() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0105-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * MULAW To PCM16 Instantiate codec by UID sl@0: * @test Req. under test REQ172.6.1, REQ172.11.13 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0105::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceMulawToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(codecUid)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0106::CTest_MMF_ACOD_U_0106() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0106-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 50; sl@0: iExpectedDstBytesAdded[i] = 100; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * MULAW To PCM16 Pass in small source buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0106::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDeviceMulawToPCM16}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KSmallBufferSize, KMulawToPCM16OptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0107::CTest_MMF_ACOD_U_0107() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0107-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 25; sl@0: iExpectedDstBytesAdded[i] = 50; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * MULAW To PCM16 Pass in small dest buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0107::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceMulawToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KMulawToPCM16OptimumSrc, KSmallBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0108::CTest_MMF_ACOD_U_0108() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0108-HP"); sl@0: iHeapSize = 0x20000; sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 5000; sl@0: iExpectedDstBytesAdded[i] = 10000; sl@0: sl@0: if((i%2)==0)//even i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: else //odd i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * MULAW To PCM16 Pass in large buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0108::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceMulawToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KLargeBufferSize, KLargeBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0109::CTest_MMF_ACOD_U_0109() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0109-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x800; sl@0: iExpectedDstBytesAdded[i] = 0x1000; sl@0: sl@0: if((i%2)==0)//even i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: else //odd i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * MULAW To PCM16 Pass in default sized buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0109::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceMulawToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KDefaultBufferSize, KDefaultBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0110::CTest_MMF_ACOD_U_0110() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0110-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x800; sl@0: iExpectedDstBytesAdded[i] = 0x1000; sl@0: sl@0: if((i%2)==0)//even i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: else //odd i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * MULAW To PCM16 Pass in buffers with different max length and length sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0110::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceMulawToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KMaxBufferLength, KDefaultBufferSize, KDefaultBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0111::CTest_MMF_ACOD_U_0111() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0111-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x800; sl@0: iExpectedDstBytesAdded[i] = 0x1000; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * MULAW To PCM16 Pass in buffers of optimum size sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0111::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceMulawToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KMulawToPCM16OptimumSrc, KMulawToPCM16OptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0112::CTest_MMF_ACOD_U_0112() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0112-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * MULAW To PCM16 Reposition source pointer during conversion sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0112::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceMulawToPCM16}; sl@0: TBool testOK = EFalse; sl@0: INFO_PRINTF1(_L(">> The MULAW To PCM16 codec doesn't currently store data between calls to ProcessL")); sl@0: sl@0: // TRAPD(err, testOK = TestRepositionL(codecUid, KMulawToPCM16OptimumSrc, KMulawToPCM16OptimumDst+30)); sl@0: TInt err = KErrNone; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0113::CTest_MMF_ACOD_U_0113() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0113-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To MULAW Instantiate codec by FourCC Codes sl@0: * @test Req. under test REQ172.6.2, REQ172.11.15 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0113::DoTestStepL() sl@0: { sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(KMMFFourCCCodePCM16, KMMFFourCCCodeMuLAW)); sl@0: TInt err = KErrNone; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0114::CTest_MMF_ACOD_U_0114() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0114-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To MULAW Instantiate codec by UID sl@0: * @test Req. under test REQ172.6.1, REQ172.11.15 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0114::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToMuLaw}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(codecUid)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0115::CTest_MMF_ACOD_U_0115() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0115-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 50; sl@0: iExpectedDstBytesAdded[i] = 25; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To MULAW Pass in small source buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0115::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToMuLaw}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KSmallBufferSize, KPCM16ToMulawOptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0116::CTest_MMF_ACOD_U_0116() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0116-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 100; sl@0: iExpectedDstBytesAdded[i] = 50; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To MULAW Pass in small dest buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0116::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToMuLaw}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToMulawOptimumSrc, KSmallBufferSize)); sl@0: TInt err = KErrNone; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0117::CTest_MMF_ACOD_U_0117() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0117-HP"); sl@0: iHeapSize = 0x20000; sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 10000; sl@0: iExpectedDstBytesAdded[i] = 5000; sl@0: sl@0: if((i%2)==0)//even i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: else //odd i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To MULAW Pass in large buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0117::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToMuLaw}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KLargeBufferSize, KLargeBufferSize)); sl@0: TInt err = KErrNone; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0118::CTest_MMF_ACOD_U_0118() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0118-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x1000; sl@0: iExpectedDstBytesAdded[i] = 0x800; sl@0: sl@0: if((i%2)==0)//even i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: else //odd i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To MULAW Pass in default sized buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0118::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToMuLaw}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KDefaultBufferSize, KDefaultBufferSize)); sl@0: TInt err = KErrNone; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0119::CTest_MMF_ACOD_U_0119() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0119-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x1000; sl@0: iExpectedDstBytesAdded[i] = 0x800; sl@0: sl@0: if((i%2)==0)//even i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: else //odd i sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To MULAW Pass in buffers with different max length and length sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0119::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToMuLaw}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KMaxBufferLength, KDefaultBufferSize, KDefaultBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0120::CTest_MMF_ACOD_U_0120() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0120-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x1000; sl@0: iExpectedDstBytesAdded[i] = 0x800; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To MULAW Pass in buffers of optimum size sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0120::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToMuLaw}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToMulawOptimumSrc, KPCM16ToMulawOptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0121::CTest_MMF_ACOD_U_0121() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0121-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 To MULAW Reposition source pointer during conversion sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0121::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToMuLaw}; sl@0: TBool testOK = EFalse; sl@0: sl@0: INFO_PRINTF1(_L(">> The PCM16 to MULAW codec doesn't currently store data between calls to ProcessL")); sl@0: // TRAPD(err, testOK = TestRepositionL(codecUid, KDefaultBufferSize, KDefaultBufferSize+30)); sl@0: TInt err = KErrNone ; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0122::CTest_MMF_ACOD_U_0122() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0122-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAD to PCM16 Instantiate codec by FourCC Codes sl@0: * @test Req. under test REQ172.6.2, REQ172.11.12 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0122::DoTestStepL() sl@0: { sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(KMMFFourCCCodeIMAD, KMMFFourCCCodePCM16)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0123::CTest_MMF_ACOD_U_0123() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0123-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAD to PCM16 Instantiate codec by UID sl@0: * @test Req. under test REQ172.6.1, REQ172.11.12 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0123::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceIMAADPCMToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(codecUid)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0124::CTest_MMF_ACOD_U_0124() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0124-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 50; sl@0: iExpectedDstBytesAdded[i] = 0; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAD to PCM16 Pass in small source buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0124::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceIMAADPCMToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KSmallBufferSize, KAdpcmToPCM16OptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0125::CTest_MMF_ACOD_U_0125() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0125-HP"); sl@0: sl@0: iExpectedLeaveErrorCode = KErrArgument; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAD to PCM16 Pass in small dest buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0125::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceIMAADPCMToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KAdpcmToPCM16OptimumSrc, KSmallBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0126::CTest_MMF_ACOD_U_0126() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0126-HP"); sl@0: iHeapSize = 0x20000; sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: if(i<4) sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: else sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAD to PCM16 Pass in large buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0126::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceIMAADPCMToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KLargeBufferSize, KLargeBufferSize, 0, EFalse)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0127::CTest_MMF_ACOD_U_0127() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0127-HP"); sl@0: sl@0: iExpectedReturnValue[0].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: iExpectedReturnValue[1].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: iExpectedReturnValue[2].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: iExpectedReturnValue[3].iStatus = TCodecProcessResult::EProcessComplete; sl@0: iExpectedReturnValue[4].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAD to PCM16 Pass in default sized buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0127::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceIMAADPCMToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KDefaultBufferSize, KDefaultBufferSize, 0, EFalse)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0128::CTest_MMF_ACOD_U_0128() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0128-HP"); sl@0: sl@0: iExpectedReturnValue[0].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: iExpectedReturnValue[1].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: iExpectedReturnValue[2].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: iExpectedReturnValue[3].iStatus = TCodecProcessResult::EProcessComplete; sl@0: iExpectedReturnValue[4].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAD to PCM16 Pass in buffers with different max length and length sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0128::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDeviceIMAADPCMToPCM16}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KMaxBufferLength, KDefaultBufferSize, KDefaultBufferSize, EFalse)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0129::CTest_MMF_ACOD_U_0129() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0129-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x400; sl@0: iExpectedDstBytesAdded[i] = 0xFC8; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAD to PCM16 Pass in buffers of optimum size sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0129::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDeviceIMAADPCMToPCM16}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KAdpcmToPCM16OptimumSrc, KAdpcmToPCM16OptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0130::CTest_MMF_ACOD_U_0130() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0130-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAD to PCM16 Reposition source pointer during conversion sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0130::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDeviceIMAADPCMToPCM16}; sl@0: TBool testOK = EFalse; sl@0: sl@0: // TUint src = (KAdpcmToPCM16OptimumSrc/4) + 10; sl@0: sl@0: INFO_PRINTF1(_L(">> The IMAD to PCM16 codec stores data between calls to ProcessL")); sl@0: // TRAPD(err, testOK = TestRepositionL(codecUid, src, KAdpcmToPCM16OptimumDst)); sl@0: TInt err = KErrNone; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0131::CTest_MMF_ACOD_U_0131() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0131-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to IMAD Instantiate codec by FourCC Codes sl@0: * @test Req. under test REQ172.6.2, REQ172.11.14 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0131::DoTestStepL() sl@0: { sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(KMMFFourCCCodePCM16, KMMFFourCCCodeIMAD)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0132::CTest_MMF_ACOD_U_0132() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0132-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to IMAD Instantiate codec by UID sl@0: * @test Req. under test REQ172.6.1, REQ172.11.14 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0132::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToIMAADPCM}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(codecUid)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0133::CTest_MMF_ACOD_U_0133() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0133-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 50; sl@0: iExpectedDstBytesAdded[i] = 0; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAD to PCM16 Pass in small source buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0133::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDevicePCM16ToIMAADPCM}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KSmallBufferSize, KPCM16ToAdpcmOptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0134::CTest_MMF_ACOD_U_0134() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0134-HP"); sl@0: sl@0: iExpectedLeaveErrorCode = KErrArgument; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to IMAD Pass in small dest buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0134::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDevicePCM16ToIMAADPCM}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToAdpcmOptimumSrc, KSmallBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0135::CTest_MMF_ACOD_U_0135() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0135-HP"); sl@0: iHeapSize = 0x20000; sl@0: iExpectedReturnValue[0].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: iExpectedReturnValue[1].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: iExpectedReturnValue[2].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: iExpectedReturnValue[3].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: iExpectedReturnValue[4].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to IMAD Pass in large buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0135::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDevicePCM16ToIMAADPCM}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KLargeBufferSize, KLargeBufferSize, 0, EFalse)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0136::CTest_MMF_ACOD_U_0136() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0136-HP"); sl@0: sl@0: iExpectedReturnValue[0].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: iExpectedReturnValue[1].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: iExpectedReturnValue[2].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: iExpectedReturnValue[3].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: iExpectedReturnValue[4].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to IMAD Pass in default sized buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0136::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDevicePCM16ToIMAADPCM}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KDefaultBufferSize, KDefaultBufferSize, 0, EFalse)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0137::CTest_MMF_ACOD_U_0137() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0137-HP"); sl@0: sl@0: iExpectedReturnValue[0].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: iExpectedReturnValue[1].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: iExpectedReturnValue[2].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: iExpectedReturnValue[3].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: iExpectedReturnValue[4].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to IMAD Pass in buffers with different max length and length sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0137::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDevicePCM16ToIMAADPCM}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KMaxBufferLength, KDefaultBufferSize, KDefaultBufferSize, EFalse)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0138::CTest_MMF_ACOD_U_0138() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0138-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0xFC8; sl@0: iExpectedDstBytesAdded[i] = 0x400; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to IMAD Pass in buffers of optimum size sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0138::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDevicePCM16ToIMAADPCM}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToAdpcmOptimumSrc, KPCM16ToAdpcmOptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0139::CTest_MMF_ACOD_U_0139() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0139-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to IMAD Reposition source pointer during conversion sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0139::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToIMAADPCM}; sl@0: TBool testOK = EFalse; sl@0: sl@0: // TUint src = (KPCM16ToAdpcmOptimumSrc/4) + 10; sl@0: sl@0: INFO_PRINTF1(_L(">> The PCM16 to IMAD codec stores data between calls to ProcessL")); sl@0: // TRAPD(err, testOK = TestRepositionL(codecUid, src, KPCM16ToAdpcmOptimumDst)); sl@0: TInt err = KErrNone ; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0140::CTest_MMF_ACOD_U_0140() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0140-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAS to PCM16 Instantiate codec by FourCC Codes sl@0: * @test Req. under test REQ172.6.2, REQ172.11.17 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0140::DoTestStepL() sl@0: { sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestNewL(KMMFFourCCCodeIMAS, KMMFFourCCCodePCM16)); sl@0: TInt err = KErrNone ; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0141::CTest_MMF_ACOD_U_0141() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0141-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAS to PCM16 Instantiate codec by UID sl@0: * @test Req. under test REQ172.6.1, REQ172.11.17 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0141::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {0}; //KMmfUidHwDeviceIMAADPCMToPCM16Stereo}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(codecUid)); sl@0: TInt err = KErrNone; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0142::CTest_MMF_ACOD_U_0142() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0142-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 50; sl@0: iExpectedDstBytesAdded[i] = 0; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAS to PCM16 Pass in small source buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0142::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {0}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KSmallBufferSize, KStereoAdpcmToPCM16OptimumDst)); sl@0: TInt err = KErrNone ; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0143::CTest_MMF_ACOD_U_0143() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0143-HP"); sl@0: sl@0: iExpectedLeaveErrorCode = KErrArgument; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAS to PCM16 Pass in small dest buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0143::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {0};//{0}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KStereoAdpcmToPCM16OptimumSrc, KSmallBufferSize)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0144::CTest_MMF_ACOD_U_0144() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0144-HP"); sl@0: iHeapSize = 0x20000; sl@0: iExpectedReturnValue[0].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: iExpectedReturnValue[1].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: iExpectedReturnValue[2].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: iExpectedReturnValue[3].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: iExpectedReturnValue[4].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAS to PCM16 Pass in large buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0144::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {0}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KLargeBufferSize, KLargeBufferSize, 0, EFalse)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0145::CTest_MMF_ACOD_U_0145() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0145-HP"); sl@0: sl@0: iExpectedReturnValue[0].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: iExpectedReturnValue[1].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: iExpectedReturnValue[2].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: iExpectedReturnValue[3].iStatus = TCodecProcessResult::EProcessComplete; sl@0: iExpectedReturnValue[4].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAS to PCM16 Pass in default sized buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0145::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {0}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KDefaultBufferSize, KDefaultBufferSize, 0, EFalse)); sl@0: TInt err = KErrNone ; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0146::CTest_MMF_ACOD_U_0146() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0146-HP"); sl@0: sl@0: iExpectedReturnValue[0].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: iExpectedReturnValue[1].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: iExpectedReturnValue[2].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: iExpectedReturnValue[3].iStatus = TCodecProcessResult::EProcessComplete; sl@0: iExpectedReturnValue[4].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAS to PCM16 Pass in buffers with different max length and length sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0146::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {0}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KMaxBufferLength, KDefaultBufferSize, KDefaultBufferSize, EFalse)); sl@0: TInt err = KErrNone ; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0147::CTest_MMF_ACOD_U_0147() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0147-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x400; sl@0: iExpectedDstBytesAdded[i] = 0xF90; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAS to PCM16 Pass in buffers of optimum size sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0147::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {0}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KStereoAdpcmToPCM16OptimumSrc, KStereoAdpcmToPCM16OptimumDst)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0148::CTest_MMF_ACOD_U_0148() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0148-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAS to PCM16 Reposition source pointer during conversion sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0148::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {0}; sl@0: TBool testOK = EFalse; sl@0: sl@0: // TUint src = (KStereoAdpcmToPCM16OptimumSrc/4) + 10; sl@0: sl@0: INFO_PRINTF1(_L(">> The IMAS to PCM16 codec stores data between calls to ProcessL")); sl@0: //TRAPD(err, testOK = TestRepositionL(codecUid, src, KStereoAdpcmToPCM16OptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0149::CTest_MMF_ACOD_U_0149() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0149-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to IMAS Instantiate codec by FourCC Codes sl@0: * @test Req. under test REQ172.6.2, REQ172.11.18 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0149::DoTestStepL() sl@0: { sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestNewL(KMMFFourCCCodePCM16, KMMFFourCCCodeIMAS)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0150::CTest_MMF_ACOD_U_0150() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0150-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to IMAS Instantiate codec by UID sl@0: * @test Req. under test REQ172.6.1, REQ172.11.18 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0150::DoTestStepL() sl@0: { sl@0: // AASSERT( 0 ); // remove this tests ! sl@0: // const TUid codecUid = {0}; //KMmfUidHwDevicePCM16ToIMAADPCMStereo}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(codecUid)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0151::CTest_MMF_ACOD_U_0151() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0151-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 50; sl@0: iExpectedDstBytesAdded[i] = 0; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAS to PCM16 Pass in small source buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0151::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {0}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KSmallBufferSize, KPCM16ToStereoAdpcmOptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0152::CTest_MMF_ACOD_U_0152() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0152-HP"); sl@0: sl@0: iExpectedLeaveErrorCode = KErrArgument; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to IMAS Pass in small dest buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0152::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {0}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToStereoAdpcmOptimumSrc, KSmallBufferSize)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0153::CTest_MMF_ACOD_U_0153() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0153-HP"); sl@0: iHeapSize = 0x20000; sl@0: iExpectedReturnValue[0].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: iExpectedReturnValue[1].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: iExpectedReturnValue[2].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: iExpectedReturnValue[3].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: iExpectedReturnValue[4].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to IMAS Pass in large buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0153::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {0}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KLargeBufferSize, KLargeBufferSize, 0, EFalse)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0154::CTest_MMF_ACOD_U_0154() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0154-HP"); sl@0: sl@0: iExpectedReturnValue[0].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: iExpectedReturnValue[1].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: iExpectedReturnValue[2].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: iExpectedReturnValue[3].iStatus = TCodecProcessResult::EProcessComplete; sl@0: iExpectedReturnValue[4].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to IMAS Pass in default sized buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0154::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {0}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KDefaultBufferSize, KDefaultBufferSize, 0, EFalse)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0155::CTest_MMF_ACOD_U_0155() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0155-HP"); sl@0: sl@0: iExpectedReturnValue[0].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: iExpectedReturnValue[1].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: iExpectedReturnValue[2].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: iExpectedReturnValue[3].iStatus = TCodecProcessResult::EProcessComplete; sl@0: iExpectedReturnValue[4].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to IMAS Pass in buffers with different max length and length sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0155::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {0}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KMaxBufferLength, KDefaultBufferSize, KDefaultBufferSize, EFalse)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0156::CTest_MMF_ACOD_U_0156() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0156-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0xF90; sl@0: iExpectedDstBytesAdded[i] = 0x400; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to IMAS Pass in buffers of optimum size sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0156::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {0}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToStereoAdpcmOptimumSrc, KPCM16ToStereoAdpcmOptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0157::CTest_MMF_ACOD_U_0157() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0157-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to IMAS Reposition source pointer during conversion sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0157::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {0}; sl@0: TBool testOK = EFalse; sl@0: sl@0: // TUint src = (KPCM16ToStereoAdpcmOptimumSrc/4) + 10; sl@0: sl@0: INFO_PRINTF1(_L(">> The PCM16 to IMAS codec stores data between calls to ProcessL")); sl@0: // TRAPD(err, testOK = TestRepositionL(codecUid, src, KPCM16ToStereoAdpcmOptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0158::CTest_MMF_ACOD_U_0158() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0158-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * GSM610 to PCM16 Instantiate codec by FourCC Codes sl@0: * @test Req. under test REQ172.6.2, REQ172.11.19 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0158::DoTestStepL() sl@0: { sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(KMMFFourCCCodeGSM610, KMMFFourCCCodePCM16)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0159::CTest_MMF_ACOD_U_0159() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0159-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * GSM610 to PCM16 Instantiate codec by UID sl@0: * @test Req. under test REQ172.6.1, REQ172.11.19 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0159::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceGSM610ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(codecUid)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0160::CTest_MMF_ACOD_U_0160() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0160-HP"); sl@0: iHeapSize = 0x200000; sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: sl@0: } sl@0: sl@0: /** @xxxx sl@0: * GSM610 to PCM16 Pass in small source buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0160::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDeviceGSM610ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KSmallBufferSizeGSM, KGSM610ToPCM16OptimumDstGSM, 0, EFalse)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0161::CTest_MMF_ACOD_U_0161() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0161-HP"); sl@0: iHeapSize = 0x20000; sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * GSM610 to PCM16 Pass in small dest buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0161::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDeviceGSM610ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KGSM610ToPCM16OptimumSrcGSM, KSmallBufferSizeGSM, 0, EFalse)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0162::CTest_MMF_ACOD_U_0162() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0162-HP"); sl@0: iHeapSize = 0x20000; sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * GSM610 to PCM16 Pass in large buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0162::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDeviceGSM610ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KLargeBufferSize, KLargeBufferSize, 0, EFalse)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0163::CTest_MMF_ACOD_U_0163() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0163-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * GSM610 to PCM16 Pass in default sized buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0163::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDeviceGSM610ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KDefaultBufferSize, KDefaultBufferSize, 0, EFalse)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0164::CTest_MMF_ACOD_U_0164() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0164-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessIncomplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * GSM610 to PCM16 Pass in buffers with different max length and length sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0164::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDeviceGSM610ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KMaxBufferLength, KDefaultBufferSize, KDefaultBufferSize, EFalse)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0165::CTest_MMF_ACOD_U_0165() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0165-HP"); sl@0: iSingleIteration = ETrue; sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0x104; sl@0: iExpectedDstBytesAdded[i] = 0xA00; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * GSM610 to PCM16 Pass in buffers of optimum size sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0165::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDeviceGSM610ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KGSM610ToPCM16OptimumSrc, KGSM610ToPCM16OptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0166::CTest_MMF_ACOD_U_0166() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0166-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * GSM610 to PCM16 Reposition source pointer during conversion sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0166::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDeviceGSM610ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: sl@0: // TUint src = (KGSM610ToPCM16OptimumSrc/4) + 10; sl@0: sl@0: INFO_PRINTF1(_L(">> The GSM610 to PCM16 codec stores data between calls to ProcessL")); sl@0: // TRAPD(err, testOK = TestRepositionL(codecUid, src, KGSM610ToPCM16OptimumDst)); sl@0: TInt err = KErrNone; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0167::CTest_MMF_ACOD_U_0167() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0167-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to GSM610 Instantiate codec by FourCC Codes sl@0: * @test Req. under test REQ172.6.2, REQ172.11.20 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0167::DoTestStepL() sl@0: { sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(KMMFFourCCCodePCM16, KMMFFourCCCodeGSM610)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0168::CTest_MMF_ACOD_U_0168() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0168-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to GSM610 Instantiate codec by UID sl@0: * @test Req. under test REQ172.6.1, REQ172.11.20 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0168::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToGSM610}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestNewL(codecUid)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0169::CTest_MMF_ACOD_U_0169() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0169-HP"); sl@0: iHeapSize = 0x20000; sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * GSM610 to PCM16 Pass in small source buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0169::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDevicePCM16ToGSM610}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KSmallBufferSizeGSM, KPCM16ToGSM610OptimumDstGSM, 0, EFalse)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0170::CTest_MMF_ACOD_U_0170() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0170-HP"); sl@0: sl@0: iExpectedLeaveErrorCode = KErrArgument; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to GSM610 Pass in small dest buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0170::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDevicePCM16ToGSM610}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToGSM610OptimumSrc, KSmallBufferSize, 0, EFalse)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0171::CTest_MMF_ACOD_U_0171() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0171-HP"); sl@0: iHeapSize = 0x20000; sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to GSM610 Pass in large buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0171::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDevicePCM16ToGSM610}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KLargeBufferSize, KLargeBufferSize, 0, EFalse)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0172::CTest_MMF_ACOD_U_0172() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0172-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to GSM610 Pass in default sized buffers sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0172::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDevicePCM16ToGSM610}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KDefaultBufferSize, KDefaultBufferSize, 0, EFalse)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0173::CTest_MMF_ACOD_U_0173() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0173-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to GSM610 Pass in buffers with different max length and length sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0173::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDevicePCM16ToGSM610}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KMaxBufferLength, KDefaultBufferSize, KDefaultBufferSize, EFalse)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0174::CTest_MMF_ACOD_U_0174() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0174-HP"); sl@0: iSingleIteration = ETrue; sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0xA00; sl@0: iExpectedDstBytesAdded[i] = 0x104; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EProcessComplete; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to GSM610 Pass in buffers of optimum size sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0174::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDevicePCM16ToGSM610}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToGSM610OptimumSrc, KPCM16ToGSM610OptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0175::CTest_MMF_ACOD_U_0175() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0175-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to GSM610 Reposition source pointer during conversion sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0175::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToGSM610}; sl@0: TBool testOK = EFalse; sl@0: sl@0: // TUint src = (KPCM16ToGSM610OptimumSrc/4) + 10; sl@0: sl@0: INFO_PRINTF1(_L(">> The PCM16 to GSM610 codec stores data between calls to ProcessL")); sl@0: // TRAPD(err, testOK = TestRepositionL(codecUid, src, KPCM16ToGSM610OptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0176::CTest_MMF_ACOD_U_0176() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0176-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * Instantiate codec that doesn't exist sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0176::DoTestStepL() sl@0: { sl@0: // CMMFCodec* codec = NULL; sl@0: //TRAPD(err, codec = CMMFCodec::NewL(KMMFFourCCCodeALAW, KMMFFourCCCodePCMU16B)); sl@0: TInt err = KErrNone; sl@0: if (err == KErrNone || err == KErrNotSupported) sl@0: return EPass; sl@0: else sl@0: { sl@0: ERR_PRINTF2(_L(">> CTest_MMF_ACOD_U_0176::DoTestStepL Leave occurred in NewL, error code %d"), err); sl@0: return EFail; sl@0: } sl@0: } sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0177::CTest_MMF_ACOD_U_0177() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0177-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * Instantiate codec from fourCC codes that don't exist sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0177::DoTestStepL() sl@0: { sl@0: // const TUint32 KFourCCCodeP1B = 0x42315020; //(' ', 'P', '1', 'B') sl@0: // const TUint32 KFourCCCodePS16 = 0x36315350; //('P', 'S', '1', '6') sl@0: sl@0: // CMMFCodec* codec = NULL; sl@0: //TRAPD(err, codec = CMMFCodec::NewL(KFourCCCodeP1B, KFourCCCodePS16)); sl@0: sl@0: TInt err = KErrNone; sl@0: if (err == KErrNone || err == KErrNotSupported) sl@0: return EPass; sl@0: else sl@0: { sl@0: ERR_PRINTF2(_L(">> CTest_MMF_ACOD_U_0177::DoTestStepL Leave occurred in NewL, error code %d"), err); sl@0: return EFail; sl@0: } sl@0: } sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0178::CTest_MMF_ACOD_U_0178() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0178-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * Test out of memory in NewL sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0178::DoTestStepL() sl@0: { sl@0: // CMMFCodec* codec = NULL; sl@0: __UHEAP_FAILNEXT(1); sl@0: //TRAPD(err, codec = CMMFCodec::NewL(KMMFFourCCCodePCMU8, KMMFFourCCCodePCM16)); sl@0: TInt err = KErrNone; sl@0: if (err == KErrNoMemory) sl@0: return EPass; sl@0: else sl@0: { sl@0: ERR_PRINTF2(_L(">> CTest_MMF_ACOD_U_0178::DoTestStepL Leave occurred in NewL, error code %d"), err); sl@0: return EFail; sl@0: } sl@0: } sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0179::CTest_MMF_ACOD_U_0179() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0179-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0; sl@0: iExpectedDstBytesAdded[i] = 0; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * ALAW To PCM16 Pass in zero sized source buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0179::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceAlawToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, 0, KAlawToPCM16OptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0180::CTest_MMF_ACOD_U_0180() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0180-HP"); sl@0: sl@0: iExpectedLeaveErrorCode = KErrArgument; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * ALAW To PCM16 Pass in zero sized destination buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0180::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceAlawToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KAlawToPCM16OptimumSrc, 0)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0181::CTest_MMF_ACOD_U_0181() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0181-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * ALAW To PCM16 Test out of memory sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0181::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {KMmfUidHwDeviceAlawToPCM16}; sl@0: TBool testOK = EFalse; sl@0: sl@0: // TRAPD(err, testOK = TestNewLOutOfMemoryL(codecUid)); sl@0: TInt err = KErrNone ; sl@0: if (err==KErrNone && testOK) sl@0: TRAP(err, testOK = TestProcessLOutOfMemoryL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0182::CTest_MMF_ACOD_U_0182() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0182-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * ALAW To PCM16 Test for memory leaks sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0182::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {KMmfUidHwDeviceAlawToPCM16}; sl@0: TBool testOK = EFalse; sl@0: TRAPD(err, testOK = TestMemoryLeakL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0183::CTest_MMF_ACOD_U_0183() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0183-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * ALAW To PCM16 Test for memory scribbles sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0183::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceAlawToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestMemoryScribbleL(codecUid)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0184::CTest_MMF_ACOD_U_0184() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0184-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0; sl@0: iExpectedDstBytesAdded[i] = 0; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to ALAW Pass in zero sized source buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0184::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToALaw}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, 0, KPCM16ToAlawOptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0185::CTest_MMF_ACOD_U_0185() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0185-HP"); sl@0: sl@0: iExpectedLeaveErrorCode = KErrArgument; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to ALAW Pass in zero sized destination buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0185::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToALaw}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToAlawOptimumSrc, 0)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0186::CTest_MMF_ACOD_U_0186() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0186-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to ALAW Test out of memory sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0186::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {KMmfUidHwDevicePCM16ToALaw}; sl@0: TBool testOK = EFalse; sl@0: sl@0: // TRAPD(err, testOK = TestNewLOutOfMemoryL(codecUid)); sl@0: TInt err = KErrNone; sl@0: if (err==KErrNone && testOK) sl@0: TRAP(err, testOK = TestProcessLOutOfMemoryL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0187::CTest_MMF_ACOD_U_0187() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0187-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to ALAW Test for memory leaks sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0187::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {KMmfUidHwDevicePCM16ToALaw}; sl@0: TBool testOK = EFalse; sl@0: TRAPD(err, testOK = TestMemoryLeakL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0188::CTest_MMF_ACOD_U_0188() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0188-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to ALAW Test for memory scribbles sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0188::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToALaw}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestMemoryScribbleL(codecUid)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0189::CTest_MMF_ACOD_U_0189() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0189-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0; sl@0: iExpectedDstBytesAdded[i] = 0; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM8 To PCM16 Pass in zero sized source buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0189::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM8ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, 0, KPCM8ToPCM16OptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0190::CTest_MMF_ACOD_U_0190() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0190-HP"); sl@0: sl@0: iExpectedLeaveErrorCode = KErrArgument; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM8 To PCM16 Pass in zero sized destination buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0190::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM8ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM8ToPCM16OptimumSrc, 0)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0191::CTest_MMF_ACOD_U_0191() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0191-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM8 To PCM16 Test out of memory sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0191::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {KMmfUidHwDevicePCM8ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: sl@0: // TRAPD(err, testOK = TestNewLOutOfMemoryL(codecUid)); sl@0: TInt err = KErrNone ; sl@0: if (err==KErrNone && testOK) sl@0: TRAP(err, testOK = TestProcessLOutOfMemoryL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0192::CTest_MMF_ACOD_U_0192() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0192-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM8 To PCM16 Test for memory leaks sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0192::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {KMmfUidHwDevicePCM8ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: TRAPD(err, testOK = TestMemoryLeakL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0193::CTest_MMF_ACOD_U_0193() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0193-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM8 To PCM16 Test for memory scribbles sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0193::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM8ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestMemoryScribbleL(codecUid)); sl@0: TInt err = KErrNone; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0194::CTest_MMF_ACOD_U_0194() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0194-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0; sl@0: iExpectedDstBytesAdded[i] = 0; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to PCM8 Pass in zero sized source buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0194::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDeviceS16ToPCMS8}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopTInt err = KErrNone;FiveTimesL(codecUid, 0, KPCM16ToPCM8OptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0195::CTest_MMF_ACOD_U_0195() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0195-HP"); sl@0: sl@0: iExpectedLeaveErrorCode = KErrArgument; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to PCM8 Pass in zero sized destination buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0195::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDeviceS16ToPCMS8}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToPCM8OptimumSrc, 0)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0196::CTest_MMF_ACOD_U_0196() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0196-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to PCM8 Test out of memory sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0196::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {KMmfUidHwDeviceS16ToPCMS8}; sl@0: TBool testOK = EFalse; sl@0: sl@0: // TRAPD(err, testOK = TestNewLOutOfMemoryL(codecUid)); sl@0: TInt err = KErrNone; sl@0: sl@0: if (err==KErrNone && testOK) sl@0: TRAP(err, testOK = TestProcessLOutOfMemoryL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0197::CTest_MMF_ACOD_U_0197() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0197-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to PCM8 Test for memory leaks sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0197::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDeviceS16ToPCMS8}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestMemoryLeakL(codecUid)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0198::CTest_MMF_ACOD_U_0198() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0198-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to PCM8 Test for memory scribbles sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0198::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMS8}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestMemoryScribbleL(codecUid)); sl@0: TInt err= KErrNone ; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0199::CTest_MMF_ACOD_U_0199() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0199-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0; sl@0: iExpectedDstBytesAdded[i] = 0; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * Swap Endian Pass in zero sized source buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0199::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMMFUidCodecPCM16SwapEndian}; sl@0: //const TUid codecUid = {KMmfUidHwDevicePCM16toPCM16B}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, 0, KPCM16ToPCM16BOptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0200::CTest_MMF_ACOD_U_0200() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0200-HP"); sl@0: sl@0: iExpectedLeaveErrorCode = KErrArgument; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * Swap Endian Pass in zero sized destination buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0200::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMMFUidCodecPCM16SwapEndian}; sl@0: //const TUid codecUid = {KMmfUidHwDevicePCM16toPCM16B}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToPCM16BOptimumSrc, 0)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0201::CTest_MMF_ACOD_U_0201() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0201-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * Swap Endian Test out of memory sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0201::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMMFUidCodecPCM16SwapEndian}; sl@0: const TUid codecUid = {KMmfUidHwDevicePCM16toPCM16B}; sl@0: TBool testOK = EFalse; sl@0: sl@0: // TRAPD(err, testOK = TestNewLOutOfMemoryL(codecUid)); sl@0: TInt err = KErrNone ; sl@0: if (err==KErrNone && testOK) sl@0: TRAP(err, testOK = TestProcessLOutOfMemoryL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0202::CTest_MMF_ACOD_U_0202() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0202-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * Swap Endian Test for memory leaks sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0202::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMMFUidCodecPCM16SwapEndian}; sl@0: //const TUid codecUid = {KMmfUidHwDevicePCM16toPCM16B}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestMemoryLeakL(codecUid)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0203::CTest_MMF_ACOD_U_0203() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0203-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * Swap Endian Test for memory scribbles sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0203::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMMFUidCodecPCM16SwapEndian}; sl@0: //const TUid codecUid = {KMmfUidHwDevicePCM16toPCM16B}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestMemoryScribbleL(codecUid)); sl@0: TInt err = KErrNone ; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0204::CTest_MMF_ACOD_U_0204() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0204-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0; sl@0: iExpectedDstBytesAdded[i] = 0; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to PCMU16BE Pass in zero sized source buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0204::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMMFUidHwDevicePCM16toPCMU16B}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, 0, KPCM16ToPCMU16BOptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0205::CTest_MMF_ACOD_U_0205() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0205-HP"); sl@0: sl@0: iExpectedLeaveErrorCode = KErrArgument; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to PCMU16BE Pass in zero sized destination buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0205::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMMFUidHwDevicePCM16toPCMU16B}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToPCMU16BOptimumSrc, 0)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0206::CTest_MMF_ACOD_U_0206() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0206-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to PCMU16BE Test out of memory sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0206::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {KMMFUidHwDevicePCM16toPCMU16B}; sl@0: TBool testOK = EFalse; sl@0: sl@0: // TRAPD(err, testOK = TestNewLOutOfMemoryL(codecUid)); sl@0: TInt err = KErrNone ; sl@0: if (err==KErrNone && testOK) sl@0: TRAP(err, testOK = TestProcessLOutOfMemoryL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0207::CTest_MMF_ACOD_U_0207() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0207-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to PCMU16BE Test for memory leaks sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0207::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {KMMFUidHwDevicePCM16toPCMU16B}; sl@0: TBool testOK = EFalse; sl@0: TRAPD(err, testOK = TestMemoryLeakL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0208::CTest_MMF_ACOD_U_0208() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0208-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to PCMU16BE Test for memory scribbles sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0208::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMMFUidHwDevicePCM16toPCMU16B}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestMemoryScribbleL(codecUid)); sl@0: TInt err = KErrNone ; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0209::CTest_MMF_ACOD_U_0209() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0209-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0; sl@0: iExpectedDstBytesAdded[i] = 0; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to PCMU16 Pass in zero sized source buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0209::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {KMmfUidHwDeviceS16ToPCMU16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, 0, KPCM16ToPCMU16OptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0210::CTest_MMF_ACOD_U_0210() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0210-HP"); sl@0: sl@0: iExpectedLeaveErrorCode = KErrArgument; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to PCMU16 Pass in zero sized destination buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0210::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMU16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToPCMU16OptimumSrc, 0)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0211::CTest_MMF_ACOD_U_0211() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0211-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to PCMU16 Test out of memory sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0211::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {KMmfUidHwDeviceS16ToPCMU16}; sl@0: TBool testOK = EFalse; sl@0: sl@0: // TRAPD(err, testOK = TestNewLOutOfMemoryL(codecUid)); sl@0: TInt err = KErrNone ; sl@0: if (err==KErrNone && testOK) sl@0: TRAP(err, testOK = TestProcessLOutOfMemoryL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0212::CTest_MMF_ACOD_U_0212() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0212-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to PCMU16 Test for memory leaks sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0212::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {KMmfUidHwDeviceS16ToPCMU16}; sl@0: TBool testOK = EFalse; sl@0: TRAPD(err, testOK = TestMemoryLeakL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0213::CTest_MMF_ACOD_U_0213() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0213-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to PCMU16 Test for memory scribbles sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0213::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMU16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestMemoryScribbleL(codecUid)); sl@0: TInt err = KErrNone; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0214::CTest_MMF_ACOD_U_0214() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0214-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0; sl@0: iExpectedDstBytesAdded[i] = 0; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to PCMU8 Pass in zero sized source buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0214::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMU8}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, 0, KPCM16ToPCMU8OptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0215::CTest_MMF_ACOD_U_0215() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0215-HP"); sl@0: sl@0: iExpectedLeaveErrorCode = KErrArgument; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to PCMU8 Pass in zero sized destination buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0215::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMU8}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToPCMU8OptimumSrc, 0)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0216::CTest_MMF_ACOD_U_0216() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0216-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to PCMU8 Test out of memory sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0216::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {KMmfUidHwDeviceS16ToPCMU8}; sl@0: TBool testOK = EFalse; sl@0: sl@0: // TRAPD(err, testOK = TestNewLOutOfMemoryL(codecUid)); sl@0: TInt err = KErrNone ; sl@0: if (err==KErrNone && testOK) sl@0: TRAP(err, testOK = TestProcessLOutOfMemoryL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0217::CTest_MMF_ACOD_U_0217() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0217-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to PCMU8 Test for memory leaks sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0217::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {KMmfUidHwDeviceS16ToPCMU8}; sl@0: TBool testOK = EFalse; sl@0: TRAPD(err, testOK = TestMemoryLeakL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0218::CTest_MMF_ACOD_U_0218() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0218-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to PCMU8 Test for memory scribbles sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0218::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceS16ToPCMU8}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestMemoryScribbleL(codecUid)); sl@0: TInt err = KErrNone ; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0219::CTest_MMF_ACOD_U_0219() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0219-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0; sl@0: iExpectedDstBytesAdded[i] = 0; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16BE to PCM16 Pass in zero sized source buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0219::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceU16BEToPCMS16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, 0, KPCMU16BToPCM16OptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0220::CTest_MMF_ACOD_U_0220() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0220-HP"); sl@0: sl@0: iExpectedLeaveErrorCode = KErrArgument; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16BE to PCM16 Pass in zero sized destination buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0220::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceU16BEToPCMS16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCMU16BToPCM16OptimumSrc, 0)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0221::CTest_MMF_ACOD_U_0221() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0221-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16BE to PCM16 Test out of memory sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0221::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceU16BEToPCMS16}; sl@0: TBool testOK = EFalse; sl@0: sl@0: // TRAPD(err, testOK = TestNewLOutOfMemoryL(codecUid)); sl@0: TInt err = KErrNone; sl@0: sl@0: // if (err==KErrNone && testOK) sl@0: // TRAP(err, testOK = TestProcessLOutOfMemoryL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0222::CTest_MMF_ACOD_U_0222() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0222-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16BE to PCM16 Test for memory leaks sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0222::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {KMmfUidHwDeviceU16BEToPCMS16}; sl@0: TBool testOK = EFalse; sl@0: TRAPD(err, testOK = TestMemoryLeakL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0223::CTest_MMF_ACOD_U_0223() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0223-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16BE to PCM16 Test for memory scribbles sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0223::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceU16BEToPCMS16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestMemoryScribbleL(codecUid)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0224::CTest_MMF_ACOD_U_0224() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0224-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0; sl@0: iExpectedDstBytesAdded[i] = 0; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16 to PCM16 Pass in zero sized source buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0224::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceU16ToPCMS16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, 0, KPCMU16ToPCM16OptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0225::CTest_MMF_ACOD_U_0225() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0225-HP"); sl@0: sl@0: iExpectedLeaveErrorCode = KErrArgument; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16 to PCM16 Pass in zero sized destination buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0225::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceU16ToPCMS16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCMU16ToPCM16OptimumSrc, 0)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0226::CTest_MMF_ACOD_U_0226() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0226-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16 to PCM16 Test out of memory sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0226::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {KMmfUidHwDeviceU16ToPCMS16}; sl@0: TBool testOK = EFalse; sl@0: sl@0: // TRAPD(err, testOK = TestNewLOutOfMemoryL(codecUid)); sl@0: // if (err==KErrNone && testOK) sl@0: TInt err = KErrNone ; sl@0: TRAP(err, testOK = TestProcessLOutOfMemoryL(codecUid)); sl@0: sl@0: sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0227::CTest_MMF_ACOD_U_0227() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0227-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16 to PCM16 Test for memory leaks sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0227::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {KMmfUidHwDeviceU16ToPCMS16}; sl@0: TBool testOK = EFalse; sl@0: TRAPD(err, testOK = TestMemoryLeakL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0228::CTest_MMF_ACOD_U_0228() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0228-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU16 to PCM16 Test for memory scribbles sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0228::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceU16ToPCMS16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestMemoryScribbleL(codecUid)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0229::CTest_MMF_ACOD_U_0229() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0229-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0; sl@0: iExpectedDstBytesAdded[i] = 0; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU8 To PCM16 Pass in zero sized source buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0229::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCMU8ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, 0, KPCMU8ToPCM16OptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0230::CTest_MMF_ACOD_U_0230() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0230-HP"); sl@0: sl@0: iExpectedLeaveErrorCode = KErrArgument; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU8 To PCM16 Pass in zero sized destination buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0230::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCMU8ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCMU8ToPCM16OptimumSrc, 0)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0231::CTest_MMF_ACOD_U_0231() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0231-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU8 To PCM16 Test out of memory sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0231::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {KMmfUidHwDevicePCMU8ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: sl@0: // TRAPD(err, testOK = TestNewLOutOfMemoryL(codecUid)); sl@0: TInt err = KErrNone ; sl@0: if (err==KErrNone && testOK) sl@0: TRAP(err, testOK = TestProcessLOutOfMemoryL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0232::CTest_MMF_ACOD_U_0232() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0232-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU8 To PCM16 Test for memory leaks sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0232::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {KMmfUidHwDevicePCMU8ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: TRAPD(err, testOK = TestMemoryLeakL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0233::CTest_MMF_ACOD_U_0233() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0233-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCMU8 To PCM16 Test for memory scribbles sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0233::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCMU8ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestMemoryScribbleL(codecUid)); sl@0: TInt err = KErrNone ; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0234::CTest_MMF_ACOD_U_0234() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0234-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0; sl@0: iExpectedDstBytesAdded[i] = 0; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * MULAW To PCM16 Pass in zero sized source buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0234::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceMulawToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, 0, KMulawToPCM16OptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0235::CTest_MMF_ACOD_U_0235() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0235-HP"); sl@0: sl@0: iExpectedLeaveErrorCode = KErrArgument; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * MULAW To PCM16 Pass in zero sized destination buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0235::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceMulawToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KMulawToPCM16OptimumSrc, 0)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0236::CTest_MMF_ACOD_U_0236() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0236-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * MULAW To PCM16 Test out of memory sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0236::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceMulawToPCM16}; sl@0: TBool testOK = EFalse; sl@0: sl@0: // TRAPD(err, testOK = TestNewLOutOfMemoryL(codecUid)); sl@0: TInt err = KErrNone ; sl@0: //if (err==KErrNone && testOK) sl@0: // TRAP(err, testOK = TestProcessLOutOfMemoryL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0237::CTest_MMF_ACOD_U_0237() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0237-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * MULAW To PCM16 Test for memory leaks sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0237::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {KMmfUidHwDeviceMulawToPCM16}; sl@0: TBool testOK = EFalse; sl@0: TRAPD(err, testOK = TestMemoryLeakL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0238::CTest_MMF_ACOD_U_0238() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0238-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * MULAW To PCM16 Test for memory scribbles sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0238::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceMulawToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestMemoryScribbleL(codecUid)); sl@0: TInt err = KErrNone; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0239::CTest_MMF_ACOD_U_0239() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0239-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0; sl@0: iExpectedDstBytesAdded[i] = 0; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to MULAW Pass in zero sized source buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0239::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToMuLaw}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, 0, KPCM16ToMulawOptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0240::CTest_MMF_ACOD_U_0240() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0240-HP"); sl@0: sl@0: iExpectedLeaveErrorCode = KErrArgument; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to MULAW Pass in zero sized destination buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0240::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToMuLaw}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToMulawOptimumSrc, 0)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0241::CTest_MMF_ACOD_U_0241() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0241-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to MULAW Test out of memory sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0241::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {KMmfUidHwDevicePCM16ToMuLaw}; sl@0: TBool testOK = EFalse; sl@0: sl@0: // TRAPD(err, testOK = TestNewLOutOfMemoryL(codecUid)); sl@0: TInt err = KErrNone; sl@0: if (err==KErrNone && testOK) sl@0: TRAP(err, testOK = TestProcessLOutOfMemoryL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0242::CTest_MMF_ACOD_U_0242() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0242-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to MULAW Test for memory leaks sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0242::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {KMmfUidHwDevicePCM16ToMuLaw}; sl@0: TBool testOK = EFalse; sl@0: TRAPD(err, testOK = TestMemoryLeakL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0243::CTest_MMF_ACOD_U_0243() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0243-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to MULAW Test for memory scribbles sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0243::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToMuLaw}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestMemoryScribbleL(codecUid)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0244::CTest_MMF_ACOD_U_0244() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0244-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0; sl@0: iExpectedDstBytesAdded[i] = 0; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAD To PCM16 Pass in zero sized source buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0244::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceIMAADPCMToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, 0, KAdpcmToPCM16OptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0245::CTest_MMF_ACOD_U_0245() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0245-HP"); sl@0: sl@0: iExpectedLeaveErrorCode = KErrArgument; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAD To PCM16 Pass in zero sized destination buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0245::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceIMAADPCMToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KAdpcmToPCM16OptimumSrc, 0)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0246::CTest_MMF_ACOD_U_0246() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0246-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAD To PCM16 Test out of memory sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0246::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {KMmfUidHwDeviceIMAADPCMToPCM16}; sl@0: TBool testOK = EFalse; sl@0: sl@0: // TRAPD(err, testOK = TestNewLOutOfMemoryL(codecUid)); sl@0: TInt err = KErrNone ; sl@0: if (err==KErrNone && testOK) sl@0: TRAP(err, testOK = TestProcessLOutOfMemoryL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0247::CTest_MMF_ACOD_U_0247() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0247-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAD To PCM16 Test for memory leaks sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0247::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {KMmfUidHwDeviceIMAADPCMToPCM16}; sl@0: TBool testOK = EFalse; sl@0: TRAPD(err, testOK = TestMemoryLeakL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0248::CTest_MMF_ACOD_U_0248() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0248-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAD To PCM16 Test for memory scribbles sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0248::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceIMAADPCMToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestMemoryScribbleL(codecUid)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0249::CTest_MMF_ACOD_U_0249() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0249-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0; sl@0: iExpectedDstBytesAdded[i] = 0; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to IMAD Pass in zero sized source buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0249::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToIMAADPCM}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, 0, KPCM16ToAdpcmOptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0250::CTest_MMF_ACOD_U_0250() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0250-HP"); sl@0: sl@0: iExpectedLeaveErrorCode = KErrArgument; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to IMAD Pass in zero sized destination buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0250::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToIMAADPCM}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToAdpcmOptimumSrc, 0)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0251::CTest_MMF_ACOD_U_0251() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0251-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to IMAD Test out of memory sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0251::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {KMmfUidHwDevicePCM16ToIMAADPCM}; sl@0: TBool testOK = EFalse; sl@0: sl@0: // TRAPD(err, testOK = TestNewLOutOfMemoryL(codecUid)); sl@0: TInt err = KErrNone; sl@0: if (err==KErrNone && testOK) sl@0: TRAP(err, testOK = TestProcessLOutOfMemoryL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0252::CTest_MMF_ACOD_U_0252() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0252-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to IMAD Test for memory leaks sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0252::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {KMmfUidHwDevicePCM16ToIMAADPCM}; sl@0: TBool testOK = EFalse; sl@0: TRAPD(err, testOK = TestMemoryLeakL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0253::CTest_MMF_ACOD_U_0253() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0253-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to IMAD Test for memory scribbles sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0253::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToIMAADPCM}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestMemoryScribbleL(codecUid)); sl@0: TInt err = KErrNone; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0254::CTest_MMF_ACOD_U_0254() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0254-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0; sl@0: iExpectedDstBytesAdded[i] = 0; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAS To PCM16 Pass in zero sized source buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0254::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {0}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, 0, KStereoAdpcmToPCM16OptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0255::CTest_MMF_ACOD_U_0255() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0255-HP"); sl@0: sl@0: iExpectedLeaveErrorCode = KErrArgument; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAS To PCM16 Pass in zero sized destination buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0255::DoTestStepL() sl@0: { sl@0: //const TUid codecUid = {0}; sl@0: TBool testOK = EFalse; sl@0: //TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KStereoAdpcmToPCM16OptimumSrc, 0)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0256::CTest_MMF_ACOD_U_0256() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0256-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAS To PCM16 Test out of memory sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0256::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {0}; sl@0: TBool testOK = EFalse; sl@0: sl@0: // TRAPD(err, testOK = TestNewLOutOfMemoryL(codecUid)); sl@0: TInt err = KErrNone; sl@0: if (err==KErrNone && testOK) sl@0: TRAP(err, testOK = TestProcessLOutOfMemoryL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0257::CTest_MMF_ACOD_U_0257() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0257-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAS To PCM16 Test for memory leaks sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0257::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {0}; sl@0: TBool testOK = EFalse; sl@0: TRAPD(err, testOK = TestMemoryLeakL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0258::CTest_MMF_ACOD_U_0258() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0258-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * IMAS To PCM16 Test for memory scribbles sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0258::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {0}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestMemoryScribbleL(codecUid)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0259::CTest_MMF_ACOD_U_0259() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0259-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0; sl@0: iExpectedDstBytesAdded[i] = 0; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to IMAS Pass in zero sized source buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0259::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {0}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, 0, KPCM16ToStereoAdpcmOptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0260::CTest_MMF_ACOD_U_0260() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0260-HP"); sl@0: sl@0: iExpectedLeaveErrorCode = KErrArgument; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to IMAS Pass in zero sized destination buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0260::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {0}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToStereoAdpcmOptimumSrc, 0)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0261::CTest_MMF_ACOD_U_0261() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0261-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to IMAS Test out of memory sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0261::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {0}; sl@0: TBool testOK = EFalse; sl@0: sl@0: // TRAPD(err, testOK = TestNewLOutOfMemoryL(codecUid)); sl@0: TInt err = KErrNone; sl@0: if (err==KErrNone && testOK) sl@0: TRAP(err, testOK = TestProcessLOutOfMemoryL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0262::CTest_MMF_ACOD_U_0262() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0262-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to IMAS Test for memory leaks sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0262::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {0}; sl@0: TBool testOK = EFalse; sl@0: TRAPD(err, testOK = TestMemoryLeakL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0263::CTest_MMF_ACOD_U_0263() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0263-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to IMAS Test for memory scribbles sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0263::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {0}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestMemoryScribbleL(codecUid)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0264::CTest_MMF_ACOD_U_0264() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0264-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0; sl@0: iExpectedDstBytesAdded[i] = 0; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * GSM610 To PCM16 Pass in zero sized source buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0264::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceGSM610ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, 0, KGSM610ToPCM16OptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0265::CTest_MMF_ACOD_U_0265() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0265-HP"); sl@0: sl@0: iExpectedLeaveErrorCode = KErrArgument; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * GSM610 To PCM16 Pass in zero sized destination buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0265::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceGSM610ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KGSM610ToPCM16OptimumSrc, 0)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0266::CTest_MMF_ACOD_U_0266() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0266-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * GSM610 To PCM16 Test out of memory sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0266::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {KMmfUidHwDeviceGSM610ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: sl@0: // TRAPD(err, testOK = TestNewLOutOfMemoryL(codecUid)); sl@0: TInt err = KErrNone; sl@0: if (err==KErrNone && testOK) sl@0: TRAP(err, testOK = TestProcessLOutOfMemoryL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0267::CTest_MMF_ACOD_U_0267() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0267-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * GSM610 To PCM16 Test for memory leaks sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0267::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {KMmfUidHwDeviceGSM610ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: TRAPD(err, testOK = TestMemoryLeakL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0268::CTest_MMF_ACOD_U_0268() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0268-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * GSM610 To PCM16 Test for memory scribbles sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0268::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDeviceGSM610ToPCM16}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestMemoryScribbleL(codecUid)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0269::CTest_MMF_ACOD_U_0269() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0269-HP"); sl@0: sl@0: for (TUint i=0; i<5; i++) sl@0: { sl@0: iExpectedSrcBytesProcessed[i] = 0; sl@0: iExpectedDstBytesAdded[i] = 0; sl@0: iExpectedReturnValue[i].iStatus = TCodecProcessResult::EDstNotFilled; sl@0: } sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to GSM610 Pass in zero sized source buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0269::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToGSM610}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, 0, KPCM16ToGSM610OptimumDst)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0270::CTest_MMF_ACOD_U_0270() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0270-HP"); sl@0: sl@0: iExpectedLeaveErrorCode = KErrArgument; sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to GSM610 Pass in zero sized destination buffer sl@0: * @test Req. under test REQ172.6.4, REQ172.6.5 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0270::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToGSM610}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestProcessLLoopFiveTimesL(codecUid, KPCM16ToGSM610OptimumSrc, 0)); sl@0: TInt err = KErrNone; sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0271::CTest_MMF_ACOD_U_0271() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0271-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to GSM610 Test out of memory sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0271::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {KMmfUidHwDevicePCM16ToGSM610}; sl@0: TBool testOK = EFalse; sl@0: sl@0: // TRAPD(err, testOK = TestNewLOutOfMemoryL(codecUid)); sl@0: TInt err = KErrNone; sl@0: if (err==KErrNone && testOK) sl@0: TRAP(err, testOK = TestProcessLOutOfMemoryL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0272::CTest_MMF_ACOD_U_0272() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0272-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to GSM610 Test for memory leaks sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0272::DoTestStepL() sl@0: { sl@0: const TUid codecUid = {KMmfUidHwDevicePCM16ToGSM610}; sl@0: TBool testOK = EFalse; sl@0: TRAPD(err, testOK = TestMemoryLeakL(codecUid)); sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: sl@0: /** @xxxx sl@0: * Constructor sl@0: */ sl@0: CTest_MMF_ACOD_U_0273::CTest_MMF_ACOD_U_0273() sl@0: { sl@0: // store the name of this test case sl@0: // this is the name that is used by the script file sl@0: // Each test step initialises it's own name sl@0: iTestStepName = _L("MM-MMF-ACOD-U-0273-HP"); sl@0: } sl@0: sl@0: /** @xxxx sl@0: * PCM16 to GSM610 Test for memory scribbles sl@0: * @test Req. under test REQ172.11 sl@0: */ sl@0: TVerdict CTest_MMF_ACOD_U_0273::DoTestStepL() sl@0: { sl@0: // const TUid codecUid = {KMmfUidHwDevicePCM16ToGSM610}; sl@0: TBool testOK = EFalse; sl@0: // TRAPD(err, testOK = TestMemoryScribbleL(codecUid)); sl@0: TInt err = KErrNone; sl@0: sl@0: if (err) sl@0: { sl@0: INFO_PRINTF2(_L("Test left with status %d"), err); sl@0: return EFail; sl@0: } sl@0: else if (!testOK) sl@0: { sl@0: INFO_PRINTF1(_L("Test failed")); sl@0: return EFail; sl@0: } sl@0: else sl@0: return EPass; sl@0: } sl@0: sl@0: //------------------------------------------------------------------ sl@0: