sl@0: // Copyright (c) 2007-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: LOAD_SUITE tsi_a3f_devsound.dll sl@0: sl@0: sl@0: //! @SYMTestCaseID MM-A3F-DEVSOUND-PLAY-PCM-I-0016 sl@0: //! @SYMTestCaseDesc Positive: PCM 48k stereo playback of sine audio data (+ve) sl@0: //! @SYMTestPriority High sl@0: //! @SYMTestType CIT sl@0: //! @SYMREQ 7918 sl@0: //! @SYMPREQ 1540 sl@0: //! @SYMTestActions 1. Configure DevSound to play PCM16 raw sine audio data in stereo mode with sampling rate of 48 KHz. sl@0: //! 2. Start playing and read recorded data from file. sl@0: //! 3. Stop playback once EOF is reached. sl@0: //! @SYMTestExpectedResults Devsound to successfully play PCM16 raw sine audio data in stereo mode with sampling rate of 48 KHz with all the DevSound callback functions sl@0: //! being executed as required throughout the test. sl@0: sl@0: RUN_TEST_STEP 600000 TSI_A3F_DEVSOUND MM-A3F-DEVSOUND-PLAY-PCM-I-0016 \tsi_a3f_devsound\tsi_a3f_devsound_play.ini sl@0: TEST_COMPLETE sl@0: sl@0: sl@0: //! @SYMTestCaseID MM-A3F-DEVSOUND-PLAY-PCM-I-0018 sl@0: //! @SYMTestCaseDesc Negative: PCM mono playback with invalid sample rate (-ve) sl@0: //! @SYMTestPriority High sl@0: //! @SYMTestType CIT sl@0: //! @SYMREQ 7927 sl@0: //! @SYMPREQ 1540 sl@0: //! @SYMTestActions 1. Configure DevSound to play PCM16 raw audio data in mono mode with an invalid sample rate. sl@0: //! 2. Verify the valid error code is received sl@0: //! @SYMTestExpectedResults CMMFDevSound::SetConfigL should return with KErrArgument sl@0: sl@0: RUN_TEST_STEP 600000 TSI_A3F_DEVSOUND MM-A3F-DEVSOUND-PLAY-PCM-I-0018 \tsi_a3f_devsound\tsi_a3f_devsound_play.ini sl@0: TEST_COMPLETE sl@0: sl@0: //! @SYMTestCaseID MM-A3F-DEVSOUND-PLAY-PCM-I-0019 sl@0: //! @SYMTestCaseDesc Negative: PCM 8k playback with invalid channel mode (-ve) sl@0: //! @SYMTestPriority High sl@0: //! @SYMTestType CIT sl@0: //! @SYMREQ 7927 sl@0: //! @SYMPREQ 1540 sl@0: //! @SYMTestActions 1. Configure DevSound to play PCM16 raw audio data in an invalid mode with sampling rate of 8 kHz. sl@0: //! 2. Verify the valid error code is received sl@0: //! @SYMTestExpectedResults CMMFDevSound::SetConfigL should return with KErrArgument sl@0: sl@0: RUN_TEST_STEP 600000 TSI_A3F_DEVSOUND MM-A3F-DEVSOUND-PLAY-PCM-I-0019 \tsi_a3f_devsound\tsi_a3f_devsound_play.ini sl@0: TEST_COMPLETE sl@0: sl@0: //! @SYMTestCaseID MM-A3F-DEVSOUND-PLAY-PCM-I-0020 sl@0: //! @SYMTestCaseDesc Negative: PCM 8k mono playback with invalid FourCC (-ve) sl@0: //! @SYMTestPriority High sl@0: //! @SYMTestType CIT sl@0: //! @SYMREQ 7927 sl@0: //! @SYMPREQ 1540 sl@0: //! @SYMTestActions 1. Initialise DevSound with an invalid FourCC code sl@0: //! 2. Verify the valid error code is received sl@0: //! @SYMTestExpectedResults CMMFDevSound::InitializeL should return with KErrNotSupported sl@0: sl@0: RUN_TEST_STEP 600000 TSI_A3F_DEVSOUND MM-A3F-DEVSOUND-PLAY-PCM-I-0020 \tsi_a3f_devsound\tsi_a3f_devsound_play.ini sl@0: TEST_COMPLETE sl@0: sl@0: //! @SYMTestCaseID MM-A3F-DEVSOUND-PLAY-PCM-I-0021 sl@0: //! @SYMTestCaseDesc Negative: PCM 8k mono playback of corrupt file (-ve) sl@0: //! @SYMTestPriority High sl@0: //! @SYMTestType CIT sl@0: //! @SYMREQ 7927 sl@0: //! @SYMPREQ 1540 sl@0: //! @SYMTestStatus sl@0: //! @SYMTestActions 1. Configure DevSound to play PCM8 raw audio data in mono mode with sampling rate of 8 kHz. sl@0: //! 2. Start playing and read recorded data from file. sl@0: //! 3. Stop playback once EOF is reached. sl@0: //! @SYMTestExpectedResults Devsound to successfully play PCM8 audio data in mono mode with sampling rate of 8 KHz with all the DevSound callback functions sl@0: //! being executed as required throughout the test. sl@0: sl@0: RUN_TEST_STEP 600000 TSI_A3F_DEVSOUND MM-A3F-DEVSOUND-PLAY-PCM-I-0021 \tsi_a3f_devsound\tsi_a3f_devsound_play.ini sl@0: TEST_COMPLETE sl@0: sl@0: //! @SYMTestCaseID MM-A3F-DEVSOUND-PLAY-PCM-I-0022 sl@0: //! @SYMTestCaseDesc Positive: Play to the EOF a specified number of times (+ve) sl@0: //! @SYMTestPriority High sl@0: //! @SYMTestType CIT sl@0: //! @SYMREQ 7918 sl@0: //! @SYMPREQ 1540 sl@0: //! @SYMTestStatus sl@0: //! @SYMTestActions 1. Configure DevSound to play PCM16 raw audio data in mono mode with sampling rate of 8 kHz. sl@0: //! 2. Start playing and read recorded data from file. sl@0: //! 3. Stop playback once EOF is reached. sl@0: //! 4. Restart playback again sl@0: //! 5. Stop test when EOF is reached again sl@0: //! @SYMTestExpectedResults Devsound to successfully play PCM16 audio data in mono mode with sampling rate of 8 KHz twice with all the DevSound callback sl@0: //! functions being executed as required throughout the test. sl@0: sl@0: RUN_TEST_STEP 600000 TSI_A3F_DEVSOUND MM-A3F-DEVSOUND-PLAY-PCM-I-0022 \tsi_a3f_devsound\tsi_a3f_devsound_play.ini sl@0: TEST_COMPLETE sl@0: sl@0: //! @SYMTestCaseID MM-A3F-DEVSOUND-PLAY-PCM-I-0023 sl@0: //! @SYMTestCaseDesc Positive: PCM playback with default parameters. Default FourCC input datatype and default config values (+ve) sl@0: //! @SYMTestPriority High sl@0: //! @SYMTestType CIT sl@0: //! @SYMREQ 7925 sl@0: //! @SYMPREQ 1540 sl@0: //! @SYMTestStatus sl@0: //! @SYMTestActions 1. Initialise DevSound for playback without specifying format nor configuration parameters sl@0: //! 2. Start playing and read recorded data from a PCM16/8 kHz file. sl@0: //! 3. Stop playback once EOF is reached. sl@0: //! @SYMTestExpectedResults Devsound to successfully play PCM16 audio data in mono mode with sampling rate of 8 KHz with all the DevSound callback functions sl@0: //! being executed as required throughout the test. sl@0: sl@0: RUN_TEST_STEP 600000 TSI_A3F_DEVSOUND MM-A3F-DEVSOUND-PLAY-PCM-I-0023 \tsi_a3f_devsound\tsi_a3f_devsound_play.ini sl@0: TEST_COMPLETE sl@0: sl@0: //! @SYMTestCaseID MM-A3F-DEVSOUND-PLAY-PCM-I-0024 sl@0: //! @SYMTestCaseDesc Positive: Play->Stop->Play->Stop->Play EOF. Stop is called a specified number of times through ini file. sl@0: //! Last playback continues until the EOF (+ve) sl@0: //! @SYMTestPriority High sl@0: //! @SYMTestType CIT sl@0: //! @SYMREQ 7919 sl@0: //! @SYMPREQ 1540 sl@0: //! @SYMTestStatus sl@0: //! @SYMTestActions 1. Configure DevSound to play PCM16 raw audio data in mono mode with sampling rate of 8 kHz. sl@0: //! 2. Start playing and read recorded data from file. sl@0: //! 3. Stop playback after 10 seconds. sl@0: //! 4. Restart playback sl@0: //! 5. Stop playback after 10 seconds. sl@0: //! 6. Restart playback sl@0: //! 7. Stop playback once EOF is reached. sl@0: //! @SYMTestExpectedResults Devsound to successfully play-stop-play-stop-play PCM16 audio data in mono mode with sampling rate of 8 KHz with all the DevSound callback sl@0: //! functions being executed as required throughout the test. sl@0: sl@0: RUN_TEST_STEP 600000 TSI_A3F_DEVSOUND MM-A3F-DEVSOUND-PLAY-PCM-I-0024 \tsi_a3f_devsound\tsi_a3f_devsound_play.ini sl@0: TEST_COMPLETE sl@0: sl@0: //! @SYMTestCaseID MM-A3F-DEVSOUND-PLAY-PCM-I-0025 sl@0: //! @SYMTestCaseDesc Positive: Read the current device configuration during playback (+ve) sl@0: //! @SYMTestPriority High sl@0: //! @SYMTestType CIT sl@0: //! @SYMREQ sl@0: //! @SYMPREQ 1540 sl@0: //! @SYMTestActions 1. Configure DevSound to play PCM16 raw audio data in mono mode with sampling rate of 8 kHz. sl@0: //! 2. Start playing and read recorded data from file. sl@0: //! 3. In the BuffertoBeFilled callback check the current device configuration matches the one set at the beginning of the test. sl@0: //! 4. Stop the test sl@0: //! @SYMTestExpectedResults Values queried during playback should match the ones set before the playback started sl@0: RUN_TEST_STEP 600000 TSI_A3F_DEVSOUND MM-A3F-DEVSOUND-PLAY-PCM-I-0025 \tsi_a3f_devsound\tsi_a3f_devsound_play.ini sl@0: TEST_COMPLETE sl@0: sl@0: //! @SYMTestCaseID MM-A3F-DEVSOUND-PLAY-PCM-I-0026 sl@0: //! @SYMTestCaseDesc Positive: Set volume before play, start play, stop play and get volume (+ve) sl@0: //! @SYMTestPriority High sl@0: //! @SYMTestType CIT sl@0: //! @SYMREQ sl@0: //! @SYMPREQ 1540 sl@0: //! @SYMTestActions 1. Configure DevSound to play PCM16 raw audio data in mono mode with sampling rate of 8 kHz. sl@0: //! 2. Set volume to a value specified in the ini file sl@0: //! 3. Start playing and read recorded data from file. sl@0: //! 4. Stop playback after 10 seconds and get the volume from DevSound sl@0: //! 5. Check the values match sl@0: //! @SYMTestExpectedResults The Volume after the playback has stopped should match the volume set before playback sl@0: RUN_TEST_STEP 600000 TSI_A3F_DEVSOUND MM-A3F-DEVSOUND-PLAY-PCM-I-0026 \tsi_a3f_devsound\tsi_a3f_devsound_play.ini sl@0: TEST_COMPLETE sl@0: sl@0: //! @SYMTestCaseID MM-A3F-DEVSOUND-PLAY-PCM-I-0027 sl@0: //! @SYMTestCaseDesc Positive: Empty buffers when playback paused (+ve) sl@0: //! @SYMTestPriority High sl@0: //! @SYMTestType CIT sl@0: //! @SYMREQ 7926 sl@0: //! @SYMPREQ 1540 sl@0: //! @SYMTestActions 1. Configure DevSound to play PCM16 raw audio data in mono mode with sampling rate of 8 kHz. sl@0: //! 2. Start playing and read recorded data from file. sl@0: //! 3. Pause playback after 10 seconds sl@0: //! 4. Call EmptyBuffers while in paused state sl@0: //! @SYMTestExpectedResults EmptyBuffers in paused state should return with KErrNone sl@0: sl@0: RUN_TEST_STEP 600000 TSI_A3F_DEVSOUND MM-A3F-DEVSOUND-PLAY-PCM-I-0027 \tsi_a3f_devsound\tsi_a3f_devsound_play.ini sl@0: TEST_COMPLETE sl@0: