1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1.2 +++ b/os/mm/devsound/a3fcharacterisationtest/src/char_a3f_devsound_playtest.h Fri Jun 15 03:10:57 2012 +0200
1.3 @@ -0,0 +1,872 @@
1.4 +// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
1.5 +// All rights reserved.
1.6 +// This component and the accompanying materials are made available
1.7 +// under the terms of "Eclipse Public License v1.0"
1.8 +// which accompanies this distribution, and is available
1.9 +// at the URL "http://www.eclipse.org/legal/epl-v10.html".
1.10 +//
1.11 +// Initial Contributors:
1.12 +// Nokia Corporation - initial contribution.
1.13 +//
1.14 +// Contributors:
1.15 +//
1.16 +// Description:
1.17 +//
1.18 +
1.19 +#ifndef CHAR_A3F_DEVSOUND_PLAYTEST_H
1.20 +#define CHAR_A3F_DEVSOUND_PLAYTEST_H
1.21 +
1.22 +// User includes
1.23 +#include "char_a3f_devsound_testbase.h"
1.24 +#include "char_a3f_devsound_playrecordclients.h"
1.25 +#include "char_a3f_devsound_toneclient.h"
1.26 +
1.27 +/*
1.28 + *========================================================================================================
1.29 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0001
1.30 + */
1.31 +class RA3FDevSoundPlaySetConfigTest : public RA3FDevSoundTestBase
1.32 + {
1.33 +public:
1.34 + static RA3FDevSoundPlaySetConfigTest* NewL(const TDesC& aTestName);
1.35 +
1.36 +private:
1.37 + RA3FDevSoundPlaySetConfigTest(const TDesC& aTestName);
1.38 + void DoKickoffTestL();
1.39 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.40 +
1.41 +private:
1.42 + TMMFSampleRate iESampleRate;
1.43 + TInt iSampleRate;
1.44 + TInt iChannels;
1.45 + };
1.46 +
1.47 +/*
1.48 + *========================================================================================================
1.49 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0002
1.50 + */
1.51 +class RA3FDevSoundPlaySetVolumeWhilePlayingTest : public RA3FDevSoundTestBase
1.52 + {
1.53 +public:
1.54 + static RA3FDevSoundPlaySetVolumeWhilePlayingTest* NewL(const TDesC& aTestName);
1.55 +
1.56 +private:
1.57 + RA3FDevSoundPlaySetVolumeWhilePlayingTest(const TDesC& aTestName);
1.58 + void DoKickoffTestL();
1.59 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.60 + void DoTimerCallback();
1.61 +private:
1.62 + TInt iVolume;
1.63 + TFileName iFilename;
1.64 + };
1.65 +
1.66 +/*
1.67 + *========================================================================================================
1.68 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0003
1.69 + */
1.70 +class RA3FDevSoundPlaySetVolumeTest : public RA3FDevSoundTestBase
1.71 + {
1.72 +public:
1.73 + static RA3FDevSoundPlaySetVolumeTest* NewL(const TDesC& aTestName);
1.74 +
1.75 +private:
1.76 + RA3FDevSoundPlaySetVolumeTest(const TDesC& aTestName);
1.77 + void DoKickoffTestL();
1.78 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.79 +
1.80 +private:
1.81 + TInt iVolume;
1.82 + };
1.83 +
1.84 +/*
1.85 + *========================================================================================================
1.86 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0004
1.87 + */
1.88 +class RA3FDevSoundPlaySetVolumeWhilePausedPlayingTest : public RA3FDevSoundTestBase
1.89 + {
1.90 +public:
1.91 + static RA3FDevSoundPlaySetVolumeWhilePausedPlayingTest* NewL(const TDesC& aTestName);
1.92 +
1.93 +private:
1.94 + RA3FDevSoundPlaySetVolumeWhilePausedPlayingTest(const TDesC& aTestName);
1.95 + void DoKickoffTestL();
1.96 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.97 + void DoTimerCallback();
1.98 +
1.99 +private:
1.100 + TFileName iFilename;
1.101 + TInt iVolume;
1.102 + };
1.103 +
1.104 +/*
1.105 + *========================================================================================================
1.106 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0005
1.107 + */
1.108 +class RA3FDevSoundPlaySetVolumeInitializeToPlayAudioThenTonesTest: public RA3FDevSoundTestBase
1.109 + {
1.110 +public:
1.111 + static RA3FDevSoundPlaySetVolumeInitializeToPlayAudioThenTonesTest* NewL(const TDesC& aTestName);
1.112 +
1.113 +private:
1.114 + RA3FDevSoundPlaySetVolumeInitializeToPlayAudioThenTonesTest(const TDesC& aTestName);
1.115 + void DoKickoffTestL();
1.116 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.117 +
1.118 +private:
1.119 + TBool iReinitialized;
1.120 + TInt iVolume;
1.121 + };
1.122 +
1.123 +/*
1.124 + *========================================================================================================
1.125 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0006
1.126 + */
1.127 +class RA3FDevSoundPlaySetVolumeRampWhilePlayingTest : public RA3FDevSoundTestBase
1.128 + {
1.129 +public:
1.130 + static RA3FDevSoundPlaySetVolumeRampWhilePlayingTest* NewL(const TDesC& aTestName);
1.131 +
1.132 +private:
1.133 + RA3FDevSoundPlaySetVolumeRampWhilePlayingTest(const TDesC& aTestName);
1.134 + void DoKickoffTestL();
1.135 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.136 + void DoTimerCallback();
1.137 + void PlayError(TInt aError);
1.138 +
1.139 +private:
1.140 + TFileName iFilename;
1.141 + TInt iVolumeRamp;
1.142 + TBool iPlayInitTwice;
1.143 + };
1.144 +
1.145 +/*
1.146 + *========================================================================================================
1.147 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0007
1.148 + */
1.149 +class RA3FDevSoundPlaySetVolumeBeyondMaxVolumeTest : public RA3FDevSoundTestBase
1.150 + {
1.151 +public:
1.152 + static RA3FDevSoundPlaySetVolumeBeyondMaxVolumeTest* NewL(const TDesC& aTestName);
1.153 +
1.154 +private:
1.155 + RA3FDevSoundPlaySetVolumeBeyondMaxVolumeTest(const TDesC& aTestName);
1.156 + void DoKickoffTestL();
1.157 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.158 + };
1.159 +
1.160 +/*
1.161 + *========================================================================================================
1.162 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0008
1.163 + */
1.164 +class RA3FDevSoundPlaySetVolumeToNegativeTest : public RA3FDevSoundTestBase
1.165 + {
1.166 +public:
1.167 + static RA3FDevSoundPlaySetVolumeToNegativeTest* NewL(const TDesC& aTestName);
1.168 +
1.169 +private:
1.170 + RA3FDevSoundPlaySetVolumeToNegativeTest(const TDesC& aTestName);
1.171 + void DoKickoffTestL();
1.172 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.173 +
1.174 +private:
1.175 + TInt iVolume;
1.176 + };
1.177 +
1.178 +/*
1.179 + *========================================================================================================
1.180 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0009
1.181 + */
1.182 +class RA3FDevSoundPlaySetPlayBalanceBeyondOneHundredTest : public RA3FDevSoundTestBase
1.183 + {
1.184 +public:
1.185 + static RA3FDevSoundPlaySetPlayBalanceBeyondOneHundredTest* NewL(const TDesC& aTestName);
1.186 +
1.187 +private:
1.188 + RA3FDevSoundPlaySetPlayBalanceBeyondOneHundredTest(const TDesC& aTestName);
1.189 + void DoKickoffTestL();
1.190 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.191 +
1.192 +private:
1.193 + TInt iLSpeakerBalance;
1.194 + TInt iRSpeakerBalance;
1.195 + };
1.196 +
1.197 +/*
1.198 + *========================================================================================================
1.199 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0010
1.200 + */
1.201 +class RA3FDevSoundPlaySetPlayBalanceToNegativeTest : public RA3FDevSoundTestBase
1.202 + {
1.203 +public:
1.204 + static RA3FDevSoundPlaySetPlayBalanceToNegativeTest* NewL(const TDesC& aTestName);
1.205 +
1.206 +private:
1.207 + RA3FDevSoundPlaySetPlayBalanceToNegativeTest(const TDesC& aTestName);
1.208 + void DoKickoffTestL();
1.209 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.210 +
1.211 +private:
1.212 + TInt iLSpeakerBalance;
1.213 + TInt iRSpeakerBalance;
1.214 + };
1.215 +
1.216 +/*
1.217 + *========================================================================================================
1.218 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0011
1.219 + */
1.220 +class RA3FDevSoundPlaySetPrioritySettingsTest : public RA3FDevSoundTestBase
1.221 + {
1.222 +public:
1.223 + static RA3FDevSoundPlaySetPrioritySettingsTest* NewL(const TDesC& aTestName);
1.224 +
1.225 +private:
1.226 + RA3FDevSoundPlaySetPrioritySettingsTest(const TDesC& aTestName);
1.227 + void DoKickoffTestL();
1.228 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.229 +
1.230 +private:
1.231 + TInt iPriority;
1.232 + };
1.233 +
1.234 +/*
1.235 + *========================================================================================================
1.236 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0012
1.237 + */
1.238 +class RA3FDevSoundPlayCapabilitiesTest : public RA3FDevSoundTestBase
1.239 + {
1.240 +public:
1.241 + static RA3FDevSoundPlayCapabilitiesTest* NewL(const TDesC& aTestName);
1.242 +
1.243 +private:
1.244 + RA3FDevSoundPlayCapabilitiesTest(const TDesC& aTestName);
1.245 + void DoKickoffTestL();
1.246 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.247 +
1.248 +private:
1.249 + TInt iExCapChannels;
1.250 + TInt iExCapRate;
1.251 + };
1.252 +
1.253 +/*
1.254 + *========================================================================================================
1.255 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0013
1.256 + */
1.257 +class RA3FDevSoundPlayConfigTest : public RA3FDevSoundTestBase
1.258 + {
1.259 +public:
1.260 + static RA3FDevSoundPlayConfigTest* NewL(const TDesC& aTestName);
1.261 +
1.262 +private:
1.263 + RA3FDevSoundPlayConfigTest(const TDesC& aTestName);
1.264 + void DoKickoffTestL();
1.265 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.266 +
1.267 +private:
1.268 + TMMFSampleRate iESampleRate;
1.269 + TMMFSampleRate iExSampleRate;
1.270 + TInt iExCapRate;
1.271 + TInt iExCapChannels;
1.272 + };
1.273 +
1.274 +/*
1.275 + *========================================================================================================
1.276 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0014
1.277 + */
1.278 +class RA3FDevSoundPlayGetPlayBalanceTest : public RA3FDevSoundTestBase
1.279 + {
1.280 +public:
1.281 + static RA3FDevSoundPlayGetPlayBalanceTest* NewL(const TDesC& aTestName);
1.282 +
1.283 +private:
1.284 + RA3FDevSoundPlayGetPlayBalanceTest(const TDesC& aTestName);
1.285 + void DoKickoffTestL();
1.286 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.287 +
1.288 +private:
1.289 + TInt iExLSpeakerBalance;
1.290 + TInt iExRSpeakerBalance;
1.291 + };
1.292 +
1.293 +/*
1.294 + *========================================================================================================
1.295 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0015
1.296 + */
1.297 +class RA3FDevSoundPlayGetSupportedInputDataTypesLTest : public RA3FDevSoundTestBase
1.298 + {
1.299 +public:
1.300 + static RA3FDevSoundPlayGetSupportedInputDataTypesLTest* NewL(const TDesC& aTestName);
1.301 +
1.302 +private:
1.303 + RA3FDevSoundPlayGetSupportedInputDataTypesLTest(const TDesC& aTestName);
1.304 + void DoKickoffTestL();
1.305 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.306 +
1.307 +private:
1.308 + RArray<TFourCC> iSupportedDataTypes;
1.309 + TInt iCurrentTypeInTest;
1.310 + };
1.311 +
1.312 +/*
1.313 + *========================================================================================================
1.314 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0016
1.315 + */
1.316 +class RA3FDevSoundPlayMaxVolumeTest : public RA3FDevSoundTestBase
1.317 + {
1.318 +public:
1.319 + static RA3FDevSoundPlayMaxVolumeTest* NewL(const TDesC& aTestName);
1.320 +
1.321 +private:
1.322 + RA3FDevSoundPlayMaxVolumeTest(const TDesC& aTestName);
1.323 + void DoKickoffTestL();
1.324 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.325 +
1.326 +private:
1.327 + TInt iExVolume;
1.328 + };
1.329 +
1.330 +/*
1.331 + *========================================================================================================
1.332 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0017
1.333 + */
1.334 +class RA3FDevSoundPlaySamplesPlayedTest : public RA3FDevSoundTestBase
1.335 + {
1.336 +public:
1.337 + static RA3FDevSoundPlaySamplesPlayedTest* NewL(const TDesC& aTestName);
1.338 +
1.339 +private:
1.340 + RA3FDevSoundPlaySamplesPlayedTest(const TDesC& aTestName);
1.341 + void DoKickoffTestL();
1.342 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.343 +
1.344 +private:
1.345 + TInt iExSamplesPlayed;
1.346 + };
1.347 +
1.348 +/*
1.349 + *========================================================================================================
1.350 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0018
1.351 + */
1.352 +class RA3FDevSoundPlayVolumeTest : public RA3FDevSoundTestBase
1.353 + {
1.354 +public:
1.355 + static RA3FDevSoundPlayVolumeTest* NewL(const TDesC& aTestName);
1.356 +
1.357 +private:
1.358 + RA3FDevSoundPlayVolumeTest(const TDesC& aTestName);
1.359 + void DoKickoffTestL();
1.360 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.361 +
1.362 +private:
1.363 + TInt iExVolume;
1.364 + };
1.365 +
1.366 +/*
1.367 + *========================================================================================================
1.368 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0019
1.369 + */
1.370 +class RA3FDevSoundPlayCapabilitiesWhilePlayingTest : public RA3FDevSoundTestBase
1.371 + {
1.372 +public:
1.373 + static RA3FDevSoundPlayCapabilitiesWhilePlayingTest* NewL(const TDesC& aTestName);
1.374 +
1.375 +private:
1.376 + RA3FDevSoundPlayCapabilitiesWhilePlayingTest(const TDesC& aTestName);
1.377 + void DoKickoffTestL();
1.378 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.379 + void DoTimerCallback();
1.380 +
1.381 +private:
1.382 + TFileName iFilename;
1.383 + TInt iExCapChannels;
1.384 + TInt iExCapRate;
1.385 + };
1.386 +
1.387 +/*
1.388 + *========================================================================================================
1.389 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0020
1.390 + */
1.391 +class RA3FDevSoundPlayConfigWhilePlayingTest : public RA3FDevSoundTestBase
1.392 + {
1.393 +public:
1.394 + static RA3FDevSoundPlayConfigWhilePlayingTest* NewL(const TDesC& aTestName);
1.395 +
1.396 +private:
1.397 + RA3FDevSoundPlayConfigWhilePlayingTest(const TDesC& aTestName);
1.398 + void DoKickoffTestL();
1.399 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.400 + void DoTimerCallback();
1.401 +
1.402 +private:
1.403 + TFileName iFilename;
1.404 + TMMFSampleRate iExSampleRate;
1.405 + TInt iExCapRate;
1.406 + TInt iExCapChannels;
1.407 + };
1.408 +
1.409 +/*
1.410 + *========================================================================================================
1.411 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0021
1.412 + */
1.413 +class RA3FDevSoundPlayGetPlayBalanceWhilePlayingTest : public RA3FDevSoundTestBase
1.414 + {
1.415 +public:
1.416 + static RA3FDevSoundPlayGetPlayBalanceWhilePlayingTest* NewL(const TDesC& aTestName);
1.417 +
1.418 +private:
1.419 + RA3FDevSoundPlayGetPlayBalanceWhilePlayingTest(const TDesC& aTestName);
1.420 + void DoKickoffTestL();
1.421 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.422 + void DoTimerCallback();
1.423 +
1.424 +private:
1.425 + TFileName iFilename;
1.426 + TInt iExLSpeakerBalance;
1.427 + TInt iExRSpeakerBalance;
1.428 + };
1.429 +
1.430 +/*
1.431 + *========================================================================================================
1.432 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0022
1.433 + */
1.434 +class RA3FDevSoundPlayGetSupportedInputDataTypesWhilePlayingTest : public RA3FDevSoundTestBase
1.435 + {
1.436 +public:
1.437 + static RA3FDevSoundPlayGetSupportedInputDataTypesWhilePlayingTest* NewL(const TDesC& aTestName);
1.438 +
1.439 +private:
1.440 + RA3FDevSoundPlayGetSupportedInputDataTypesWhilePlayingTest(const TDesC& aTestName);
1.441 + void DoKickoffTestL();
1.442 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.443 + void DoTimerCallback();
1.444 +private:
1.445 + TFileName iFilename;
1.446 + };
1.447 +
1.448 +/*
1.449 + *========================================================================================================
1.450 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0023
1.451 + */
1.452 +class RA3FDevSoundPlayMaxVolumeWhilePlayingTest : public RA3FDevSoundTestBase
1.453 + {
1.454 +public:
1.455 + static RA3FDevSoundPlayMaxVolumeWhilePlayingTest* NewL(const TDesC& aTestName);
1.456 +
1.457 +private:
1.458 + RA3FDevSoundPlayMaxVolumeWhilePlayingTest(const TDesC& aTestName);
1.459 + void DoKickoffTestL();
1.460 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.461 + void DoTimerCallback();
1.462 +
1.463 +private:
1.464 + TFileName iFilename;
1.465 + TInt iExVolume;
1.466 + };
1.467 +
1.468 +/*
1.469 + *========================================================================================================
1.470 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0024
1.471 + */
1.472 +class RA3FDevSoundPlaySamplesPlayedWhilePlayingTest : public RA3FDevSoundTestBase
1.473 + {
1.474 +public:
1.475 + static RA3FDevSoundPlaySamplesPlayedWhilePlayingTest* NewL(const TDesC& aTestName);
1.476 +
1.477 +private:
1.478 + RA3FDevSoundPlaySamplesPlayedWhilePlayingTest(const TDesC& aTestName);
1.479 + void DoKickoffTestL();
1.480 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.481 + void DoTimerCallback();
1.482 +
1.483 +private:
1.484 + TFileName iFilename;
1.485 + TInt iExSamplesPlayed;
1.486 + };
1.487 +
1.488 +/*
1.489 + *========================================================================================================
1.490 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0025
1.491 + */
1.492 +class RA3FDevSoundPlayVolumeWhilePlayingTest : public RA3FDevSoundTestBase
1.493 + {
1.494 +public:
1.495 + static RA3FDevSoundPlayVolumeWhilePlayingTest* NewL(const TDesC& aTestName);
1.496 +
1.497 +private:
1.498 + RA3FDevSoundPlayVolumeWhilePlayingTest(const TDesC& aTestName);
1.499 + void DoKickoffTestL();
1.500 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.501 + void DoTimerCallback();
1.502 +
1.503 +private:
1.504 + TFileName iFilename;
1.505 + TInt iExVolume;
1.506 + };
1.507 +
1.508 +/*
1.509 + *========================================================================================================
1.510 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0026
1.511 + */
1.512 +class RA3FDevSoundPlayTest : public RA3FDevSoundTestBase
1.513 + {
1.514 +public:
1.515 + static RA3FDevSoundPlayTest* NewL(const TDesC& aTestName);
1.516 +
1.517 +private:
1.518 + RA3FDevSoundPlayTest(const TDesC& aTestName);
1.519 + void DoKickoffTestL();
1.520 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.521 +
1.522 +private:
1.523 + TFileName iFilename;
1.524 + };
1.525 +
1.526 +/*
1.527 + *========================================================================================================
1.528 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0027
1.529 + */
1.530 +class RA3FDevSoundPlayEmptyBufferWhilePlayingTest : public RA3FDevSoundTestBase
1.531 + {
1.532 +public:
1.533 + static RA3FDevSoundPlayEmptyBufferWhilePlayingTest* NewL(const TDesC& aTestName);
1.534 +
1.535 +private:
1.536 + RA3FDevSoundPlayEmptyBufferWhilePlayingTest(const TDesC& aTestName);
1.537 + void DoKickoffTestL();
1.538 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.539 + void DoTimerCallback();
1.540 +
1.541 +private:
1.542 + TFileName iFilename;
1.543 + };
1.544 +
1.545 +/*
1.546 + *========================================================================================================
1.547 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0028
1.548 + */
1.549 +class RA3FDevSoundPlayEmptyBufferBeforePlayingTest : public RA3FDevSoundTestBase
1.550 + {
1.551 +public:
1.552 + static RA3FDevSoundPlayEmptyBufferBeforePlayingTest* NewL(const TDesC& aTestName);
1.553 +
1.554 +private:
1.555 + RA3FDevSoundPlayEmptyBufferBeforePlayingTest(const TDesC& aTestName);
1.556 + void DoKickoffTestL();
1.557 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.558 + };
1.559 +
1.560 +/*
1.561 + *========================================================================================================
1.562 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0029
1.563 + */
1.564 +class RA3FDevSoundPlayPauseTest : public RA3FDevSoundTestBase
1.565 + {
1.566 +public:
1.567 + static RA3FDevSoundPlayPauseTest* NewL(const TDesC& aTestName);
1.568 +
1.569 +private:
1.570 + RA3FDevSoundPlayPauseTest(const TDesC& aTestName);
1.571 + void DoKickoffTestL();
1.572 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.573 + void DoTimerCallback();
1.574 +
1.575 +private:
1.576 + TFileName iFilename;
1.577 + TBool iPaused;
1.578 + TInt iSamplesPlayedPaused;
1.579 + };
1.580 +
1.581 +/*
1.582 + *========================================================================================================
1.583 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0030
1.584 + */
1.585 +class RA3FDevSoundPlayStopTest : public RA3FDevSoundTestBase
1.586 + {
1.587 +public:
1.588 + static RA3FDevSoundPlayStopTest* NewL(const TDesC& aTestName);
1.589 +
1.590 +private:
1.591 + RA3FDevSoundPlayStopTest(const TDesC& aTestName);
1.592 + void DoKickoffTestL();
1.593 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.594 + void DoTimerCallback();
1.595 +
1.596 +private:
1.597 + TFileName iFilename;
1.598 + TBool iStopped;
1.599 + };
1.600 +
1.601 +/*
1.602 + *========================================================================================================
1.603 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0031
1.604 + */
1.605 +class RA3FDevSoundPlayPreemptionTest : public RA3FDevSoundTestBase, public MA3FDevsoundPlayAudioClientObserver
1.606 + {
1.607 +public:
1.608 + static RA3FDevSoundPlayPreemptionTest* NewL(const TDesC& aTestName);
1.609 +
1.610 +private:
1.611 + RA3FDevSoundPlayPreemptionTest(const TDesC& aTestName);
1.612 + void DoKickoffTestL();
1.613 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.614 + void PlayError(TInt aError);
1.615 + void DoTimerCallback();
1.616 + void ClientInitializeCompleteCallback(TInt aError);
1.617 + void ClientBufferToBeFilledCallback(TInt aError);
1.618 + void ClientPlayErrorCallback(TInt aError, TBool aLastBuffer);
1.619 + void ClientPlayHandleOpenFileErrorInValidEventOrStateCallBack(TMmfDevSoundClientErrorCodes aError);
1.620 +
1.621 +private:
1.622 + TFileName iFilename;
1.623 + TFileName iOtherFilename;
1.624 + };
1.625 +
1.626 +/*
1.627 + *========================================================================================================
1.628 + * 3F-DEVSOUND-CHRTZ-PLAY-RAW-0032
1.629 + */
1.630 +class RA3FDevSoundPlayPreemptedByToneTest : public RA3FDevSoundTestBase, public MA3FDevsoundToneClientObserver
1.631 + {
1.632 +public:
1.633 + static RA3FDevSoundPlayPreemptedByToneTest* NewL(const TDesC& aTestName);
1.634 +private:
1.635 + RA3FDevSoundPlayPreemptedByToneTest(const TDesC& aTestName);
1.636 + void PlayError(TInt aError);
1.637 + void ClientInitializeCompleteCallback(TInt aError);
1.638 + void ClientToneFinishedCallback(TInt aError);
1.639 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.640 + void DoKickoffTestL();
1.641 + void DoTimerCallback();
1.642 +
1.643 +private:
1.644 + TFileName iFilename;
1.645 + TInt iFrequencyTone1;
1.646 + TInt iDuration;
1.647 + };
1.648 +
1.649 +/*
1.650 + *========================================================================================================
1.651 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0033
1.652 + */
1.653 +class RA3FDevSoundPlayPreemptedByRecordTest : public RA3FDevSoundTestBase, public MA3FDevsoundRecordAudioClientObserver
1.654 + {
1.655 +public:
1.656 + static RA3FDevSoundPlayPreemptedByRecordTest* NewL(const TDesC& aTestName);
1.657 +private:
1.658 + RA3FDevSoundPlayPreemptedByRecordTest(const TDesC& aTestName);
1.659 + void PlayError(TInt aError);
1.660 + void DoKickoffTestL();
1.661 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.662 + void DoTimerCallback();
1.663 + void ClientInitializeCompleteCallback(TInt aError);
1.664 + void ClientBufferToBeEmptiedCallback(TInt aError);
1.665 + void ClientRecordErrorCallback(TInt aError);
1.666 + void ClientRecordHandleOpenFileErrorInValidEventOrStateCallBack(TMmfDevSoundClientErrorCodes aError);
1.667 +
1.668 +private:
1.669 + TInt iDuration;
1.670 + TBool iOtherClientStarted;
1.671 + TFileName iFilename;
1.672 + TFileName iOtherFilename;
1.673 + };
1.674 +
1.675 +/*
1.676 + *========================================================================================================
1.677 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0034
1.678 + */
1.679 +class RA3FDevSoundPlayRejectionTest : public RA3FDevSoundTestBase, public MA3FDevsoundPlayAudioClientObserver
1.680 + {
1.681 +public:
1.682 + static RA3FDevSoundPlayRejectionTest* NewL(const TDesC& aTestName);
1.683 +
1.684 +private:
1.685 + RA3FDevSoundPlayRejectionTest(const TDesC& aTestName);
1.686 + void DoKickoffTestL();
1.687 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.688 + void DoTimerCallback();
1.689 + void ClientInitializeCompleteCallback(TInt aError);
1.690 + void ClientBufferToBeFilledCallback(TInt aError);
1.691 + void ClientPlayErrorCallback(TInt aError, TBool aLastBuffer);
1.692 + void ClientPlayHandleOpenFileErrorInValidEventOrStateCallBack(TMmfDevSoundClientErrorCodes aError);
1.693 +
1.694 +private:
1.695 + TFileName iFilename;
1.696 + TFileName iOtherFilename;
1.697 + };
1.698 +
1.699 +/*
1.700 + *========================================================================================================
1.701 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0035
1.702 + */
1.703 +class RA3FDevSoundPlayRejectedByToneTest : public RA3FDevSoundTestBase, public MA3FDevsoundPlayAudioClientObserver
1.704 + {
1.705 +public:
1.706 + static RA3FDevSoundPlayRejectedByToneTest* NewL(const TDesC& aTestName);
1.707 +private:
1.708 + RA3FDevSoundPlayRejectedByToneTest(const TDesC& aTestName);
1.709 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.710 + void DoKickoffTestL();
1.711 + void DoTimerCallback();
1.712 + void ClientInitializeCompleteCallback(TInt aError);
1.713 + void ClientBufferToBeFilledCallback(TInt aError);
1.714 + void ClientPlayErrorCallback(TInt aError, TBool aLastBuffer);
1.715 + void ClientPlayHandleOpenFileErrorInValidEventOrStateCallBack(TMmfDevSoundClientErrorCodes aError);
1.716 +
1.717 +private:
1.718 + TFileName iFilename;
1.719 + TInt iFrequencyTone1;
1.720 + TInt iDuration;
1.721 + };
1.722 +
1.723 +/*
1.724 + *========================================================================================================
1.725 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0036
1.726 + */
1.727 +class RA3FDevSoundPlayRejectedByRecordTest : public RA3FDevSoundTestBase, public MA3FDevsoundPlayAudioClientObserver
1.728 + {
1.729 +public:
1.730 + static RA3FDevSoundPlayRejectedByRecordTest* NewL(const TDesC& aTestName);
1.731 +
1.732 +private:
1.733 + RA3FDevSoundPlayRejectedByRecordTest(const TDesC& aTestName);
1.734 + void DoKickoffTestL();
1.735 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.736 + void DoTimerCallback();
1.737 + void ClientInitializeCompleteCallback(TInt aError);
1.738 + void ClientBufferToBeFilledCallback(TInt aError);
1.739 + void ClientPlayErrorCallback(TInt aError, TBool aLastBuffer);
1.740 + void ClientPlayHandleOpenFileErrorInValidEventOrStateCallBack(TMmfDevSoundClientErrorCodes aError);
1.741 +
1.742 +private:
1.743 + TFileName iFilename;
1.744 + TFileName iOtherFilename;
1.745 + TBool iOtherClientStarted;
1.746 + };
1.747 +
1.748 +/*
1.749 + *========================================================================================================
1.750 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0037
1.751 + */
1.752 +class RA3FDevSoundPlayDataBeforePlayInitTest : public RA3FDevSoundTestBase
1.753 + {
1.754 +public:
1.755 + static RA3FDevSoundPlayDataBeforePlayInitTest* NewL(const TDesC& aTestName);
1.756 +
1.757 +private:
1.758 + RA3FDevSoundPlayDataBeforePlayInitTest(const TDesC& aTestName);
1.759 + void DoKickoffTestL();
1.760 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.761 + };
1.762 +
1.763 +/*
1.764 + *========================================================================================================
1.765 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0038
1.766 + */
1.767 +class RA3FDevSoundPlayInitTwiceTest : public RA3FDevSoundTestBase
1.768 + {
1.769 +public:
1.770 + static RA3FDevSoundPlayInitTwiceTest* NewL(const TDesC& aTestName);
1.771 +
1.772 +private:
1.773 + RA3FDevSoundPlayInitTwiceTest(const TDesC& aTestName);
1.774 + void DoKickoffTestL();
1.775 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.776 + void BufferToBeFilled(CMMFBuffer* /*aBuffer*/);
1.777 +
1.778 +private:
1.779 + TInt iFirstPlayInitErr;
1.780 + TInt iErr;
1.781 + };
1.782 +
1.783 +/*
1.784 + *========================================================================================================
1.785 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0039
1.786 + */
1.787 +class RA3FDevSoundPlayARNTest : public RA3FDevSoundTestBase, public MA3FDevsoundPlayAudioClientObserver
1.788 + {
1.789 +public:
1.790 + static RA3FDevSoundPlayARNTest* NewL(const TDesC& aTestName);
1.791 +
1.792 +private:
1.793 + RA3FDevSoundPlayARNTest(const TDesC& aTestName);
1.794 + void DoKickoffTestL();
1.795 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.796 + void PlayError(TInt aError);
1.797 + void DoTimerCallback();
1.798 + void ClientInitializeCompleteCallback(TInt aError);
1.799 + void ClientBufferToBeFilledCallback(TInt aError);
1.800 + void ClientPlayErrorCallback(TInt aError, TBool aLastBuffer);
1.801 + void ClientPlayHandleOpenFileErrorInValidEventOrStateCallBack(TMmfDevSoundClientErrorCodes aError);
1.802 +
1.803 +private:
1.804 + TFileName iFilename;
1.805 + TFileName iOtherFilename;
1.806 + TBool iRepeat;
1.807 + };
1.808 +
1.809 +/*
1.810 +*========================================================================================================
1.811 +* MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0040
1.812 +*/
1.813 +class RA3FDevSoundImmediatePauseAfterCreation : public RA3FDevSoundTestBase
1.814 + {
1.815 +public:
1.816 + static RA3FDevSoundImmediatePauseAfterCreation* NewL(const TDesC& aTestName);
1.817 +
1.818 +private:
1.819 + RA3FDevSoundImmediatePauseAfterCreation(const TDesC& aTestName);
1.820 + void DoKickoffTestL();
1.821 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.822 + void DoTimerCallback();
1.823 +private:
1.824 + TFileName iFilename;
1.825 + TFileName iOtherFilename;
1.826 + TBool iRepeat;
1.827 + };
1.828 +
1.829 +/*
1.830 + *========================================================================================================
1.831 + * MM-A3F-DEVSOUND-CHRTZ-PLAY-RAW-0041
1.832 + */
1.833 +class RA3FDevSoundPlayEmptyBuffersWhilePlayingTest : public RA3FDevSoundTestBase
1.834 + {
1.835 +public:
1.836 + static RA3FDevSoundPlayEmptyBuffersWhilePlayingTest* NewL(const TDesC& aTestName);
1.837 +
1.838 +private:
1.839 + RA3FDevSoundPlayEmptyBuffersWhilePlayingTest(const TDesC& aTestName);
1.840 + void DoKickoffTestL();
1.841 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.842 +private:
1.843 + TInt iVolume;
1.844 + TInt iBtbfCount;
1.845 + TFileName iFilename;
1.846 + };
1.847 +
1.848 +/*
1.849 + *========================================================================================================
1.850 + * 3F-DEVSOUND-CHRTZ-PLAY-RAW-0042
1.851 + */
1.852 +class RA3FDevSoundPlayPreemptedByToneAfterSetVolumeTest : public RA3FDevSoundTestBase, public MA3FDevsoundToneClientObserver
1.853 + {
1.854 +public:
1.855 + static RA3FDevSoundPlayPreemptedByToneAfterSetVolumeTest* NewL(const TDesC& aTestName);
1.856 +private:
1.857 + RA3FDevSoundPlayPreemptedByToneAfterSetVolumeTest(const TDesC& aTestName);
1.858 + void PlayError(TInt aError);
1.859 + void ClientInitializeCompleteCallback(TInt aError);
1.860 + void ClientToneFinishedCallback(TInt aError);
1.861 + void Fsm(TMmfDevSoundEvent aDevSoundEvent, TInt aError);
1.862 + void DoKickoffTestL();
1.863 + void DoTimerCallback();
1.864 +
1.865 +private:
1.866 + TFileName iFilename;
1.867 + TInt iExVolume;
1.868 + TInt iFrequencyTone1;
1.869 + TInt iDuration;
1.870 + TBool iSetVolume;
1.871 + TBool iResume;
1.872 + };
1.873 +
1.874 +#endif // CHAR_A3F_DEVSOUND_PLAYTEST_H
1.875 +