Update contrib.
1 // Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
2 // All rights reserved.
3 // This component and the accompanying materials are made available
4 // under the terms of "Eclipse Public License v1.0"
5 // which accompanies this distribution, and is available
6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
8 // Initial Contributors:
9 // Nokia Corporation - initial contribution.
16 #ifndef TESTRENDERERNEG_H
17 #define TESTRENDERERNEG_H
20 #include "testrenderer.h"
23 Test creating surface with different parameters
24 MM-MMF-VIDREND-U-0100 to MM-MMF-VIDREND-U-0107
26 class RTestRendererCreateSurfaceStep : public RTestRendererStep
29 static RTestRendererCreateSurfaceStep* NewL(const TDesC& aStepName,
31 TRgbFormat aRgbFormat,
36 RTestRendererCreateSurfaceStep(const TDesC& aStepName,
38 TRgbFormat aRgbFormat,
41 TVerdict DoTestStepL();
42 virtual void FsmL(TTestRendererEvents /*aEventCode*/) {};
51 Test update buffer twice in timed and non-timed mode
52 This test case is run by different script for udeb and urel mode to expect different behaviour
53 MM-MMF-VIDREND-U-0108 and MM-MMF-VIDREND-U-0109
55 class RTestRendererUpdateTwiceStep : public RTestRendererStep
58 static RTestRendererUpdateTwiceStep* NewL(const TDesC& aStepName, TBool aTimed);
61 RTestRendererUpdateTwiceStep(const TDesC& aStepName, TBool aTimed);
62 void FsmL(TTestRendererEvents aEventCode);
66 Test release buffer twice
67 This class is also base class for test steps that do not need to start active scheduler
70 class RTestRendererReleaseTwiceStep : public RTestRendererStep
73 static RTestRendererReleaseTwiceStep* NewL(const TDesC& aStepName, TBool aTimed);
76 RTestRendererReleaseTwiceStep(const TDesC& aStepName, TBool aTimed);
77 void FsmL(TTestRendererEvents aEventCode);
78 TVerdict DoTestStepL();
81 TVideoFrameBuffer* iBuffer;
85 Test using surface after destroying surface
88 class RTestRendererDestroySurfaceStep : public RTestRendererReleaseTwiceStep
91 static RTestRendererDestroySurfaceStep* NewL(const TDesC& aStepName, TBool aTimed);
94 RTestRendererDestroySurfaceStep(const TDesC& aStepName, TBool aTimed);
95 void FsmL(TTestRendererEvents aEventCode);
99 Test update buffer immediately destroy surface in timed and non-timed mode
100 MM-MMF-VIDREND-U-0112 and MM-MMF-VIDREND-U-0113
102 class RTestRendererUpdateAndDestroyStep : public RTestRendererStep
105 static RTestRendererUpdateAndDestroyStep* NewL(const TDesC& aStepName, TBool aTimed);
106 static TInt TimerCallbackFunc(TAny *aPtr);
107 void FsmL(TTestRendererEvents aEventCode);
110 RTestRendererUpdateAndDestroyStep(const TDesC& aStepName, TBool aTimed);
111 TVerdict DoTestStepPreambleL();
112 TVerdict DoTestStepPostambleL();
115 CCallBackTimer* iCallbackTimer;
119 Test update buffer immediately delete video renderer in timed and non-timed mode
120 MM-MMF-VIDREND-U-0114 and MM-MMF-VIDREND-U-0115
122 class RTestRendererUpdateAndDeleteStep : public RTestRendererReleaseTwiceStep
125 static RTestRendererUpdateAndDeleteStep* NewL(const TDesC& aStepName, TBool aTimed);
128 RTestRendererUpdateAndDeleteStep(const TDesC& aStepName, TBool aTimed);
129 void FsmL(TTestRendererEvents aEventCode);
133 Test update buffer with invalid buffer in timed and non-timed mode
134 MM-MMF-VIDREND-U-0116 and MM-MMF-VIDREND-U-0117
136 class RTestRendererUpdateInvalidStep : public RTestRendererReleaseTwiceStep
139 static RTestRendererUpdateInvalidStep* NewL(const TDesC& aStepName, TBool aTimed);
142 RTestRendererUpdateInvalidStep(const TDesC& aStepName, TBool aTimed);
143 void FsmL(TTestRendererEvents aEventCode);
147 Test creating surface twice
148 MM-MMF-VIDREND-U-0118
150 class RTestRendererCreateTwiceStep : public RTestRendererReleaseTwiceStep
153 static RTestRendererCreateTwiceStep* NewL(const TDesC& aStepName, TBool aTimed);
156 RTestRendererCreateTwiceStep(const TDesC& aStepName, TBool aTimed);
157 void FsmL(TTestRendererEvents aEventCode);
161 Test destroying surface that does not exist
162 MM-MMF-VIDREND-U-0119
164 class RTestRendererDestroyInvalidStep : public RTestRendererReleaseTwiceStep
167 static RTestRendererDestroyInvalidStep* NewL(const TDesC& aStepName, TBool aTimed);
170 RTestRendererDestroyInvalidStep(const TDesC& aStepName, TBool aTimed);
171 void FsmL(TTestRendererEvents aEventCode);
175 Test resoure file reader
176 MM-MMF-VIDREND-U-0120
178 class RTestResourceFileReaderStep : public RTestStep
181 static RTestResourceFileReaderStep* NewL(const TDesC& aStepName,
182 const TDesC& aFileName,
183 TInt aExpectedFormatErr,
184 TInt aExpectedTimerErr,
185 TInt64 aExpectedDefaultDelay,
186 TInt64 aExpectedDelay);
189 TVerdict DoTestStepL();
192 RTestResourceFileReaderStep(const TDesC& aStepName,
193 const TDesC& aFileName,
194 TInt aExpectedFormatErr,
195 TInt aExpectedTimerErr,
196 TInt64 aExpectedDefaultDelay,
197 TInt64 aExpectedDelay);
198 TBuf<KMaxFileName> iFileName;
199 TInt iExpectedFormatErr;
200 TInt iExpectedTimerErr;
201 TInt64 iExpectedDefaultDelay;
202 TInt64 iExpectedMaxDelay;
206 Test creating a delay by delaying set background surface in timed mode
207 MM-MMF-VIDREND-U-0121
209 class RTestRendererDelayStep : public RTestRendererUpdateAndDestroyStep
212 static RTestRendererDelayStep* NewL(const TDesC& aStepName);
213 void FsmL(TTestRendererEvents aEventCode);
216 RTestRendererDelayStep(const TDesC& aStepName);
219 #endif // TESTRENDERERNEG_H