|
1 /* |
|
2 * Copyright (c) 2002 - 2007 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: Test EIKLABEL.H, eikfnlab.h |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 #ifndef C_TESTSDKLABELS_H |
|
21 #define C_TESTSDKLABELS_H |
|
22 |
|
23 // INCLUDES |
|
24 #include <stiflogger.h> |
|
25 #include <testscripterinternal.h> |
|
26 #include <stiftestmodule.h> |
|
27 #include <testclassassert.h> |
|
28 |
|
29 // MACROS |
|
30 #define TEST_CLASS_VERSION_MAJOR 0 |
|
31 #define TEST_CLASS_VERSION_MINOR 0 |
|
32 #define TEST_CLASS_VERSION_BUILD 0 |
|
33 |
|
34 // Logging path |
|
35 _LIT( KtestsdklabelsLogPath, "\\logs\\testframework\\testsdklabels\\" ); |
|
36 // Log file |
|
37 _LIT( KtestsdklabelsLogFile, "testsdklabels.txt" ); |
|
38 _LIT( KtestsdklabelsLogFileWithTitle, "testsdklabels_[%S].txt" ); |
|
39 |
|
40 /** |
|
41 * CTestSDKLabels test class for STIF Test Framework TestScripter. |
|
42 * @since S60 5.0 |
|
43 */ |
|
44 NONSHARABLE_CLASS(CTestSDKLabels) : public CScriptBase |
|
45 { |
|
46 public: // Constructors and destructor |
|
47 |
|
48 /** |
|
49 * Two-phased constructor. |
|
50 */ |
|
51 static CTestSDKLabels* NewL( CTestModuleIf& aTestModuleIf ); |
|
52 |
|
53 /** |
|
54 * Destructor. |
|
55 */ |
|
56 virtual ~CTestSDKLabels(); |
|
57 |
|
58 public: // Functions from base classes |
|
59 |
|
60 /** |
|
61 * From CScriptBase Runs a script line. |
|
62 * @since S60 5.0 |
|
63 * @param aItem Script line containing method name and parameters |
|
64 * @return Symbian OS error code |
|
65 */ |
|
66 virtual TInt RunMethodL( CStifItemParser& aItem ); |
|
67 |
|
68 private: |
|
69 |
|
70 /** |
|
71 * C++ default constructor. |
|
72 */ |
|
73 CTestSDKLabels( CTestModuleIf& aTestModuleIf ); |
|
74 |
|
75 /** |
|
76 * By default Symbian 2nd phase constructor is private. |
|
77 */ |
|
78 void ConstructL(); |
|
79 |
|
80 /** |
|
81 * Frees all resources allocated from test methods. |
|
82 * @since S60 5.0 |
|
83 */ |
|
84 void Delete(); |
|
85 |
|
86 /** |
|
87 * Method used to log version of test class |
|
88 */ |
|
89 void SendTestClassVersion(); |
|
90 |
|
91 /** |
|
92 * Turn off ScreenSaver |
|
93 * @since S60 5.0 |
|
94 * @return Symbian OS error code. |
|
95 */ |
|
96 void TurnOffScreenSaver(); |
|
97 |
|
98 /** |
|
99 * Restore ScreenSaver |
|
100 * @since S60 5.0 |
|
101 * @return Symbian OS error code. |
|
102 */ |
|
103 void RestoreScreenSaver(); |
|
104 |
|
105 private: // Test eikfnlab.h |
|
106 /* class CEikFileNameLabel */ |
|
107 /** |
|
108 * TestLCEikFileNameLabelL test function for testing the |
|
109 * CEikFileNameLabel function |
|
110 * @since S60 5.0 |
|
111 * @param aItem never used |
|
112 * @return Symbian OS error code. |
|
113 */ |
|
114 virtual TInt TestLCEikFileNameLabelL( CStifItemParser& aItem ); |
|
115 |
|
116 /** |
|
117 * TestLDeconstructorL test function for testing the |
|
118 * ~CEikFileNameLabel function |
|
119 * @since S60 5.0 |
|
120 * @param aItem never used |
|
121 * @return Symbian OS error code. |
|
122 */ |
|
123 virtual TInt TestLDeconstructorL( CStifItemParser& aItem ); |
|
124 |
|
125 /** |
|
126 * TestLConstructL test function for testing the |
|
127 * ConstructL function |
|
128 * @since S60 5.0 |
|
129 * @param aItem never used |
|
130 * @return Symbian OS error code. |
|
131 */ |
|
132 virtual TInt TestLConstructL( CStifItemParser& aItem ); |
|
133 |
|
134 /** |
|
135 * TestLUpdateL test function for testing the |
|
136 * UpdateL function |
|
137 * @since S60 5.0 |
|
138 * @param aItem never used |
|
139 * @return Symbian OS error code. |
|
140 */ |
|
141 |
|
142 virtual TInt TestLUpdateL( CStifItemParser& aItem ); |
|
143 |
|
144 /** |
|
145 * TestLGetColorUseListL test function for testing the |
|
146 * GetColorUseListL function |
|
147 * @since S60 5.0 |
|
148 * @param aItem never used |
|
149 * @return Symbian OS error code. |
|
150 */ |
|
151 virtual TInt TestLGetColorUseListL( CStifItemParser& aItem ); |
|
152 |
|
153 /** |
|
154 * TestLHandleResourceChangeL test function for testing the |
|
155 * HandleResourceChange function |
|
156 * @since S60 5.0 |
|
157 * @param aItem never used |
|
158 * @return Symbian OS error code. |
|
159 */ |
|
160 virtual TInt TestLHandleResourceChangeL( CStifItemParser& aItem ); |
|
161 |
|
162 /** |
|
163 * TestLMinimumSizeL test function for testing the |
|
164 * MinimumSize function |
|
165 * @since S60 5.0 |
|
166 * @param aItem never used |
|
167 * @return Symbian OS error code. |
|
168 */ |
|
169 virtual TInt TestLMinimumSizeL( CStifItemParser& aItem ); |
|
170 |
|
171 /** |
|
172 * TestLHandlePointerEventL test function for testing the |
|
173 * HandlePointerEventL function |
|
174 * @since S60 5.0 |
|
175 * @param aItem never used |
|
176 * @return Symbian OS error code. |
|
177 */ |
|
178 virtual TInt TestLHandlePointerEventL( CStifItemParser& aItem ); |
|
179 |
|
180 /** |
|
181 * TestLDrawL test function for testing the |
|
182 * Draw function |
|
183 * @since S60 5.0 |
|
184 * @param aItem never used |
|
185 * @return Symbian OS error code. |
|
186 */ |
|
187 virtual TInt TestLDrawL( CStifItemParser& aItem ); |
|
188 |
|
189 private: // Test EIKLABEL.H |
|
190 /* class CEikLabel */ |
|
191 /** |
|
192 * TestLabelDeconstructorL test function for testing the |
|
193 * CEikLabel function |
|
194 * @since S60 5.0 |
|
195 * @param aItem never used |
|
196 * @return Symbian OS error code. |
|
197 */ |
|
198 virtual TInt TestLabelDeconstructorL( CStifItemParser& aItem ); |
|
199 |
|
200 /** |
|
201 * TestLabelCEikLabelL test function for testing the |
|
202 * CEikLabel function |
|
203 * @since S60 5.0 |
|
204 * @param aItem never used |
|
205 * @return Symbian OS error code. |
|
206 */ |
|
207 virtual TInt TestLabelCEikLabelL( CStifItemParser& aItem ); |
|
208 |
|
209 /** |
|
210 * TestLabelSetLabelAlignmentL test function for testing the |
|
211 * SetLabelAlignment function |
|
212 * @since S60 5.0 |
|
213 * @param aItem never used |
|
214 * @return Symbian OS error code. |
|
215 */ |
|
216 virtual TInt TestLabelSetLabelAlignmentL( CStifItemParser& aItem ); |
|
217 |
|
218 /** |
|
219 * TestLabelSetBrushStyleL test function for testing the |
|
220 * SetBrushStyle function |
|
221 * @since S60 5.0 |
|
222 * @param aItem never used |
|
223 * @return Symbian OS error code. |
|
224 */ |
|
225 virtual TInt TestLabelSetBrushStyleL( CStifItemParser& aItem ); |
|
226 |
|
227 /** |
|
228 * TestLabelSetBrushStyleFromContextL test function for testing the |
|
229 * SetBrushStyleFromContext function |
|
230 * @since S60 5.0 |
|
231 * @param aItem never used |
|
232 * @return Symbian OS error code. |
|
233 */ |
|
234 virtual TInt TestLabelSetBrushStyleFromContextL( CStifItemParser& aItem ); |
|
235 |
|
236 /** |
|
237 * TestLabelMinimumSizeL test function for testing the |
|
238 * MinimumSize function |
|
239 * @since S60 5.0 |
|
240 * @param aItem never used |
|
241 * @return Symbian OS error code. |
|
242 */ |
|
243 virtual TInt TestLabelMinimumSizeL( CStifItemParser& aItem ); |
|
244 |
|
245 /** |
|
246 * TestLabelConstructFromResourceL test function for testing the |
|
247 * ConstructFromResourceL function |
|
248 * @since S60 5.0 |
|
249 * @param aItem never used |
|
250 * @return Symbian OS error code. |
|
251 */ |
|
252 virtual TInt TestLabelConstructFromResourceL( CStifItemParser& aItem ); |
|
253 |
|
254 /** |
|
255 * TestLabelGetColorUseListL test function for testing the |
|
256 * GetColorUseListL function |
|
257 * @since S60 5.0 |
|
258 * @param aItem never used |
|
259 * @return Symbian OS error code. |
|
260 */ |
|
261 virtual TInt TestLabelGetColorUseListL( CStifItemParser& aItem ); |
|
262 |
|
263 /** |
|
264 * TestLabelHandleResourceChangeL test function for testing the |
|
265 * HandleResourceChange function |
|
266 * @since S60 5.0 |
|
267 * @param aItem never used |
|
268 * @return Symbian OS error code. |
|
269 */ |
|
270 virtual TInt TestLabelHandleResourceChangeL( CStifItemParser& aItem ); |
|
271 |
|
272 /** |
|
273 * TestLabelDrawL test function for testing the |
|
274 * Draw function |
|
275 * @since S60 5.0 |
|
276 * @param aItem never used |
|
277 * @return Symbian OS error code. |
|
278 */ |
|
279 virtual TInt TestLabelDrawL( CStifItemParser& aItem ); |
|
280 |
|
281 /** |
|
282 * TestLabelSetTextL test function for testing the |
|
283 * SetTextL function |
|
284 * @since S60 5.0 |
|
285 * @param aItem never used |
|
286 * @return Symbian OS error code. |
|
287 */ |
|
288 virtual TInt TestLabelSetTextL( CStifItemParser& aItem ); |
|
289 |
|
290 /** |
|
291 * TestLabelTextL test function for testing the |
|
292 * Text function |
|
293 * @since S60 5.0 |
|
294 * @param aItem never used |
|
295 * @return Symbian OS error code. |
|
296 */ |
|
297 virtual TInt TestLabelTextL( CStifItemParser& aItem ); |
|
298 |
|
299 /** |
|
300 * TestLabelCropTextL test function for testing the |
|
301 * CropText function |
|
302 * @since S60 5.0 |
|
303 * @param aItem never used |
|
304 * @return Symbian OS error code. |
|
305 */ |
|
306 virtual TInt TestLabelCropTextL( CStifItemParser& aItem ); |
|
307 |
|
308 /** |
|
309 * TestLabelSetBufferReserveLengthL test function for testing the |
|
310 * SetBufferReserveLengthL function |
|
311 * @since S60 5.0 |
|
312 * @param aItem never used |
|
313 * @return Symbian OS error code. |
|
314 */ |
|
315 virtual TInt TestLabelSetBufferReserveLengthL( CStifItemParser& aItem ); |
|
316 |
|
317 /** |
|
318 * TestLabelSetFontL test function for testing the |
|
319 * SetFont function |
|
320 * @since S60 5.0 |
|
321 * @param aItem never used |
|
322 * @return Symbian OS error code. |
|
323 */ |
|
324 virtual TInt TestLabelSetFontL( CStifItemParser& aItem ); |
|
325 |
|
326 /** |
|
327 * TestLabelFontL test function for testing the |
|
328 * Font function |
|
329 * @since S60 5.0 |
|
330 * @param aItem never used |
|
331 * @return Symbian OS error code. |
|
332 */ |
|
333 virtual TInt TestLabelFontL( CStifItemParser& aItem ); |
|
334 |
|
335 /** |
|
336 * TestLabelSetEmphasisL test function for testing the |
|
337 * SetEmphasis function |
|
338 * @since S60 5.0 |
|
339 * @param aItem never used |
|
340 * @return Symbian OS error code. |
|
341 */ |
|
342 virtual TInt TestLabelSetEmphasisL( CStifItemParser& aItem ); |
|
343 |
|
344 /** |
|
345 * TestLabelSetPixelGapBetweenLinesL test function for testing the |
|
346 * SetPixelGapBetweenLines function |
|
347 * @since S60 5.0 |
|
348 * @param aItem never used |
|
349 * @return Symbian OS error code. |
|
350 */ |
|
351 virtual TInt TestLabelSetPixelGapBetweenLinesL( CStifItemParser& aItem ); |
|
352 |
|
353 /** |
|
354 * TestLabelPixelGapBetweenLinesL test function for testing the |
|
355 * PixelGapBetweenLines function |
|
356 * @since S60 5.0 |
|
357 * @param aItem never used |
|
358 * @return Symbian OS error code. |
|
359 */ |
|
360 virtual TInt TestLabelPixelGapBetweenLinesL( CStifItemParser& aItem ); |
|
361 |
|
362 /** |
|
363 * TestLabelIsUnderlinedL test function for testing the |
|
364 * IsUnderlined function |
|
365 * @since S60 5.0 |
|
366 * @param aItem never used |
|
367 * @return Symbian OS error code. |
|
368 */ |
|
369 virtual TInt TestLabelIsUnderlinedL( CStifItemParser& aItem ); |
|
370 |
|
371 /** |
|
372 * TestLabelSetUnderliningL test function for testing the |
|
373 * SetUnderlining function |
|
374 * @since S60 5.0 |
|
375 * @param aItem never used |
|
376 * @return Symbian OS error code. |
|
377 */ |
|
378 virtual TInt TestLabelSetUnderliningL( CStifItemParser& aItem ); |
|
379 |
|
380 /** |
|
381 * TestLabelIsStrikethroughL test function for testing the |
|
382 * IsStrikethrough function |
|
383 * @since S60 5.0 |
|
384 * @param aItem never used |
|
385 * @return Symbian OS error code. |
|
386 */ |
|
387 virtual TInt TestLabelIsStrikethroughL( CStifItemParser& aItem ); |
|
388 |
|
389 /** |
|
390 * TestLabelSetStrikethroughL test function for testing the |
|
391 * SetStrikethrough function |
|
392 * @since S60 5.0 |
|
393 * @param aItem never used |
|
394 * @return Symbian OS error code. |
|
395 */ |
|
396 virtual TInt TestLabelSetStrikethroughL( CStifItemParser& aItem ); |
|
397 |
|
398 /** |
|
399 * TestLabelCalcMinimumSizeL test function for testing the |
|
400 * CalcMinimumSize function |
|
401 * @since S60 5.0 |
|
402 * @param aItem never used |
|
403 * @return Symbian OS error code. |
|
404 */ |
|
405 virtual TInt TestLabelCalcMinimumSizeL( CStifItemParser& aItem ); |
|
406 |
|
407 /** |
|
408 * TestLabelNumberOfLinesL test function for testing the |
|
409 * NumberOfLines function |
|
410 * @since S60 5.0 |
|
411 * @param aItem never used |
|
412 * @return Symbian OS error code. |
|
413 */ |
|
414 virtual TInt TestLabelNumberOfLinesL( CStifItemParser& aItem ); |
|
415 |
|
416 /** |
|
417 * TestLabelBufferReserveLengthL test function for testing the |
|
418 * BufferReserveLength function |
|
419 * @since S60 5.0 |
|
420 * @param aItem never used |
|
421 * @return Symbian OS error code. |
|
422 */ |
|
423 virtual TInt TestLabelBufferReserveLengthL( CStifItemParser& aItem ); |
|
424 |
|
425 /** |
|
426 * TestLabelUseLogicalToVisualConversionL test function for testing the |
|
427 * UseLogicalToVisualConversion function |
|
428 * @since S60 5.0 |
|
429 * @param aItem never used |
|
430 * @return Symbian OS error code. |
|
431 */ |
|
432 virtual TInt TestLabelUseLogicalToVisualConversionL( CStifItemParser& aItem ); |
|
433 |
|
434 /** |
|
435 * TestLabelLogicalToVisualConversionUsedL test function for testing the |
|
436 * LogicalToVisualConversionUsed function |
|
437 * @since S60 5.0 |
|
438 * @param aItem never used |
|
439 * @return Symbian OS error code. |
|
440 */ |
|
441 virtual TInt TestLabelLogicalToVisualConversionUsedL( CStifItemParser& aItem ); |
|
442 |
|
443 /** |
|
444 * TestLabelEnablePictographsL test function for testing the |
|
445 * EnablePictographsL function |
|
446 * @since S60 5.0 |
|
447 * @param aItem never used |
|
448 * @return Symbian OS error code. |
|
449 */ |
|
450 virtual TInt TestLabelEnablePictographsL( CStifItemParser& aItem ); |
|
451 |
|
452 /** |
|
453 * TestLabelDisablePictographsL test function for testing the |
|
454 * DisablePictographs function |
|
455 * @since S60 5.0 |
|
456 * @param aItem never used |
|
457 * @return Symbian OS error code. |
|
458 */ |
|
459 virtual TInt TestLabelDisablePictographsL( CStifItemParser& aItem ); |
|
460 |
|
461 /** |
|
462 * TestLabelHandlePointerEventL test function for testing the |
|
463 * HandlePointerEventL function |
|
464 * @since S60 5.0 |
|
465 * @param aItem never used |
|
466 * @return Symbian OS error code. |
|
467 */ |
|
468 virtual TInt TestLabelHandlePointerEventL( CStifItemParser& aItem ); |
|
469 |
|
470 /** |
|
471 * TestLabelWriteInternalStateL test function for testing the |
|
472 * WriteInternalStateL function |
|
473 * @since S60 5.0 |
|
474 * @param aItem never used |
|
475 * @return Symbian OS error code. |
|
476 */ |
|
477 virtual TInt TestLabelWriteInternalStateL( CStifItemParser& aItem ); |
|
478 |
|
479 private: // Data |
|
480 |
|
481 /** |
|
482 * ScreenSaver Property |
|
483 */ |
|
484 TInt iOldScreenSaverProperty; |
|
485 |
|
486 // Resource file offset |
|
487 TInt iOffset; |
|
488 }; |
|
489 |
|
490 #endif // C_TESTSDKLABELS_H |
|
491 |
|
492 // End of File |