|
1 // Copyright (c) 2005-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". |
|
7 // |
|
8 // Initial Contributors: |
|
9 // Nokia Corporation - initial contribution. |
|
10 // |
|
11 // Contributors: |
|
12 // |
|
13 // Description: |
|
14 // CCommsdat1Step |
|
15 // CCommsdat2Step |
|
16 // CCommsdat3Step |
|
17 // CCommsdat4Step |
|
18 // CCommsdat5Step |
|
19 // CCommsdat6Step |
|
20 // CCommsdat7Step |
|
21 // CCommsdat8Step |
|
22 // CCommsdat9Step |
|
23 // CCommsdat10Step |
|
24 // CCommsdat11Step |
|
25 // CCommsdat12Step |
|
26 // CCommsdat13Step |
|
27 // CCommsdat14Step |
|
28 // CCommsdat15Step |
|
29 // CCommsdat16Step |
|
30 // CCommsdat17Step |
|
31 // CCommsdat18Step |
|
32 // CCommsdat19Step |
|
33 // CCommsdat20Step |
|
34 // CCommsdat21Step |
|
35 // CCommsdat22Step |
|
36 // CCommsdat23Step |
|
37 // CCommsdat24Step |
|
38 // CCommsdat25Step |
|
39 // CCommsdat26Step |
|
40 // CCommsdat27Step |
|
41 // CCommsdat28Step |
|
42 // |
|
43 // |
|
44 |
|
45 /** |
|
46 @file commsdatBasicFunctionalityTests.cpp |
|
47 */ |
|
48 #include "commsdatBasicFunctionalityTests.h" |
|
49 #include "Te_commsdatSuiteDefs.h" |
|
50 #include "CommsDatInternalDefs.h" |
|
51 #include <e32test.h> |
|
52 #ifdef SYMBIAN_ENABLE_SPLIT_HEADERS |
|
53 #include <commsdat_partner.h> |
|
54 #endif |
|
55 |
|
56 CCommsdat1Step::~CCommsdat1Step() |
|
57 /** |
|
58 * Destructor |
|
59 */ |
|
60 { |
|
61 } |
|
62 |
|
63 CCommsdat1Step::CCommsdat1Step() |
|
64 /** |
|
65 * Constructor |
|
66 */ |
|
67 { |
|
68 SetTestStepName(KCommsdat1Step); |
|
69 } |
|
70 |
|
71 |
|
72 TVerdict CCommsdat1Step::doTestStepL() |
|
73 /** |
|
74 * @return - TVerdict code |
|
75 * Create a session object and delete it |
|
76 */ |
|
77 { |
|
78 SetTestStepResult(EFail); |
|
79 INFO_PRINTF1(_L("Setting Repository. In CCommsdat1Step::doTestStepL() ")); |
|
80 |
|
81 #ifdef SYMBIAN_NON_SEAMLESS_NETWORK_BEARER_MOBILITY |
|
82 CMDBSession *cmdbSession = CMDBSession::NewL(KCDVersion1_2); |
|
83 #else |
|
84 CMDBSession *cmdbSession = CMDBSession::NewL(KCDVersion1_1); |
|
85 #endif |
|
86 |
|
87 delete cmdbSession; |
|
88 |
|
89 SetTestStepResult(EPass); |
|
90 return TestStepResult(); |
|
91 } |
|
92 //---------------------------------------------------------------------------------------------------------------- |
|
93 CCommsdat2Step::CCommsdat2Step() |
|
94 /** |
|
95 * Constructor |
|
96 */ |
|
97 { |
|
98 SetTestStepName(KCommsdat2Step); |
|
99 } |
|
100 |
|
101 |
|
102 TVerdict CCommsdat2Step::doTestStepL() |
|
103 /** |
|
104 * @return - TVerdict code |
|
105 * Set and get attributes |
|
106 */ |
|
107 { |
|
108 SetTestStepResult(EFail); |
|
109 INFO_PRINTF1(_L(" Setting Repository & creating IAP RecordSet & setting/getting attributes - CCommsdat2Step::doTestStepL()")); |
|
110 |
|
111 #ifdef SYMBIAN_NON_SEAMLESS_NETWORK_BEARER_MOBILITY |
|
112 CMDBSession *cmdbSession = CMDBSession::NewL(KCDVersion1_2); |
|
113 #else |
|
114 CMDBSession *cmdbSession = CMDBSession::NewL(KCDVersion1_1); |
|
115 #endif |
|
116 |
|
117 CleanupStack::PushL(cmdbSession); |
|
118 |
|
119 CMDBRecordSet<CCDIAPRecord>* IAPRecords = new(ELeave) CMDBRecordSet<CCDIAPRecord>; |
|
120 |
|
121 IAPRecords->SetAttributes(ECDProtectedWrite); |
|
122 |
|
123 TMDBAttributeFlags atts = IAPRecords->Attributes(); |
|
124 |
|
125 if (atts == ECDProtectedWrite) |
|
126 SetTestStepResult(EPass); |
|
127 |
|
128 delete IAPRecords; |
|
129 CleanupStack::PopAndDestroy(cmdbSession); |
|
130 |
|
131 return TestStepResult(); |
|
132 } |
|
133 //---------------------------------------------------------------------------------------------------------------- |
|
134 CCommsdat3Step::CCommsdat3Step() |
|
135 /** |
|
136 * Constructor |
|
137 */ |
|
138 { |
|
139 SetTestStepName(KCommsdat3Step); |
|
140 } |
|
141 |
|
142 TVerdict CCommsdat3Step::doTestStepL() |
|
143 /** |
|
144 * @return - TVerdict code |
|
145 * Create a CMDBField object and delete it |
|
146 */ |
|
147 { |
|
148 SetTestStepResult(EFail); |
|
149 INFO_PRINTF1(_L("CCommsdat3Step::doTestStepL() in the file commsdat3Step.cpp")); |
|
150 |
|
151 CMDBField<TInt> *dbField = new(ELeave) CMDBField<TInt>(); |
|
152 delete dbField; |
|
153 |
|
154 SetTestStepResult(EPass); |
|
155 return TestStepResult(); |
|
156 } |
|
157 |
|
158 //---------------------------------------------------------------------------------------------------------------- |
|
159 CCommsdat4Step::CCommsdat4Step() |
|
160 /** |
|
161 * Constructor |
|
162 */ |
|
163 { |
|
164 SetTestStepName(KCommsdat4Step); |
|
165 } |
|
166 |
|
167 |
|
168 TVerdict CCommsdat4Step::doTestStepL() |
|
169 /** |
|
170 * @return - TVerdict code |
|
171 * Create a CMDBField object, set element id and delete it |
|
172 */ |
|
173 { |
|
174 SetTestStepResult(EFail); |
|
175 INFO_PRINTF1(_L("Creating a field and setting element id - CCommsdat4Step::doTestStepL() in the file commsdat4Step.cpp")); |
|
176 |
|
177 TMDBElementId elementId = 0x04021600; |
|
178 CMDBField<TUint32> *dbField = new(ELeave) CMDBField<TUint32>(elementId); |
|
179 |
|
180 INFO_PRINTF3(_L("ElementId is %08x, should be %08x"), dbField->ElementId(), elementId); |
|
181 |
|
182 if (elementId == dbField->ElementId()) |
|
183 SetTestStepResult(EPass); |
|
184 |
|
185 delete dbField; |
|
186 |
|
187 return TestStepResult(); |
|
188 } |
|
189 //---------------------------------------------------------------------------------------------------------------- |
|
190 CCommsdat5Step::CCommsdat5Step() |
|
191 /** |
|
192 * Constructor |
|
193 */ |
|
194 { |
|
195 SetTestStepName(KCommsdat5Step); |
|
196 } |
|
197 |
|
198 |
|
199 TVerdict CCommsdat5Step::doTestStepL() |
|
200 /** |
|
201 * @return - TVerdict code |
|
202 * Create a CMDBField object with an element id and delete it |
|
203 */ |
|
204 { |
|
205 SetTestStepResult(EFail); |
|
206 INFO_PRINTF1(_L("CCommsdat5Step::doTestStepL() in the file commsdat5Step.cpp")); |
|
207 |
|
208 TMDBElementId elementId = 5; |
|
209 |
|
210 CMDBField<TInt> *dbField = new(ELeave) CMDBField<TInt>(elementId); |
|
211 delete dbField; |
|
212 |
|
213 SetTestStepResult(EPass); |
|
214 return TestStepResult(); |
|
215 } |
|
216 //---------------------------------------------------------------------------------------------------------------- |
|
217 CCommsdat6Step::CCommsdat6Step() |
|
218 /** |
|
219 * Constructor |
|
220 */ |
|
221 { |
|
222 SetTestStepName(KCommsdat6Step); |
|
223 } |
|
224 |
|
225 |
|
226 TVerdict CCommsdat6Step::doTestStepL() |
|
227 /** |
|
228 * @return - TVerdict code |
|
229 * Create a CMDBField object, assign a value and delete it |
|
230 */ |
|
231 { |
|
232 SetTestStepResult(EFail); |
|
233 INFO_PRINTF1(_L("CCommsdat6Step::doTestStepL() in the file commsdat6Step.cpp. Setting TUint32 value")); |
|
234 |
|
235 CMDBField<TUint32> *dbField = new(ELeave) CMDBField<TUint32>(); |
|
236 TMDBElementId data = 13; |
|
237 *dbField = data; |
|
238 |
|
239 INFO_PRINTF3(_L("value is %08x, should be %08x"), (TUint32)*dbField, data); |
|
240 |
|
241 if( data == *dbField) |
|
242 SetTestStepResult(EPass); |
|
243 |
|
244 delete dbField; |
|
245 |
|
246 return TestStepResult(); |
|
247 } |
|
248 //---------------------------------------------------------------------------------------------------------------- |
|
249 CCommsdat7Step::CCommsdat7Step() |
|
250 /** |
|
251 * Constructor |
|
252 */ |
|
253 { |
|
254 SetTestStepName(KCommsdat7Step); |
|
255 } |
|
256 |
|
257 |
|
258 TVerdict CCommsdat7Step::doTestStepL() |
|
259 /** |
|
260 * @return - TVerdict code |
|
261 * Create a CMDBField object and variable with the same element id, check they both return |
|
262 * same element id and delete object |
|
263 */ |
|
264 { |
|
265 SetTestStepResult(EFail); |
|
266 INFO_PRINTF1(_L("CCommsdat7Step::doTestStepL() in the file commsdat7Step.cpp")); |
|
267 |
|
268 TMDBElementId elementId = 0x01010500; |
|
269 |
|
270 CMDBField<TInt> *dbField = new(ELeave) CMDBField<TInt>(elementId); |
|
271 CMDBField<TInt> dbField2(elementId); |
|
272 TUint32 result = dbField->ElementId(); |
|
273 INFO_PRINTF3(_L("field id = %08x. Should be %08x"), elementId, dbField->ElementId() & KCDMaskHideRes); |
|
274 |
|
275 delete dbField; |
|
276 dbField = 0; |
|
277 |
|
278 if (dbField2.ElementId() == result) |
|
279 SetTestStepResult(EPass); |
|
280 |
|
281 delete dbField; |
|
282 |
|
283 return TestStepResult(); |
|
284 } |
|
285 //---------------------------------------------------------------------------------------------------------------- |
|
286 CCommsdat8Step::CCommsdat8Step() |
|
287 /** |
|
288 * Constructor |
|
289 */ |
|
290 { |
|
291 SetTestStepName(KCommsdat8Step); |
|
292 } |
|
293 |
|
294 |
|
295 TVerdict CCommsdat8Step::doTestStepL() |
|
296 /** |
|
297 * @return - TVerdict code |
|
298 * Create a CMDBField object with an element id, check the element id and delete it |
|
299 */ |
|
300 { |
|
301 SetTestStepResult(EFail); |
|
302 INFO_PRINTF1(_L("CCommsdat8Step::doTestStepL() in the file commsdat8Step.cpp")); |
|
303 |
|
304 TMDBElementId elementId = 0x01010600; |
|
305 |
|
306 TMDBElementId result; |
|
307 CMDBField<TInt> *dbField = new(ELeave) CMDBField<TInt>(elementId); |
|
308 result = dbField->ElementId(); |
|
309 INFO_PRINTF3(_L("result = %08x. Should be %08x"), result, elementId); |
|
310 |
|
311 if (result == elementId) |
|
312 { |
|
313 SetTestStepResult(EPass); |
|
314 } |
|
315 |
|
316 delete dbField; |
|
317 |
|
318 return TestStepResult(); |
|
319 } |
|
320 |
|
321 //---------------------------------------------------------------------------------------------------------------- |
|
322 CCommsdat9Step::CCommsdat9Step() |
|
323 /** |
|
324 * Constructor |
|
325 */ |
|
326 { |
|
327 SetTestStepName(KCommsdat9Step); |
|
328 } |
|
329 |
|
330 |
|
331 TVerdict CCommsdat9Step::doTestStepL() |
|
332 /** |
|
333 * @return - TVerdict code |
|
334 * Create a CMDBField object with an element id, check the record id and delete it |
|
335 */ |
|
336 { |
|
337 SetTestStepResult(EFail); |
|
338 INFO_PRINTF1(_L("CCommsdat9Step::doTestStepL() in the file commsdat9Step.cpp")); |
|
339 |
|
340 TMDBElementId elementId = 0x020304f0; |
|
341 |
|
342 CMDBField<TInt> *dbField = new(ELeave) CMDBField<TInt>(elementId); |
|
343 TMDBElementId result = dbField->RecordId(); |
|
344 |
|
345 INFO_PRINTF3(_L("result = %08x, should be %08x"), result, (elementId & KCDMaskShowRecordId) >> 8); |
|
346 |
|
347 TInt id = (elementId & KCDMaskShowRecordId) >> 8; |
|
348 if (result == id) |
|
349 { |
|
350 SetTestStepResult(EPass); |
|
351 } |
|
352 |
|
353 delete dbField; |
|
354 |
|
355 return TestStepResult(); |
|
356 } |
|
357 |
|
358 //---------------------------------------------------------------------------------------------------------------- |
|
359 CCommsdat10Step::CCommsdat10Step() |
|
360 /** |
|
361 * Constructor |
|
362 */ |
|
363 { |
|
364 SetTestStepName(KCommsdat10Step); |
|
365 } |
|
366 |
|
367 |
|
368 TVerdict CCommsdat10Step::doTestStepL() |
|
369 /** |
|
370 * @return - TVerdict code |
|
371 * Create a CMDBField object with an element id, check the record id and delete it |
|
372 */ |
|
373 { |
|
374 SetTestStepResult(EFail); |
|
375 INFO_PRINTF1(_L("CCommsdat10Step::doTestStepL() in the file commsdat10Step.cpp")); |
|
376 |
|
377 TMDBElementId elementId = 0x01810080; |
|
378 |
|
379 CMDBField<TInt> *dbField = new(ELeave) CMDBField<TInt>(elementId); |
|
380 TMDBElementId recordId = (dbField->ElementId() & KCDMaskShowRecordId); |
|
381 |
|
382 INFO_PRINTF3(_L("recordId = %08x, element id = %08x"), recordId, elementId); |
|
383 |
|
384 if (recordId == 0) |
|
385 { |
|
386 SetTestStepResult(EPass); |
|
387 } |
|
388 |
|
389 delete dbField; |
|
390 |
|
391 return TestStepResult(); |
|
392 } |
|
393 |
|
394 //---------------------------------------------------------------------------------------------------------------- |
|
395 CCommsdat11Step::CCommsdat11Step() |
|
396 /** |
|
397 * Constructor |
|
398 */ |
|
399 { |
|
400 SetTestStepName(KCommsdat11Step); |
|
401 } |
|
402 |
|
403 |
|
404 TVerdict CCommsdat11Step::doTestStepL() |
|
405 /** |
|
406 * @return - TVerdict code |
|
407 * Create a CMDBField object with an element id, check the attributes and delete it |
|
408 */ |
|
409 { |
|
410 SetTestStepResult(EFail); |
|
411 INFO_PRINTF1(_L("CCommsdat11Step::doTestStepL() in the file commsdat11Step.cpp")); |
|
412 |
|
413 TMDBElementId elementId = 0xfffffe20; |
|
414 |
|
415 TMDBAttributeFlags result; |
|
416 CMDBField<TInt> *dbField = new(ELeave) CMDBField<TInt>(elementId); |
|
417 result = dbField->Attributes(); |
|
418 |
|
419 INFO_PRINTF2(_L("attributes : result = %08x"), result); |
|
420 |
|
421 if (result == (elementId & KCDMaskShowAttributes)) |
|
422 { |
|
423 SetTestStepResult(EPass); |
|
424 } |
|
425 |
|
426 delete dbField; |
|
427 |
|
428 return TestStepResult(); |
|
429 } |
|
430 //---------------------------------------------------------------------------------------------------------------- |
|
431 CCommsdat12Step::CCommsdat12Step() |
|
432 /** |
|
433 * Constructor |
|
434 */ |
|
435 { |
|
436 SetTestStepName(KCommsdat12Step); |
|
437 } |
|
438 |
|
439 |
|
440 TVerdict CCommsdat12Step::doTestStepL() |
|
441 /** |
|
442 * Create a CMDBField object with an element id, check the element id and delete it |
|
443 */ |
|
444 { |
|
445 SetTestStepResult(EFail); |
|
446 INFO_PRINTF1(_L("CCommsdat12Step::doTestStepL() in the file commsdat12Step.cpp")); |
|
447 |
|
448 TMDBElementId elementId = 5; |
|
449 TMDBElementId result = 0; |
|
450 CMDBField<TInt> *dbField = new(ELeave) CMDBField<TInt>(); |
|
451 dbField->SetElementId(elementId); |
|
452 result = dbField->ElementId(); |
|
453 |
|
454 INFO_PRINTF2(_L("element Id - result = %d"), result); |
|
455 |
|
456 delete dbField; |
|
457 |
|
458 SetTestStepResult(EPass); |
|
459 return TestStepResult(); |
|
460 } |
|
461 //---------------------------------------------------------------------------------------------------------------- |
|
462 CCommsdat13Step::CCommsdat13Step() |
|
463 /** |
|
464 * Constructor |
|
465 */ |
|
466 { |
|
467 SetTestStepName(KCommsdat13Step); |
|
468 } |
|
469 |
|
470 |
|
471 TVerdict CCommsdat13Step::doTestStepL() |
|
472 /** |
|
473 * @return - TVerdict code |
|
474 * Create a CMDBField object with an element id, check the attributes and delete it |
|
475 */ |
|
476 { |
|
477 SetTestStepResult(EFail); |
|
478 INFO_PRINTF1(_L("CCommsdat13Step::doTestStepL() in the file commsdat13Step.cpp")); |
|
479 |
|
480 TMDBAttributeFlags attributes = 5; |
|
481 TMDBAttributeFlags result = 0; |
|
482 CMDBField<TInt> *dbField = new(ELeave) CMDBField<TInt>(); |
|
483 dbField->SetAttributes(attributes); |
|
484 result = dbField->Attributes(); |
|
485 |
|
486 INFO_PRINTF2(_L("attributes - result = %d"), result); |
|
487 |
|
488 delete dbField; |
|
489 |
|
490 SetTestStepResult(EPass); |
|
491 return TestStepResult(); |
|
492 } |
|
493 //---------------------------------------------------------------------------------------------------------------- |
|
494 CCommsdat14Step::CCommsdat14Step() |
|
495 /** |
|
496 * Constructor |
|
497 */ |
|
498 { |
|
499 SetTestStepName(KCommsdat14Step); |
|
500 } |
|
501 |
|
502 |
|
503 TVerdict CCommsdat14Step::doTestStepL() |
|
504 /** |
|
505 * @return - TVerdict code |
|
506 * Create a CMDBField object with an element id, set attributes, check whether the attributes |
|
507 * are set and delete it |
|
508 */ |
|
509 { |
|
510 SetTestStepResult(EFail); |
|
511 INFO_PRINTF1(_L("CCommsdat14Step::doTestStepL() in the file commsdat14Step.cpp")); |
|
512 |
|
513 TMDBAttributeFlags attributes = 5; |
|
514 TBool result; |
|
515 CMDBField<TInt> *dbField = new(ELeave) CMDBField<TInt>(); |
|
516 dbField->SetAttributes(attributes); |
|
517 result = dbField->IsSetAttribute(attributes); |
|
518 |
|
519 INFO_PRINTF2(_L("Bool result = %b"), result); |
|
520 |
|
521 delete dbField; |
|
522 |
|
523 SetTestStepResult(EPass); |
|
524 return TestStepResult(); |
|
525 } |
|
526 //---------------------------------------------------------------------------------------------------------------- |
|
527 CCommsdat15Step::CCommsdat15Step() |
|
528 /** |
|
529 * Constructor |
|
530 */ |
|
531 { |
|
532 SetTestStepName(KCommsdat15Step); |
|
533 } |
|
534 |
|
535 |
|
536 TVerdict CCommsdat15Step::doTestStepL() |
|
537 /** |
|
538 * @return - TVerdict code |
|
539 * Create a CMDBField object with an element id, set attributes, clear attributes, check whether |
|
540 * the attributes are set and delete it |
|
541 */ |
|
542 { |
|
543 SetTestStepResult(EFail); |
|
544 INFO_PRINTF1(_L("CCommsdat15Step::doTestStepL() in the file commsdat15Step.cpp")); |
|
545 |
|
546 TMDBAttributeFlags attributes = ECDHidden; |
|
547 TBool result(EFalse); |
|
548 CMDBField<TInt> *dbField = new(ELeave) CMDBField<TInt>(); |
|
549 dbField->SetAttributes(attributes); |
|
550 result = dbField->IsSetAttribute(attributes); |
|
551 INFO_PRINTF3(_L("Attributes %08x should be set. Result is %b. Should be 1"), attributes, result); |
|
552 |
|
553 if(result) |
|
554 { |
|
555 dbField->ClearAttributes(attributes); |
|
556 result = dbField->IsSetAttribute(attributes); |
|
557 |
|
558 INFO_PRINTF3(_L("Attributes %08x should be cleared. Result is %b. Should be 0"), attributes, result); |
|
559 |
|
560 if(!result) |
|
561 { |
|
562 SetTestStepResult(EPass); |
|
563 } |
|
564 } |
|
565 |
|
566 delete dbField; |
|
567 return TestStepResult(); |
|
568 } |
|
569 |
|
570 //---------------------------------------------------------------------------------------------------------------- |
|
571 |
|
572 CCommsdat16Step::CCommsdat16Step() |
|
573 /** |
|
574 * Constructor |
|
575 */ |
|
576 { |
|
577 SetTestStepName(KCommsdat16Step); |
|
578 } |
|
579 |
|
580 |
|
581 TVerdict CCommsdat16Step::doTestStepL() |
|
582 /** |
|
583 * @return - TVerdict code |
|
584 * Create a CMDBRecordLink object and delete it |
|
585 */ |
|
586 { |
|
587 SetTestStepResult(EFail); |
|
588 INFO_PRINTF1(_L("CCommsdat16Step::doTestStepL() in the file commsdat16Step.cpp")); |
|
589 |
|
590 CMDBRecordLink<CCDNetworkRecord> *dbField = new(ELeave) CMDBRecordLink<CCDNetworkRecord>(); |
|
591 delete dbField; |
|
592 |
|
593 SetTestStepResult(EPass); |
|
594 return TestStepResult(); |
|
595 } |
|
596 //---------------------------------------------------------------------------------------------------------------- |
|
597 |
|
598 CCommsdat17Step::CCommsdat17Step() |
|
599 /** |
|
600 * Constructor |
|
601 */ |
|
602 { |
|
603 SetTestStepName(KCommsdat17Step); |
|
604 } |
|
605 |
|
606 |
|
607 TVerdict CCommsdat17Step::doTestStepL() |
|
608 /** |
|
609 * @return - TVerdict code |
|
610 * Create a CMDBRecordLink object with an element id and delete it |
|
611 */ |
|
612 { |
|
613 SetTestStepResult(EFail); |
|
614 INFO_PRINTF1(_L("CCommsdat17Step::doTestStepL() in the file commsdat17Step.cpp")); |
|
615 |
|
616 TMDBElementId elementId = 5; |
|
617 CMDBRecordLink<CCDNetworkRecord> *dbField = new(ELeave) CMDBRecordLink<CCDNetworkRecord>(elementId); |
|
618 delete dbField; |
|
619 |
|
620 SetTestStepResult(EPass); |
|
621 return TestStepResult(); |
|
622 } |
|
623 //---------------------------------------------------------------------------------------------------------------- |
|
624 |
|
625 CCommsdat18Step::CCommsdat18Step() |
|
626 /** |
|
627 * Constructor |
|
628 */ |
|
629 { |
|
630 SetTestStepName(KCommsdat18Step); |
|
631 } |
|
632 |
|
633 |
|
634 TVerdict CCommsdat18Step::doTestStepL() |
|
635 /** |
|
636 * @return - TVerdict code |
|
637 * Create a CMDBRecordLink object with an element id and a null element and delete it |
|
638 */ |
|
639 { |
|
640 SetTestStepResult(EFail); |
|
641 INFO_PRINTF1(_L("CCommsdat18Step::doTestStepL() in the file commsdat18Step.cpp")); |
|
642 |
|
643 TMDBElementId elementId = 5; |
|
644 CCDNetworkRecord *element = NULL; |
|
645 CMDBRecordLink<CCDNetworkRecord> *dbField = new(ELeave) CMDBRecordLink<CCDNetworkRecord>(elementId,element); |
|
646 delete dbField; |
|
647 |
|
648 SetTestStepResult(EPass); |
|
649 return TestStepResult(); |
|
650 } |
|
651 //---------------------------------------------------------------------------------------------------------------- |
|
652 CCommsdat19Step::~CCommsdat19Step() |
|
653 /** |
|
654 * Destructor |
|
655 */ |
|
656 { |
|
657 } |
|
658 |
|
659 CCommsdat19Step::CCommsdat19Step() |
|
660 /** |
|
661 * Constructor |
|
662 */ |
|
663 { |
|
664 SetTestStepName(KCommsdat19Step); |
|
665 } |
|
666 |
|
667 |
|
668 TVerdict CCommsdat19Step::doTestStepL() |
|
669 /** |
|
670 * @return - TVerdict code |
|
671 * Create a CMDBRecordLink object with an element id and an element and delete it |
|
672 */ |
|
673 { |
|
674 SetTestStepResult(EFail); |
|
675 INFO_PRINTF1(_L("CCommsdat19Step::doTestStepL() in the file commsdat19Step.cpp")); |
|
676 |
|
677 TMDBElementId elementId = 5; |
|
678 CCDNetworkRecord *element = (CCDNetworkRecord*)CCDRecordBase::RecordFactoryL(KCDTIdNetworkRecord); |
|
679 CMDBRecordLink<CCDNetworkRecord> *dbField = new(ELeave) CMDBRecordLink<CCDNetworkRecord>(elementId,element); |
|
680 delete dbField; |
|
681 |
|
682 SetTestStepResult(EPass); |
|
683 return TestStepResult(); |
|
684 } |
|
685 |
|
686 //---------------------------------------------------------------------------------------------------------------- |
|
687 CCommsdat20Step::~CCommsdat20Step() |
|
688 /** |
|
689 * Destructor |
|
690 */ |
|
691 { |
|
692 } |
|
693 |
|
694 CCommsdat20Step::CCommsdat20Step() |
|
695 /** |
|
696 * Constructor |
|
697 */ |
|
698 { |
|
699 SetTestStepName(KCommsdat20Step); |
|
700 } |
|
701 |
|
702 |
|
703 TVerdict CCommsdat20Step::doTestStepL() |
|
704 /** |
|
705 * @return - TVerdict code |
|
706 * Create a CMDBRecordLink object, check record id and delete it |
|
707 */ |
|
708 { |
|
709 SetTestStepResult(EFail); |
|
710 INFO_PRINTF1(_L("CCommsdat20Step::doTestStepL() in the file commsdat20Step.cpp")); |
|
711 |
|
712 TMDBElementId elementId = 5; |
|
713 |
|
714 INFO_PRINTF2(_L("elementId = %d"), elementId); |
|
715 |
|
716 CMDBRecordLink<CCDNetworkRecord> *dbField = new(ELeave) CMDBRecordLink<CCDNetworkRecord>(); |
|
717 |
|
718 TInt id = (elementId & KCDMaskShowRecordId) >> 8; |
|
719 if (dbField->RecordId() == id) |
|
720 { |
|
721 SetTestStepResult(EPass); |
|
722 } |
|
723 INFO_PRINTF2(_L("reset elementId = %d"), elementId); |
|
724 |
|
725 delete dbField; |
|
726 |
|
727 SetTestStepResult(EPass); |
|
728 return TestStepResult(); |
|
729 } |
|
730 //---------------------------------------------------------------------------------------------------------------- |
|
731 CCommsdat21Step::~CCommsdat21Step() |
|
732 /** |
|
733 * Destructor |
|
734 */ |
|
735 { |
|
736 } |
|
737 |
|
738 CCommsdat21Step::CCommsdat21Step() |
|
739 /** |
|
740 * Constructor |
|
741 */ |
|
742 { |
|
743 SetTestStepName(KCommsdat21Step); |
|
744 } |
|
745 |
|
746 |
|
747 TVerdict CCommsdat21Step::doTestStepL() |
|
748 /** |
|
749 * @return - TVerdict code |
|
750 * Create a CMDBRecordLink object, check linked record and delete object |
|
751 */ |
|
752 { |
|
753 SetTestStepResult(EFail); |
|
754 INFO_PRINTF1(_L("CCommsdat21Step::doTestStepL() in the file commsdat21Step.cpp")); |
|
755 |
|
756 TUint temp(0); |
|
757 |
|
758 CMDBRecordLink<CCDLocationRecord> *dbField = new(ELeave) CMDBRecordLink<CCDLocationRecord>(); |
|
759 if(dbField->iLinkedRecord == NULL) |
|
760 { |
|
761 INFO_PRINTF1(_L("iLinkedRecord is null")); |
|
762 SetTestStepResult(EPass); |
|
763 } |
|
764 |
|
765 INFO_PRINTF2(_L("linked record id = %d"), temp); |
|
766 |
|
767 |
|
768 delete dbField; |
|
769 |
|
770 return TestStepResult(); |
|
771 } |
|
772 //---------------------------------------------------------------------------------------------------------------- |
|
773 CCommsdat22Step::~CCommsdat22Step() |
|
774 /** |
|
775 * Destructor |
|
776 */ |
|
777 { |
|
778 } |
|
779 |
|
780 CCommsdat22Step::CCommsdat22Step() |
|
781 /** |
|
782 * Constructor |
|
783 */ |
|
784 { |
|
785 SetTestStepName(KCommsdat22Step); |
|
786 } |
|
787 |
|
788 |
|
789 TVerdict CCommsdat22Step::doTestStepL() |
|
790 /** |
|
791 * @return - TVerdict code |
|
792 * Create a CMDBRecordSet object and delete it |
|
793 */ |
|
794 { |
|
795 SetTestStepResult(EFail); |
|
796 INFO_PRINTF1(_L("CCommsdat22Step::doTestStepL() in the file commsdat22Step.cpp")); |
|
797 |
|
798 TMDBElementId elementLinking = 5; |
|
799 |
|
800 CMDBRecordSet<CCDNetworkRecord> *dbField = new(ELeave) CMDBRecordSet<CCDNetworkRecord>(elementLinking); |
|
801 delete dbField; |
|
802 |
|
803 SetTestStepResult(EPass); |
|
804 return TestStepResult(); |
|
805 } |
|
806 //---------------------------------------------------------------------------------------------------------------- |
|
807 CCommsdat23Step::~CCommsdat23Step() |
|
808 /** |
|
809 * Destructor |
|
810 */ |
|
811 { |
|
812 } |
|
813 |
|
814 CCommsdat23Step::CCommsdat23Step() |
|
815 /** |
|
816 * Constructor |
|
817 */ |
|
818 { |
|
819 SetTestStepName(KCommsdat23Step); |
|
820 } |
|
821 |
|
822 |
|
823 TVerdict CCommsdat23Step::doTestStepL() |
|
824 /** |
|
825 * @return - TVerdict code |
|
826 * Create a CMDBSession object, check the version info and delete it |
|
827 */ |
|
828 { |
|
829 SetTestStepResult(EFail); |
|
830 INFO_PRINTF1(_L("CCommsdat23Step::doTestStepL() in the file commsdat23Step.cpp")); |
|
831 |
|
832 CMDBSession *cmdbSession = CMDBSession::NewL(CMDBSession::LatestVersion()); |
|
833 CleanupStack::PushL(cmdbSession); |
|
834 TVersion versionInUse = cmdbSession->VersionInUse(); |
|
835 if(versionInUse.iBuild != CMDBSession::LatestVersion().iBuild ) |
|
836 { |
|
837 INFO_PRINTF1(_L("Something wrong with handling of build version information")); |
|
838 } |
|
839 if(versionInUse.iMajor != CMDBSession::LatestVersion().iMajor ) |
|
840 { |
|
841 INFO_PRINTF1(_L("Something wrong with handling of major version information")); |
|
842 } |
|
843 if(versionInUse.iMinor != CMDBSession::LatestVersion().iMinor ) |
|
844 { |
|
845 INFO_PRINTF1(_L("Something wrong with handling of minor version information")); |
|
846 } |
|
847 |
|
848 if(versionInUse.iBuild == CMDBSession::LatestVersion().iBuild && |
|
849 versionInUse.iMajor == CMDBSession::LatestVersion().iMajor && |
|
850 versionInUse.iMinor == CMDBSession::LatestVersion().iMinor) |
|
851 { |
|
852 SetTestStepResult(EPass); |
|
853 } |
|
854 |
|
855 CleanupStack::PopAndDestroy(cmdbSession); |
|
856 return TestStepResult(); |
|
857 } |
|
858 //---------------------------------------------------------------------------------------------------------------- |
|
859 CCommsdat24Step::~CCommsdat24Step() |
|
860 /** |
|
861 * Destructor |
|
862 */ |
|
863 { |
|
864 } |
|
865 |
|
866 CCommsdat24Step::CCommsdat24Step() |
|
867 /** |
|
868 * Constructor |
|
869 */ |
|
870 { |
|
871 SetTestStepName(KCommsdat24Step); |
|
872 } |
|
873 |
|
874 |
|
875 TVerdict CCommsdat24Step::doTestStepL() |
|
876 /** |
|
877 * @return - TVerdict code |
|
878 * Create a CMDBSession object, check transaction status and delete it |
|
879 */ |
|
880 { |
|
881 SetTestStepResult(EFail); |
|
882 INFO_PRINTF1(_L("Opening and closing transactions - CCommsdat24Step::doTestStepL() in the file commsdat24Step.cpp")); |
|
883 |
|
884 #ifdef SYMBIAN_NON_SEAMLESS_NETWORK_BEARER_MOBILITY |
|
885 CMDBSession *cmdbSession = CMDBSession::NewL(KCDVersion1_2); |
|
886 #else |
|
887 CMDBSession *cmdbSession = CMDBSession::NewL(KCDVersion1_1); |
|
888 #endif |
|
889 |
|
890 CleanupStack::PushL(cmdbSession); |
|
891 |
|
892 cmdbSession->OpenTransactionL(); |
|
893 TBool inTransaction = cmdbSession->IsInTransaction(); |
|
894 if(!inTransaction) |
|
895 { |
|
896 INFO_PRINTF1(_L("Something wrong with opening transaction")); |
|
897 } |
|
898 |
|
899 cmdbSession->RollbackTransactionL(); |
|
900 |
|
901 TBool notInTransactionRollback = cmdbSession->IsInTransaction(); |
|
902 if(notInTransactionRollback) |
|
903 { |
|
904 INFO_PRINTF1(_L("Something wrong with rolling back transaction")); |
|
905 } |
|
906 |
|
907 cmdbSession->OpenTransactionL(); |
|
908 cmdbSession->CommitTransactionL(); |
|
909 |
|
910 TBool notInTransactionCommit = cmdbSession->IsInTransaction(); |
|
911 if(notInTransactionCommit) |
|
912 { |
|
913 INFO_PRINTF1(_L("Something wrong with comitting transaction")); |
|
914 } |
|
915 |
|
916 CleanupStack::PopAndDestroy(cmdbSession); |
|
917 |
|
918 if(inTransaction && !notInTransactionRollback && !notInTransactionCommit) |
|
919 { |
|
920 SetTestStepResult(EPass); |
|
921 } |
|
922 |
|
923 return TestStepResult(); |
|
924 } |
|
925 //---------------------------------------------------------------------------------------------------------------- |
|
926 CCommsdat25Step::~CCommsdat25Step() |
|
927 /** |
|
928 * Destructor |
|
929 */ |
|
930 { |
|
931 } |
|
932 |
|
933 CCommsdat25Step::CCommsdat25Step() |
|
934 /** |
|
935 * Constructor |
|
936 */ |
|
937 { |
|
938 SetTestStepName(KCommsdat25Step); |
|
939 } |
|
940 |
|
941 |
|
942 TVerdict CCommsdat25Step::doTestStepL() |
|
943 /** |
|
944 * @return - TVerdict code |
|
945 * Create a CMDBSession, set attribute mask and delete it |
|
946 */ |
|
947 { |
|
948 SetTestStepResult(EFail); |
|
949 INFO_PRINTF1(_L("CCommsdat25Step::doTestStepL() in the file commsdat25Step.cpp")); |
|
950 |
|
951 #ifdef SYMBIAN_NON_SEAMLESS_NETWORK_BEARER_MOBILITY |
|
952 CMDBSession *cmdbSession = CMDBSession::NewL(KCDVersion1_2); |
|
953 #else |
|
954 CMDBSession *cmdbSession = CMDBSession::NewL(KCDVersion1_1); |
|
955 #endif |
|
956 |
|
957 CleanupStack::PushL(cmdbSession); |
|
958 |
|
959 cmdbSession->SetAttributeMask(ECDHidden | ECDPrivate ); |
|
960 |
|
961 SetTestStepResult(EPass); |
|
962 CleanupStack::PopAndDestroy(cmdbSession); |
|
963 return TestStepResult(); |
|
964 } |
|
965 //---------------------------------------------------------------------------------------------------------------- |
|
966 #ifndef __TOOLS2__ |
|
967 // This test is not used on the TOOLS2 platform. |
|
968 CCommsdat26Step::~CCommsdat26Step() |
|
969 /** |
|
970 * Destructor |
|
971 */ |
|
972 { |
|
973 } |
|
974 |
|
975 CCommsdat26Step::CCommsdat26Step() |
|
976 /** |
|
977 * Constructor |
|
978 */ |
|
979 { |
|
980 SetTestStepName(KCommsdat26Step); |
|
981 } |
|
982 |
|
983 |
|
984 TVerdict CCommsdat26Step::doTestStepL() |
|
985 /** |
|
986 * @return - TVerdict code |
|
987 * Create a CMDBSession object, publish properties and delete it. |
|
988 */ |
|
989 { |
|
990 SetTestStepResult(EFail); |
|
991 INFO_PRINTF1(_L("I am in CCommsdat26Step::doTestStepL() and trying to test Publish Properties")); |
|
992 |
|
993 #ifdef SYMBIAN_NON_SEAMLESS_NETWORK_BEARER_MOBILITY |
|
994 CMDBSession *cmdbSession = CMDBSession::NewL(KCDVersion1_2); |
|
995 #else |
|
996 CMDBSession *cmdbSession = CMDBSession::NewL(KCDVersion1_1); |
|
997 #endif |
|
998 |
|
999 CleanupStack::PushL(cmdbSession); |
|
1000 TRAPD(err, cmdbSession->PublishProperties()) |
|
1001 |
|
1002 CleanupStack::PopAndDestroy(cmdbSession); |
|
1003 |
|
1004 if(err == KErrNone) |
|
1005 { |
|
1006 SetTestStepResult(EPass); |
|
1007 } |
|
1008 |
|
1009 return TestStepResult(); |
|
1010 } |
|
1011 #endif |
|
1012 //---------------------------------------------------------------------------------------------------------------- |
|
1013 CCommsdat27Step::~CCommsdat27Step() |
|
1014 /** |
|
1015 * Destructor |
|
1016 */ |
|
1017 { |
|
1018 } |
|
1019 |
|
1020 CCommsdat27Step::CCommsdat27Step() |
|
1021 /** |
|
1022 * Constructor |
|
1023 */ |
|
1024 { |
|
1025 SetTestStepName(KCommsdat27Step); |
|
1026 } |
|
1027 |
|
1028 |
|
1029 TVerdict CCommsdat27Step::doTestStepL() |
|
1030 /** |
|
1031 * @return - TVerdict code |
|
1032 * Create a CMDBSession object, publish properties and delete it. |
|
1033 */ |
|
1034 { |
|
1035 SetTestStepResult(EFail); |
|
1036 |
|
1037 INFO_PRINTF1(_L("Reading templated value underneath empty record")); |
|
1038 |
|
1039 #ifdef SYMBIAN_NON_SEAMLESS_NETWORK_BEARER_MOBILITY |
|
1040 CMDBSession *cmdbSession = CMDBSession::NewL(KCDVersion1_2); |
|
1041 #else |
|
1042 CMDBSession *cmdbSession = CMDBSession::NewL(KCDVersion1_1); |
|
1043 #endif |
|
1044 CleanupStack::PushL(cmdbSession); |
|
1045 |
|
1046 CCDModemBearerRecord *mbRecord = (CCDModemBearerRecord*)CCDRecordBase::RecordFactoryL(KCDTIdModemBearerRecord); |
|
1047 CleanupStack::PushL(mbRecord); |
|
1048 |
|
1049 // create record No.1 with |
|
1050 mbRecord->SetRecordId(1); |
|
1051 mbRecord->iSpeakerVolPref = 1; |
|
1052 |
|
1053 mbRecord->StoreL(*cmdbSession); |
|
1054 |
|
1055 // create TemplateRecord |
|
1056 mbRecord->SetRecordId(KCDDefaultRecord); |
|
1057 mbRecord->iSpeakerPref = 1; |
|
1058 |
|
1059 mbRecord->StoreL(*cmdbSession); |
|
1060 |
|
1061 // create field looking at speakerPref |
|
1062 CMDBField<TUint32>* speakerPrefField = new(ELeave) CMDBField<TUint32>(KCDTIdSpeakerPref); |
|
1063 CleanupStack::PushL(speakerPrefField); |
|
1064 // load the speakerPref from record No.1 which is Null value |
|
1065 // The data from the template should be loaded giving the value of 1, not null |
|
1066 speakerPrefField->SetRecordId(1); |
|
1067 speakerPrefField->LoadL(*cmdbSession); |
|
1068 |
|
1069 if (speakerPrefField->IsNull()) |
|
1070 { |
|
1071 // return with failure because template value was not found |
|
1072 return TestStepResult(); |
|
1073 } |
|
1074 |
|
1075 if(*speakerPrefField == 1) |
|
1076 |
|
1077 { |
|
1078 SetTestStepResult(EPass); |
|
1079 } |
|
1080 |
|
1081 CleanupStack::PopAndDestroy(speakerPrefField); |
|
1082 |
|
1083 CleanupStack::PopAndDestroy(mbRecord); |
|
1084 |
|
1085 CleanupStack::PopAndDestroy(cmdbSession); |
|
1086 |
|
1087 return TestStepResult(); |
|
1088 } |
|
1089 //---------------------------------------------------------------------------------------------------------------- |
|
1090 CCommsdat28Step::~CCommsdat28Step() |
|
1091 /** |
|
1092 * Destructor |
|
1093 */ |
|
1094 { |
|
1095 } |
|
1096 |
|
1097 CCommsdat28Step::CCommsdat28Step() |
|
1098 /** |
|
1099 * Constructor |
|
1100 */ |
|
1101 { |
|
1102 SetTestStepName(KCommsdat28Step); |
|
1103 } |
|
1104 |
|
1105 TVerdict CCommsdat28Step::doTestStepL() |
|
1106 /** |
|
1107 * @return - TVerdict code |
|
1108 * Create a CMDBRecordLink object and delete it |
|
1109 */ |
|
1110 { |
|
1111 SetTestStepResult(EFail); |
|
1112 |
|
1113 INFO_PRINTF1(_L("CCommsdat28Step::doTestStepL() in the file commsdat28Step.cpp")); |
|
1114 |
|
1115 #ifdef SYMBIAN_NON_SEAMLESS_NETWORK_BEARER_MOBILITY |
|
1116 CMDBSession *cmdbSession = CMDBSession::NewL(KCDVersion1_2); |
|
1117 #else |
|
1118 CMDBSession *cmdbSession = CMDBSession::NewL(KCDVersion1_1); |
|
1119 #endif |
|
1120 CleanupStack::PushL(cmdbSession); |
|
1121 |
|
1122 //-- Load Linked with tag record test |
|
1123 |
|
1124 CCDIAPRecord *anIAPRecord = (CCDIAPRecord*)CCDRecordBase::RecordFactoryL(KCDTIdIAPRecord); |
|
1125 CleanupStack::PushL(anIAPRecord); |
|
1126 |
|
1127 anIAPRecord->SetRecordId(1); |
|
1128 anIAPRecord->LoadL(*cmdbSession); |
|
1129 |
|
1130 CCDLocationRecord* locationRecord = anIAPRecord->iLocation; |
|
1131 |
|
1132 if (locationRecord) |
|
1133 { |
|
1134 // Oops Loading the IAP record mustn't automatically create records linked fields too. |
|
1135 return TestStepResult(); |
|
1136 } |
|
1137 |
|
1138 anIAPRecord->iLocation.LoadL(*cmdbSession); |
|
1139 |
|
1140 locationRecord = anIAPRecord->iLocation; |
|
1141 |
|
1142 if(!locationRecord || locationRecord->iPauseAfterDialOut != 1) |
|
1143 { |
|
1144 return TestStepResult(); |
|
1145 } |
|
1146 |
|
1147 |
|
1148 CCDServiceRecordBase* serviceRecord = anIAPRecord->iService; |
|
1149 |
|
1150 if (serviceRecord) |
|
1151 { |
|
1152 // Oops LoadLing the IAP record mustn't automatically create records linked fields too. |
|
1153 return TestStepResult(); |
|
1154 } |
|
1155 |
|
1156 /* Uncomment when validating general links correctly.*/ |
|
1157 anIAPRecord->iService.LoadL(*cmdbSession); |
|
1158 |
|
1159 serviceRecord = anIAPRecord->iService; |
|
1160 |
|
1161 if (!serviceRecord) // TODO - add the llmnr field to this test ced and check that here |
|
1162 { |
|
1163 return TestStepResult(); |
|
1164 } |
|
1165 |
|
1166 // ENHANCE - could also check the type of the service record matches the type named in ServiceType field |
|
1167 |
|
1168 |
|
1169 CleanupStack::PopAndDestroy(anIAPRecord); |
|
1170 |
|
1171 |
|
1172 //-- Find Linked record test |
|
1173 |
|
1174 CCDIAPRecord* IAPRecord1 = static_cast<CCDIAPRecord*>(CCDRecordBase::RecordFactoryL(KCDTIdIAPRecord)); |
|
1175 CleanupStack::PushL(IAPRecord1); |
|
1176 |
|
1177 IAPRecord1->SetRecordId(2); |
|
1178 IAPRecord1->LoadL(*cmdbSession); |
|
1179 |
|
1180 IAPRecord1->iLocation.SetRecordId(2); |
|
1181 |
|
1182 CCDLocationRecord* LocationRecord1 = IAPRecord1->iLocation; // will be NULL at first |
|
1183 |
|
1184 LocationRecord1 = static_cast<CCDLocationRecord*>(CCDRecordBase::RecordFactoryL(KCDTIdLocationRecord)); |
|
1185 |
|
1186 if(! LocationRecord1 ) |
|
1187 { |
|
1188 return TestStepResult(); |
|
1189 } |
|
1190 |
|
1191 LocationRecord1->iPauseAfterDialOut = 2; |
|
1192 /* |
|
1193 if (! IAPRecord1->iLocation.FindL(*cmdbSession)) |
|
1194 { |
|
1195 return TestStepResult(); |
|
1196 } |
|
1197 */ |
|
1198 if(LocationRecord1->iPauseAfterDialOut == 2) // TODO - find some other field |
|
1199 { |
|
1200 SetTestStepResult(EPass); |
|
1201 } |
|
1202 |
|
1203 CleanupStack::PopAndDestroy(IAPRecord1); // will cleanup all linked fields too. |
|
1204 |
|
1205 CleanupStack::PopAndDestroy(cmdbSession); |
|
1206 |
|
1207 return TestStepResult(); |
|
1208 } |
|
1209 |
|
1210 //---------------------------------------------------------------------------------------------------------------- |
|
1211 CCommsdat29Step::~CCommsdat29Step() |
|
1212 /** |
|
1213 * Destructor |
|
1214 */ |
|
1215 { |
|
1216 } |
|
1217 |
|
1218 CCommsdat29Step::CCommsdat29Step() |
|
1219 /** |
|
1220 * Constructor |
|
1221 */ |
|
1222 { |
|
1223 SetTestStepName(KCommsdat29Step); |
|
1224 } |
|
1225 |
|
1226 TVerdict CCommsdat29Step::doTestStepL() |
|
1227 { |
|
1228 SetTestStepResult(EFail); |
|
1229 |
|
1230 INFO_PRINTF1(_L("CCommsdat29Step::doTestStepL() in the file commsdat29Step.cpp")); |
|
1231 |
|
1232 #ifdef SYMBIAN_NON_SEAMLESS_NETWORK_BEARER_MOBILITY |
|
1233 CMDBSession *cmdbSession = CMDBSession::NewL(KCDVersion1_2); |
|
1234 #else |
|
1235 CMDBSession *cmdbSession = CMDBSession::NewL(KCDVersion1_1); |
|
1236 #endif |
|
1237 CleanupStack::PushL(cmdbSession); |
|
1238 |
|
1239 //-- Load a CMDBField from the database |
|
1240 |
|
1241 CMDBField<TUint32>* intervalField = new(ELeave) CMDBField<TUint32>(KCDTIdPauseAfterDialOut); |
|
1242 CleanupStack::PushL(intervalField); |
|
1243 intervalField->SetRecordId(1); |
|
1244 intervalField->LoadL(*cmdbSession); |
|
1245 |
|
1246 CleanupStack::PopAndDestroy(intervalField); |
|
1247 CleanupStack::PopAndDestroy(cmdbSession); |
|
1248 |
|
1249 SetTestStepResult(EPass); |
|
1250 |
|
1251 return TestStepResult(); |
|
1252 } |
|
1253 |
|
1254 |
|
1255 //---------------------------------------------------------------------------------------------------------------- |
|
1256 |
|
1257 CCommsdat30Step::~CCommsdat30Step() |
|
1258 /** |
|
1259 * Destructor |
|
1260 */ |
|
1261 { |
|
1262 } |
|
1263 |
|
1264 CCommsdat30Step::CCommsdat30Step() |
|
1265 /** |
|
1266 * Constructor |
|
1267 */ |
|
1268 { |
|
1269 SetTestStepName(KCommsdat30Step); |
|
1270 } |
|
1271 |
|
1272 //This code here is from the TSYCONFIG.cpp file... |
|
1273 TVerdict CCommsdat30Step::doTestStepL() |
|
1274 { |
|
1275 SetTestStepResult(EFail); |
|
1276 |
|
1277 INFO_PRINTF1(_L("CCommsdat30Step::doTestStepL()")); |
|
1278 |
|
1279 #ifdef SYMBIAN_NON_SEAMLESS_NETWORK_BEARER_MOBILITY |
|
1280 CMDBSession *cmdbSession = CMDBSession::NewL(KCDVersion1_2); |
|
1281 #else |
|
1282 CMDBSession *cmdbSession = CMDBSession::NewL(KCDVersion1_1); |
|
1283 #endif |
|
1284 CleanupStack::PushL(cmdbSession); |
|
1285 |
|
1286 //-------------------------------- part 1 --------------------------------- |
|
1287 INFO_PRINTF1(_L("Loading the ModemRecord...")); |
|
1288 CCDModemBearerRecord *modemRecord = static_cast<CCDModemBearerRecord*>(CCDRecordBase::RecordFactoryL(KCDTIdModemBearerRecord)); |
|
1289 CleanupStack::PushL(modemRecord); |
|
1290 |
|
1291 _LIT(KTsyName,"MM"); |
|
1292 modemRecord->iTsyName.SetMaxLengthL(KMaxTextLength); |
|
1293 modemRecord->iTsyName = KTsyName; |
|
1294 |
|
1295 TBool searchResult = modemRecord->FindL(*cmdbSession); |
|
1296 |
|
1297 TUint32 bearerId(0); |
|
1298 |
|
1299 if (searchResult) |
|
1300 { |
|
1301 INFO_PRINTF1(_L("OK, found the ModemRecord...")); |
|
1302 |
|
1303 bearerId = modemRecord->RecordId(); |
|
1304 |
|
1305 INFO_PRINTF2(_L("so the bearerId : %d"),bearerId); |
|
1306 } |
|
1307 else |
|
1308 { |
|
1309 bearerId = static_cast<TUint32>(KErrNotFound); |
|
1310 } |
|
1311 |
|
1312 CleanupStack::PopAndDestroy(modemRecord); |
|
1313 |
|
1314 //-------------------------------- part 2 --------------------------------- |
|
1315 INFO_PRINTF1(_L("Finding the location ID in the IAP record...")); |
|
1316 |
|
1317 CCDIAPRecord *iapRecord = static_cast<CCDIAPRecord*>(CCDRecordBase::RecordFactoryL(KCDTIdIAPRecord)); |
|
1318 CleanupStack::PushL(iapRecord); |
|
1319 |
|
1320 TUint32 locationId(0); |
|
1321 |
|
1322 iapRecord->iBearer = bearerId; |
|
1323 TBool err = iapRecord->FindL(*cmdbSession); |
|
1324 if (err) |
|
1325 { |
|
1326 INFO_PRINTF1(_L("OK, found the ModemRecord...")); |
|
1327 |
|
1328 locationId = iapRecord->iLocation; |
|
1329 |
|
1330 INFO_PRINTF2(_L("so the locationId : %d"),locationId); |
|
1331 |
|
1332 } |
|
1333 else |
|
1334 { |
|
1335 locationId = static_cast<TUint32>(KErrNotFound); |
|
1336 } |
|
1337 |
|
1338 CleanupStack::PopAndDestroy(iapRecord); |
|
1339 |
|
1340 TBool goOn = EFalse; |
|
1341 |
|
1342 if (bearerId == 2 && locationId == 4) |
|
1343 { |
|
1344 goOn = ETrue; |
|
1345 } |
|
1346 |
|
1347 if (goOn) |
|
1348 { |
|
1349 goOn = EFalse; |
|
1350 //Finding the IAP record based on the service field |
|
1351 CCDIAPRecord *iapRecord1 = static_cast<CCDIAPRecord*>(CCDRecordBase::RecordFactoryL(KCDTIdIAPRecord)); |
|
1352 CleanupStack::PushL(iapRecord1); |
|
1353 |
|
1354 iapRecord1->iService = 2; |
|
1355 err = iapRecord1->FindL(*cmdbSession); |
|
1356 |
|
1357 if (err) |
|
1358 { |
|
1359 locationId = iapRecord1->iLocation; |
|
1360 bearerId = iapRecord1->iBearer; |
|
1361 |
|
1362 if (bearerId == 2 && locationId == 4) |
|
1363 { |
|
1364 //SetTestStepResult(EPass); |
|
1365 goOn = ETrue; |
|
1366 } |
|
1367 } |
|
1368 CleanupStack::PopAndDestroy(iapRecord1); |
|
1369 } |
|
1370 |
|
1371 //------------------------------------- part 2 -------------------------------- |
|
1372 //Fingind an IAP record based on the location id |
|
1373 if (goOn) |
|
1374 { |
|
1375 CCDIAPRecord *iapRecord2 = static_cast<CCDIAPRecord*>(CCDRecordBase::RecordFactoryL(KCDTIdIAPRecord)); |
|
1376 CleanupStack::PushL(iapRecord2); |
|
1377 |
|
1378 iapRecord2->iLocation = 4; |
|
1379 err = iapRecord2->FindL(*cmdbSession); |
|
1380 |
|
1381 if (err) |
|
1382 { |
|
1383 TInt service = iapRecord2->iService; |
|
1384 bearerId = iapRecord2->iBearer; |
|
1385 |
|
1386 if (bearerId == 2 && service == 2) |
|
1387 { |
|
1388 SetTestStepResult(EPass); |
|
1389 } |
|
1390 } |
|
1391 CleanupStack::PopAndDestroy(iapRecord2); |
|
1392 } |
|
1393 |
|
1394 |
|
1395 CleanupStack::PopAndDestroy(cmdbSession); |
|
1396 |
|
1397 return TestStepResult(); |
|
1398 } |
|
1399 |
|
1400 //---------------------------------------------------------------------------------------------------------------- |
|
1401 |
|
1402 CCommsdat31Step::~CCommsdat31Step() |
|
1403 /** |
|
1404 * Destructor |
|
1405 */ |
|
1406 { |
|
1407 } |
|
1408 |
|
1409 CCommsdat31Step::CCommsdat31Step() |
|
1410 /** |
|
1411 * Constructor |
|
1412 */ |
|
1413 { |
|
1414 SetTestStepName(KCommsdat31Step); |
|
1415 } |
|
1416 |
|
1417 //This code here is from the TSYCONFIG.cpp file... |
|
1418 TVerdict CCommsdat31Step::doTestStepL() |
|
1419 { |
|
1420 SetTestStepResult(EFail); |
|
1421 |
|
1422 INFO_PRINTF1(_L("CCommsdat31Step::doTestStepL()")); |
|
1423 |
|
1424 #ifdef SYMBIAN_NON_SEAMLESS_NETWORK_BEARER_MOBILITY |
|
1425 CMDBSession *cmdbSession = CMDBSession::NewL(KCDVersion1_2); |
|
1426 #else |
|
1427 CMDBSession *cmdbSession = CMDBSession::NewL(KCDVersion1_1); |
|
1428 #endif |
|
1429 CleanupStack::PushL(cmdbSession); |
|
1430 |
|
1431 INFO_PRINTF1(_L("Loading the ProxiesRecord...")); |
|
1432 CCDProxiesRecord *proxiesRecord = static_cast<CCDProxiesRecord*>(CCDRecordBase::RecordFactoryL(KCDTIdProxiesRecord)); |
|
1433 CleanupStack::PushL(proxiesRecord); |
|
1434 |
|
1435 TUint32 portNumber(0); |
|
1436 |
|
1437 proxiesRecord->iService = 4; //the value 4 is from the database... |
|
1438 TBool err = proxiesRecord->FindL(*cmdbSession); |
|
1439 if (err) |
|
1440 { |
|
1441 INFO_PRINTF1(_L("OK, found the ProxiesRecord...")); |
|
1442 |
|
1443 portNumber = proxiesRecord->iPortNumber; |
|
1444 |
|
1445 INFO_PRINTF2(_L("so the portnumber : %d"),portNumber); |
|
1446 |
|
1447 } |
|
1448 else |
|
1449 { |
|
1450 portNumber = static_cast<TUint32>(KErrNotFound); |
|
1451 } |
|
1452 |
|
1453 CleanupStack::PopAndDestroy(proxiesRecord); |
|
1454 |
|
1455 if (portNumber == 80) |
|
1456 { |
|
1457 SetTestStepResult(EPass); |
|
1458 } |
|
1459 |
|
1460 CleanupStack::PopAndDestroy(cmdbSession); |
|
1461 |
|
1462 return TestStepResult(); |
|
1463 } |
|
1464 |
|
1465 //---------------------------------------------------------------------------------------------------------------- |
|
1466 |
|
1467 CCommsdat32Step::~CCommsdat32Step() |
|
1468 /** |
|
1469 * Destructor |
|
1470 */ |
|
1471 { |
|
1472 } |
|
1473 |
|
1474 CCommsdat32Step::CCommsdat32Step() |
|
1475 /** |
|
1476 * Constructor |
|
1477 */ |
|
1478 { |
|
1479 SetTestStepName(KCommsdat32Step); |
|
1480 } |
|
1481 |
|
1482 //This code here is from the TSYCONFIG.cpp file... |
|
1483 TVerdict CCommsdat32Step::doTestStepL() |
|
1484 { |
|
1485 SetTestStepResult(EFail); |
|
1486 |
|
1487 INFO_PRINTF1(_L("CCommsdat32Step::doTestStepL()")); |
|
1488 |
|
1489 #ifdef SYMBIAN_NON_SEAMLESS_NETWORK_BEARER_MOBILITY |
|
1490 CMDBSession *cmdbSession = CMDBSession::NewL(KCDVersion1_2); |
|
1491 #else |
|
1492 CMDBSession *cmdbSession = CMDBSession::NewL(KCDVersion1_1); |
|
1493 #endif |
|
1494 CleanupStack::PushL(cmdbSession); |
|
1495 |
|
1496 INFO_PRINTF1(_L("Loading the LanServiceRecord...")); |
|
1497 CCDLANServiceRecord *lanserviceRecord = static_cast<CCDLANServiceRecord*>(CCDRecordBase::RecordFactoryL(KCDTIdLANServiceRecord)); |
|
1498 CleanupStack::PushL(lanserviceRecord); |
|
1499 |
|
1500 |
|
1501 lanserviceRecord->iServiceExtensionTableRecordId = 1; //the value 1 is from the database... |
|
1502 TBool err = lanserviceRecord->FindL(*cmdbSession); |
|
1503 if (err) |
|
1504 { |
|
1505 INFO_PRINTF1(_L("OK, found the LanServiceRecord...")); |
|
1506 |
|
1507 TPtrC ipAddr(lanserviceRecord->iIpAddr); |
|
1508 |
|
1509 INFO_PRINTF2(_L("so the ipAddr : %S"),&ipAddr); |
|
1510 |
|
1511 _LIT(KIPAddr,"172.16.0.1"); //the value is from the DB... |
|
1512 |
|
1513 if (ipAddr == KIPAddr) |
|
1514 { |
|
1515 SetTestStepResult(EPass); |
|
1516 } |
|
1517 } |
|
1518 else |
|
1519 { |
|
1520 INFO_PRINTF1(_L("NOT found the LanServiceRecord...")); |
|
1521 } |
|
1522 |
|
1523 CleanupStack::PopAndDestroy(lanserviceRecord); |
|
1524 |
|
1525 CleanupStack::PopAndDestroy(cmdbSession); |
|
1526 |
|
1527 return TestStepResult(); |
|
1528 } |
|
1529 |
|
1530 |
|
1531 //---------------------------------------------------------------------------------------------------------------- |
|
1532 |
|
1533 CCommsdat33Step::~CCommsdat33Step() |
|
1534 /** |
|
1535 * Destructor |
|
1536 */ |
|
1537 { |
|
1538 } |
|
1539 |
|
1540 CCommsdat33Step::CCommsdat33Step() |
|
1541 /** |
|
1542 * Constructor |
|
1543 */ |
|
1544 { |
|
1545 SetTestStepName(KCommsdat33Step); |
|
1546 } |
|
1547 |
|
1548 TVerdict CCommsdat33Step::doTestStepL() |
|
1549 { |
|
1550 /* This test test the reading of the link between a WAPAccessPoint and a WAPIPBearer |
|
1551 * record. The reading happens backwards, meaning that based on the recordID of the linked WAPAP |
|
1552 * recrod we try to find the linking WAPIPBearer record. |
|
1553 */ |
|
1554 SetTestStepResult(EFail); |
|
1555 |
|
1556 INFO_PRINTF1(_L("CCommsdat33Step::doTestStepL() - Find a WapIpBearer record based on AccessPointId")); |
|
1557 |
|
1558 #ifdef SYMBIAN_NON_SEAMLESS_NETWORK_BEARER_MOBILITY |
|
1559 CMDBSession *cmdbSession = CMDBSession::NewL(KCDVersion1_2); |
|
1560 #else |
|
1561 CMDBSession *cmdbSession = CMDBSession::NewL(KCDVersion1_1); |
|
1562 #endif |
|
1563 CleanupStack::PushL(cmdbSession); |
|
1564 |
|
1565 INFO_PRINTF1(_L("Finding the WapIpBearer record...")); |
|
1566 |
|
1567 CMDBRecordSet<CCDWAPIPBearerRecord>* recordSet = new(ELeave) CMDBRecordSet<CCDWAPIPBearerRecord>(KCDTIdWAPIPBearerRecord); |
|
1568 CleanupStack::PushL(recordSet); |
|
1569 |
|
1570 |
|
1571 CCDWAPIPBearerRecord *wapIPBearer = static_cast<CCDWAPIPBearerRecord*>(CCDRecordBase::RecordFactoryL(KCDTIdWAPIPBearerRecord)); |
|
1572 CleanupStack::PushL(wapIPBearer); |
|
1573 wapIPBearer->iWAPAccessPointId = 4; //the value 4 is from the database... |
|
1574 |
|
1575 //ownership of 'wapIPBearer' goes to the recordSet... |
|
1576 recordSet->iRecords.AppendL(wapIPBearer); |
|
1577 CleanupStack::Pop(wapIPBearer); |
|
1578 |
|
1579 TBool err = recordSet->FindL(*cmdbSession); |
|
1580 if (err) |
|
1581 { |
|
1582 INFO_PRINTF1(_L("OK, found the WapIpBearer Record...")); |
|
1583 |
|
1584 TInt iap = wapIPBearer->iWAPIAP; |
|
1585 |
|
1586 INFO_PRINTF2(_L("so the iap : %d"),iap); |
|
1587 |
|
1588 |
|
1589 if (iap == 4) //4 from the database |
|
1590 { |
|
1591 SetTestStepResult(EPass); |
|
1592 } |
|
1593 } |
|
1594 else |
|
1595 { |
|
1596 INFO_PRINTF1(_L("NOT found the WapIpBearer Record...")); |
|
1597 } |
|
1598 |
|
1599 CleanupStack::PopAndDestroy(recordSet); |
|
1600 CleanupStack::PopAndDestroy(cmdbSession); |
|
1601 |
|
1602 return TestStepResult(); |
|
1603 } |
|
1604 |
|
1605 //---------------------------------------------------------------------------------------------------------------- |
|
1606 |
|
1607 CCommsdat34Step::~CCommsdat34Step() |
|
1608 /** |
|
1609 * Destructor |
|
1610 */ |
|
1611 { |
|
1612 } |
|
1613 |
|
1614 CCommsdat34Step::CCommsdat34Step() |
|
1615 /** |
|
1616 * Constructor |
|
1617 */ |
|
1618 { |
|
1619 SetTestStepName(KCommsdat34Step); |
|
1620 } |
|
1621 |
|
1622 TVerdict CCommsdat34Step::doTestStepL() |
|
1623 { |
|
1624 SetTestStepResult(EFail); |
|
1625 |
|
1626 INFO_PRINTF1(_L("CCommsdat34Step::doTestStepL()")); |
|
1627 |
|
1628 #ifdef SYMBIAN_NON_SEAMLESS_NETWORK_BEARER_MOBILITY |
|
1629 CMDBSession *cmdbSession = CMDBSession::NewL(KCDVersion1_2); |
|
1630 #else |
|
1631 CMDBSession *cmdbSession = CMDBSession::NewL(KCDVersion1_1); |
|
1632 #endif |
|
1633 CleanupStack::PushL(cmdbSession); |
|
1634 |
|
1635 INFO_PRINTF1(_L("Loading the ProxiesRecord...")); |
|
1636 CCDProxiesRecord *proxiRecord = static_cast<CCDProxiesRecord*>(CCDRecordBase::RecordFactoryL(KCDTIdProxiesRecord)); |
|
1637 CleanupStack::PushL(proxiRecord); |
|
1638 |
|
1639 proxiRecord->iService = 6; |
|
1640 proxiRecord->FindL(*cmdbSession); |
|
1641 |
|
1642 //---- just to check whether the correct record is read... |
|
1643 { |
|
1644 CMDBField<TDesC>& proxyServerNameField = proxiRecord->iServerName; |
|
1645 CMDBField<TDesC>& recordNameField = proxiRecord->iRecordName; |
|
1646 TPtrC serverName(proxyServerNameField); |
|
1647 TPtrC recordName(recordNameField); |
|
1648 _LIT(KExpectedServerName, "Dummy Server Name"); |
|
1649 _LIT(KExpectedRecordName, "DefaultRecordName-2"); |
|
1650 |
|
1651 TESTL((serverName.Compare(KExpectedServerName) == 0) && (recordName.Compare(KExpectedRecordName) == 0)); |
|
1652 } |
|
1653 //-------------------------------------------------------- |
|
1654 |
|
1655 _LIT(KModifiedName, "janos_modified"); |
|
1656 CMDBField<TDesC>& nameField = proxiRecord->iRecordName; |
|
1657 TPtrC name(nameField); |
|
1658 nameField.SetMaxLengthL(KModifiedName().Length()); |
|
1659 nameField.SetL(KModifiedName); |
|
1660 |
|
1661 INFO_PRINTF1(_L("Modifying the ProxiesRecord...")); |
|
1662 proxiRecord->ModifyL(*cmdbSession); |
|
1663 |
|
1664 CleanupStack::PopAndDestroy(proxiRecord); |
|
1665 |
|
1666 CMDBField<TDesC>* proxyServerNameField = new (ELeave) CMDBField<TDesC>(KCDTIdProxiesRecord | KCDTIdServerName); |
|
1667 CleanupStack::PushL(proxyServerNameField); |
|
1668 proxyServerNameField->SetRecordId(2); |
|
1669 |
|
1670 /* This LoadL shouldn't leave. The field is loaded from the template record but the record id should be the |
|
1671 * correct one - in this case 2. This was overwritten by commsdat to 0 as the field was loaded from the template |
|
1672 * rec. |
|
1673 */ |
|
1674 |
|
1675 proxyServerNameField->LoadL(*cmdbSession); |
|
1676 |
|
1677 if (2 == proxyServerNameField->RecordId() && |
|
1678 KCDNotNullFlag == (proxyServerNameField->ElementId() & KCDNotNullFlag)) |
|
1679 { |
|
1680 SetTestStepResult(EPass); |
|
1681 } |
|
1682 |
|
1683 CleanupStack::PopAndDestroy(proxyServerNameField); |
|
1684 CleanupStack::PopAndDestroy(cmdbSession); |
|
1685 return TestStepResult(); |
|
1686 } |
|
1687 |
|
1688 //---------------------------------------------------------------------------------------------------------------- |
|
1689 |
|
1690 CCommsdat35Step::~CCommsdat35Step() |
|
1691 /** |
|
1692 * Destructor |
|
1693 */ |
|
1694 { |
|
1695 } |
|
1696 |
|
1697 CCommsdat35Step::CCommsdat35Step() |
|
1698 /** |
|
1699 * Constructor |
|
1700 */ |
|
1701 { |
|
1702 SetTestStepName(KCommsdat35Step); |
|
1703 } |
|
1704 |
|
1705 /* This test step is for testing the template records. A proxies record is |
|
1706 * loaded from the database and some of the fields are filled up from the template |
|
1707 * record. The point is that the fields from the template record mustn't have the |
|
1708 * hidden attribute and has to have the correct record number when loading into the |
|
1709 * record |
|
1710 */ |
|
1711 TVerdict CCommsdat35Step::doTestStepL() |
|
1712 { |
|
1713 SetTestStepResult(EFail); |
|
1714 |
|
1715 INFO_PRINTF1(_L("CCommsdat35Step::doTestStepL()")); |
|
1716 |
|
1717 #ifdef SYMBIAN_NON_SEAMLESS_NETWORK_BEARER_MOBILITY |
|
1718 CMDBSession *cmdbSession = CMDBSession::NewL(KCDVersion1_2); |
|
1719 #else |
|
1720 CMDBSession *cmdbSession = CMDBSession::NewL(KCDVersion1_1); |
|
1721 #endif |
|
1722 CleanupStack::PushL(cmdbSession); |
|
1723 |
|
1724 INFO_PRINTF1(_L("Loading the ProxiesRecord...")); |
|
1725 CCDProxiesRecord *proxiRecord = static_cast<CCDProxiesRecord*>(CCDRecordBase::RecordFactoryL(KCDTIdProxiesRecord)); |
|
1726 CleanupStack::PushL(proxiRecord); |
|
1727 |
|
1728 proxiRecord->SetRecordId(2); |
|
1729 proxiRecord->LoadL(*cmdbSession); |
|
1730 |
|
1731 //---- just to check whether the correct record is read... |
|
1732 { |
|
1733 CMDBField<TDesC>& proxyServerNameField = proxiRecord->iServerName; |
|
1734 CMDBField<TDesC>& recordNameField = proxiRecord->iRecordName; |
|
1735 TPtrC serverName(proxyServerNameField); |
|
1736 TPtrC recordName(recordNameField); |
|
1737 _LIT(KExpectedServerName, "Dummy Server Name"); |
|
1738 _LIT(KExpectedRecordName, "DefaultRecordName-2"); |
|
1739 |
|
1740 TESTL((serverName == KExpectedServerName) && (recordName == KExpectedRecordName)); |
|
1741 } |
|
1742 //-------------------------------------------------------- |
|
1743 |
|
1744 _LIT(KModifiedName, "janos_modified"); |
|
1745 CMDBField<TDesC>& nameField = proxiRecord->iRecordName; |
|
1746 TPtrC name(nameField); |
|
1747 nameField.SetMaxLengthL(KModifiedName().Length()); |
|
1748 nameField.SetL(KModifiedName); |
|
1749 |
|
1750 /* At this point the 'proxiRecord' still has the 'ProxyServerName' field |
|
1751 * which comes form the template record. As the field is not modified it |
|
1752 * shouldn't be stored into the record. This will be checked after the |
|
1753 * ModifiyL call. |
|
1754 */ |
|
1755 |
|
1756 INFO_PRINTF1(_L("Modifying the ProxiesRecord...")); |
|
1757 proxiRecord->ModifyL(*cmdbSession); |
|
1758 |
|
1759 CleanupStack::PopAndDestroy(proxiRecord); |
|
1760 |
|
1761 proxiRecord = static_cast<CCDProxiesRecord*>(CCDRecordBase::RecordFactoryL(KCDTIdProxiesRecord)); |
|
1762 CleanupStack::PushL(proxiRecord); |
|
1763 |
|
1764 proxiRecord->SetRecordId(2); |
|
1765 proxiRecord->LoadL(*cmdbSession); |
|
1766 |
|
1767 if (2 == proxiRecord->iServerName.RecordId() && |
|
1768 KCDNotNullFlag == (proxiRecord->iServerName.ElementId() & KCDNotNullFlag)) |
|
1769 { |
|
1770 SetTestStepResult(EPass); |
|
1771 } |
|
1772 |
|
1773 CleanupStack::PopAndDestroy(proxiRecord); |
|
1774 CleanupStack::PopAndDestroy(cmdbSession); |
|
1775 return TestStepResult(); |
|
1776 } |