|
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". |
|
7 // |
|
8 // Initial Contributors: |
|
9 // Nokia Corporation - initial contribution. |
|
10 // |
|
11 // Contributors: |
|
12 // |
|
13 // Description: |
|
14 // Tests added for new functionality in 9.4 |
|
15 // |
|
16 // |
|
17 |
|
18 /** |
|
19 @file |
|
20 */ |
|
21 |
|
22 #include "Te_EtelSatTestStepBase.h" |
|
23 #include "TE_EtelSatpcmds1f.h" |
|
24 #include <utf.h> |
|
25 |
|
26 CTestSatPCmds1f::CTestSatPCmds1f() |
|
27 /** Each test step initialises it's own name |
|
28 */ |
|
29 { |
|
30 // store the name of this test case |
|
31 // this is the name that is used by the script file |
|
32 SetTestStepName(_L("TestSatPCmds1f")); |
|
33 } |
|
34 |
|
35 enum TVerdict CTestSatPCmds1f::doTestStepL() |
|
36 { |
|
37 |
|
38 INFO_PRINTF1(_L("***********************************************")); |
|
39 INFO_PRINTF1(_L("RSat Proactive Commands Functionality suite")); |
|
40 INFO_PRINTF1(_L("***********************************************")); |
|
41 |
|
42 TInt ret=phone.Open(iTelServer,DSATTSY_PHONE_NAME); |
|
43 TEST(ret==KErrNone); |
|
44 |
|
45 ret=sat.Open(phone); |
|
46 TEST(ret==KErrNone); |
|
47 |
|
48 /** |
|
49 Testing Release 6 Features of Universal Subscriber Identity Module(USIM) |
|
50 Application ToolKit |
|
51 |
|
52 Release6Test1() function call is made to test the newly added Retrieve(\Submit\Display) Multimedia |
|
53 proactive commands. |
|
54 |
|
55 @test TSAT289 |
|
56 @test TSAT290 |
|
57 @test TSAT291 |
|
58 @test TSAT292 |
|
59 @test TSAT293 |
|
60 @test TSAT294 |
|
61 @test TSAT340 |
|
62 @test TSAT341 |
|
63 @test TSAT342 |
|
64 */ |
|
65 |
|
66 Release6Test1L(); |
|
67 |
|
68 /** |
|
69 Release6Test2() function call is made to test the newly added proactive commands |
|
70 SetFrames and GetFrameStatus. |
|
71 |
|
72 @test TSAT295 |
|
73 @test TSAT296 |
|
74 @test TSAT297 |
|
75 @test TSAT298 |
|
76 @test TSAT343 |
|
77 @test TSAT344 |
|
78 */ |
|
79 |
|
80 Release6Test2L(); |
|
81 |
|
82 /** |
|
83 Release6Test3() function call is made to test the existing proactive commands with the new V6 class added. |
|
84 LocalInfo, GetMeSideSatProfile are the existing commands tested here. |
|
85 |
|
86 @test TSAT304 |
|
87 @test TSAT307 |
|
88 @test TSAT306 |
|
89 @test TSAT308 |
|
90 @test TSAT309 |
|
91 @test TSAT366 |
|
92 @test TSAT310 |
|
93 @test TSAT367 |
|
94 @test TSAT368 |
|
95 */ |
|
96 |
|
97 Release6Test3L(); |
|
98 |
|
99 /** |
|
100 Release6Test4() function call is made to test the existing proactive commands with the new V6 class added. |
|
101 Send Ussd, Play Tone , SetUpEventList, LaunchBrowser, DisplayText are the existing commands tested here. |
|
102 |
|
103 @test TSAT311 |
|
104 @test TSAT371 |
|
105 @test TSAT312 |
|
106 @test TSAT372 |
|
107 @test TSAT320 |
|
108 @test TSAT338 |
|
109 @test TSAT339 |
|
110 @test TSAT322 |
|
111 @test TSAT323 |
|
112 @test TSAT330 |
|
113 @test TSAT368 |
|
114 @test TSAT331 |
|
115 @test TSAT369 |
|
116 @test TSAT332 |
|
117 @test TSAT333 |
|
118 */ |
|
119 |
|
120 Release6Test4L(); |
|
121 |
|
122 /** |
|
123 Release6Test5() function call is made to test the existing proactive commands with the new V6 class added. |
|
124 GetInkey, GetInput, SelectItem, SendSm, SetUpCall, SetUpIdleModeText are the existing commands tested here. |
|
125 |
|
126 @test TSAT334 |
|
127 @test TSAT335 |
|
128 @test TSAT336 |
|
129 @test TSAT337 |
|
130 @test TSAT340 |
|
131 @test TSAT341 |
|
132 @test TSAT342 |
|
133 @test TSAT343 |
|
134 @test TSAT344 |
|
135 @test TSAT345 |
|
136 @test TSAT346 |
|
137 @test TSAT347 |
|
138 */ |
|
139 |
|
140 Release6Test5L(); |
|
141 |
|
142 /** |
|
143 Release6Test6() function call is made to test the existing proactive commands with the new V6 class added. |
|
144 RunAtCommand, SendDtmf, CloseChannel, ReceiveData are the existing commands tested here. |
|
145 |
|
146 @test TSAT348 |
|
147 @test TSAT349 |
|
148 @test TSAT350 |
|
149 @test TSAT351 |
|
150 @test TSAT352 |
|
151 @test TSAT353 |
|
152 @test TSAT354 |
|
153 @test TSAT355 |
|
154 */ |
|
155 |
|
156 Release6Test6L(); |
|
157 |
|
158 /** |
|
159 Release6Test7() function call is made to test the existing proactive commands with the new V6 class added. |
|
160 SendData, GetServiceSearch , GetServiceInfo, SendSs, Open Channel are the existing commands tested here. |
|
161 |
|
162 @test TSAT356 |
|
163 @test TSAT357 |
|
164 @test TSAT358 |
|
165 @test TSAT359 |
|
166 @test TSAT360 |
|
167 @test TSAT361 |
|
168 @test TSAT369 |
|
169 @test TSAT362 |
|
170 @test TSAT363 |
|
171 @test TSAT370 |
|
172 @test TSAT375 |
|
173 @test TSAT376 |
|
174 @test TSAT377 |
|
175 @test TSAT378 |
|
176 */ |
|
177 |
|
178 Release6Test7L(); |
|
179 |
|
180 sat.Close(); |
|
181 phone.Close(); |
|
182 return TestStepResult(); |
|
183 } |
|
184 |
|
185 void CTestSatPCmds1f::Release6Test1L() |
|
186 { |
|
187 /** |
|
188 Testing Retrieve Multimedia Message Proactive command which has been newly |
|
189 added as part of the Release 6 Features of USIM Application ToolKit |
|
190 @test TSAT289 |
|
191 */ |
|
192 RSat::TRetrieveMultimediaMessageV6* retrieveMM = new (ELeave) RSat::TRetrieveMultimediaMessageV6; |
|
193 CleanupStack::PushL(retrieveMM); |
|
194 |
|
195 RSat::TRetrieveMultimediaMessageV6Pckg* retrieveMMPckg = new (ELeave) RSat::TRetrieveMultimediaMessageV6Pckg(*retrieveMM); |
|
196 CleanupStack::PushL(retrieveMMPckg); |
|
197 |
|
198 sat.NotifyRetrieveMultimediaMsgPCmd(reqStatus, *retrieveMMPckg); |
|
199 User::WaitForRequest(reqStatus); |
|
200 TEST(reqStatus.Int()==KErrNone); |
|
201 TEST(retrieveMM->iDestination == DSATTSYV6_DEVICE_ID1); |
|
202 TEST(retrieveMM->iAlphaId.iAlphaId== DSATTSYV6_ALPHAID1); |
|
203 TEST(retrieveMM->iAlphaId.iStatus == DSATTSYV6_ALPHAID_STATUS2); |
|
204 TEST(retrieveMM->iIconId.iIdentifier == DSATTSYV6_ICON_ID1); |
|
205 TEST(retrieveMM->iIconId.iQualifier == DSATTSYV6_ICON_QUALIFIER3); |
|
206 TEST(retrieveMM->iMultimediaContentId == DSATTSYV6_MULTIMEDIA_CONTENT_ID1); |
|
207 TEST(retrieveMM->iMultimediaMessageRef == DSATTSYV6_MULTIMEDIA_MESSAGE_REF1); |
|
208 TEST(retrieveMM->iMultimediaMessageId == DSATTSYV6_MULTIMEDIA_MESSAGE_ID1); |
|
209 |
|
210 RSat::TTextAttribute textAttribute; |
|
211 textAttribute.iStatus = DSATTSY_TEXT_ATTRIBUTE_STATUS; |
|
212 const TUint8 textAttributeData[DSATTSY_TEXT_ATTRIBUTE_DATA_LENGTH] = DSATTSY_TEXT_ATTRIBUTE_DATA; |
|
213 textAttribute.iTextAttributeData.Append(textAttributeData, DSATTSY_TEXT_ATTRIBUTE_DATA_LENGTH); |
|
214 |
|
215 TEST(retrieveMM->iTextAttribute.iStatus == textAttribute.iStatus); |
|
216 TEST(retrieveMM->iTextAttribute.iTextAttributeData == textAttribute.iTextAttributeData); |
|
217 |
|
218 /** |
|
219 Testing Cancel API for the Retrieve Multimedia Message Proactive command |
|
220 @test TSAT290 |
|
221 */ |
|
222 |
|
223 //Cancel |
|
224 sat.NotifyRetrieveMultimediaMsgPCmd(reqStatus, *retrieveMMPckg); |
|
225 sat.CancelAsyncRequest(ESatNotifyRetrieveMultimediaMsgPCmd); |
|
226 User::WaitForRequest(reqStatus); |
|
227 TEST(reqStatus.Int()==KErrCancel); |
|
228 |
|
229 /** |
|
230 Testing Terminal Response for the Retrieve Multimedia Message Proactive command |
|
231 @test TSAT340 |
|
232 */ |
|
233 |
|
234 //Response |
|
235 RSat::TRetrieveMultimediaMessageRspV6* retrieveMMRsp = new (ELeave) RSat::TRetrieveMultimediaMessageRspV6; |
|
236 CleanupStack::PushL(retrieveMMRsp); |
|
237 |
|
238 RSat::TRetrieveMultimediaMessageRspV6Pckg* retrieveMMRspPckg = new (ELeave) RSat::TRetrieveMultimediaMessageRspV6Pckg(*retrieveMMRsp); |
|
239 CleanupStack::PushL(retrieveMMRspPckg); |
|
240 |
|
241 retrieveMMRsp->SetPCmdNumber(DSATTSY_RETRIEVE_MULTIMEDIA_MESSAGE); |
|
242 retrieveMMRsp->iGeneralResult=DSATTSY_PCMD_RESULT_SUCCESS; |
|
243 retrieveMMRsp->iInfoType=DSATTSY_PCMD_RSP_NO_INFO; |
|
244 |
|
245 sat.NotifyRetrieveMultimediaMsgPCmd(reqStatus, *retrieveMMPckg); |
|
246 User::WaitForRequest(reqStatus); |
|
247 TEST(reqStatus.Int()==KErrNone); |
|
248 |
|
249 sat.TerminalRsp(reqStatus,RSat::ERetrieveMultimediaMsg,*retrieveMMRspPckg); |
|
250 User::WaitForRequest(reqStatus); |
|
251 TEST(reqStatus.Int()==KErrNone); |
|
252 INFO_PRINTF2(_L("Test %d - RSat::TerminalRsp - Retrieve Multimedia Message - passed"),iTestCount++); |
|
253 |
|
254 CleanupStack::PopAndDestroy(4); |
|
255 |
|
256 /** |
|
257 Testing Submit Multimedia Message Proactive command which has been newly |
|
258 added as part of the Release 6 Features of USIM Application ToolKit |
|
259 @test TSAT291 |
|
260 */ |
|
261 RSat::TSubmitMultimediaMessageV6* submitMM = new (ELeave) RSat::TSubmitMultimediaMessageV6; |
|
262 CleanupStack::PushL(submitMM); |
|
263 |
|
264 RSat::TSubmitMultimediaMessageV6Pckg* submitMMPckg = new (ELeave) RSat::TSubmitMultimediaMessageV6Pckg(*submitMM); |
|
265 CleanupStack::PushL(submitMMPckg); |
|
266 |
|
267 sat.NotifySubmitMultimediaMsgPCmd(reqStatus, *submitMMPckg); |
|
268 |
|
269 User::WaitForRequest(reqStatus); |
|
270 TEST(reqStatus.Int()==KErrNone); |
|
271 TEST(submitMM->iDestination == DSATTSYV6_DEVICE_ID1); |
|
272 TEST(submitMM->iAlphaId.iAlphaId== DSATTSYV6_ALPHAID1); |
|
273 TEST(submitMM->iAlphaId.iStatus == DSATTSYV6_ALPHAID_STATUS2); |
|
274 TEST(submitMM->iIconId.iIdentifier == DSATTSYV6_ICON_ID1); |
|
275 TEST(submitMM->iIconId.iQualifier == DSATTSYV6_ICON_QUALIFIER3); |
|
276 TEST(submitMM->iMultimediaMessageId == DSATTSYV6_MULTIMEDIA_MESSAGE_ID1); |
|
277 TEST(submitMM->iTextAttribute.iStatus == textAttribute.iStatus); |
|
278 TEST(submitMM->iTextAttribute.iTextAttributeData == textAttribute.iTextAttributeData); |
|
279 TEST(submitMM->iSubmissionFile == DSATTSYV6_SUBMISSION_FILE1); |
|
280 |
|
281 /** |
|
282 Testing Cancel API for the Submit Multimedia Message Proactive command |
|
283 @test TSAT292 |
|
284 */ |
|
285 |
|
286 //Cancel |
|
287 sat.NotifySubmitMultimediaMsgPCmd(reqStatus, *submitMMPckg); |
|
288 sat.CancelAsyncRequest(ESatNotifySubmitMultimediaMsgPCmd); |
|
289 User::WaitForRequest(reqStatus); |
|
290 TEST(reqStatus.Int()==KErrCancel); |
|
291 |
|
292 /** |
|
293 Testing Terminal Response for the Submit Multimedia Message Proactive command |
|
294 @test TSAT341 |
|
295 */ |
|
296 |
|
297 //Response |
|
298 RSat::TSubmitMultimediaMessageRspV6* submitMMRsp = new (ELeave) RSat::TSubmitMultimediaMessageRspV6; |
|
299 CleanupStack::PushL(submitMMRsp); |
|
300 |
|
301 RSat::TSubmitMultimediaMessageRspV6Pckg* submitMMRspPckg = new (ELeave) RSat::TSubmitMultimediaMessageRspV6Pckg(*submitMMRsp); |
|
302 CleanupStack::PushL(submitMMRspPckg); |
|
303 |
|
304 submitMMRsp->SetPCmdNumber(DSATTSY_SUBMIT_MULTIMEDIA_MESSAGE); |
|
305 submitMMRsp->iGeneralResult=DSATTSY_PCMD_RESULT_SUCCESS; |
|
306 submitMMRsp->iInfoType=DSATTSY_PCMD_RSP_NO_INFO; |
|
307 |
|
308 sat.NotifySubmitMultimediaMsgPCmd(reqStatus, *submitMMPckg); |
|
309 User::WaitForRequest(reqStatus); |
|
310 TEST(reqStatus.Int()==KErrNone); |
|
311 |
|
312 sat.TerminalRsp(reqStatus,RSat::ESubmitMultimediaMsg,*submitMMRspPckg); |
|
313 User::WaitForRequest(reqStatus); |
|
314 TEST(reqStatus.Int()==KErrNone); |
|
315 INFO_PRINTF2(_L("Test %d - RSat::TerminalRsp - Submit Multimedia Message - passed"),iTestCount++); |
|
316 |
|
317 CleanupStack::PopAndDestroy(4); |
|
318 |
|
319 /** |
|
320 Testing Display Multimedia Message Proactive command which has been newly |
|
321 added as part of the Release 6 Features of USIM Application ToolKit |
|
322 @test TSAT293 |
|
323 */ |
|
324 RSat::TDisplayMultimediaMessageV6* displayMM = new (ELeave) RSat::TDisplayMultimediaMessageV6; |
|
325 CleanupStack::PushL(displayMM); |
|
326 |
|
327 RSat::TDisplayMultimediaMessageV6Pckg* displayMMPckg = new (ELeave) RSat::TDisplayMultimediaMessageV6Pckg(*displayMM); |
|
328 CleanupStack::PushL(displayMMPckg); |
|
329 |
|
330 sat.NotifyDisplayMultimediaMsgPCmd(reqStatus, *displayMMPckg); |
|
331 |
|
332 User::WaitForRequest(reqStatus); |
|
333 TEST(reqStatus.Int()==KErrNone); |
|
334 TEST(displayMM->iDestination == DSATTSYV6_DEVICE_ID3); |
|
335 TEST(displayMM->iDisplayPriority == DSATTSYV6_DISPLAY_PRIORITY1); |
|
336 TEST(displayMM->iSubmissionFile == DSATTSYV6_SUBMISSION_FILE1); |
|
337 TEST(displayMM->iMultimediaMessageId == DSATTSYV6_MULTIMEDIA_MESSAGE_ID1); |
|
338 TEST(displayMM->iImmediateRsp == DSATTSYV6_IMMEDIATE_RESPONSE1); |
|
339 |
|
340 /** |
|
341 Testing Cancel API for the Display Multimedia Message Proactive command |
|
342 @test TSAT294 |
|
343 */ |
|
344 |
|
345 //Cancel |
|
346 sat.NotifyDisplayMultimediaMsgPCmd(reqStatus, *displayMMPckg); |
|
347 sat.CancelAsyncRequest(ESatNotifyDisplayMultimediaMsgPCmd); |
|
348 User::WaitForRequest(reqStatus); |
|
349 TEST(reqStatus.Int()==KErrCancel); |
|
350 |
|
351 /** |
|
352 Testing Terminal Response for the Display Multimedia Message Proactive command |
|
353 @test TSAT342 |
|
354 */ |
|
355 |
|
356 //Response |
|
357 RSat::TDisplayMultimediaMessageRspV6* displayMMRsp = new (ELeave) RSat::TDisplayMultimediaMessageRspV6; |
|
358 CleanupStack::PushL(displayMMRsp); |
|
359 |
|
360 RSat::TDisplayMultimediaMessageRspV6Pckg* displayMMRspPckg = new (ELeave) RSat::TDisplayMultimediaMessageRspV6Pckg(*displayMMRsp); |
|
361 CleanupStack::PushL(displayMMRspPckg); |
|
362 |
|
363 displayMMRsp->SetPCmdNumber(DSATTSY_DISPLAY_MULTIMEDIA_MESSAGE); |
|
364 displayMMRsp->iGeneralResult=DSATTSY_PCMD_RESULT_SUCCESS; |
|
365 displayMMRsp->iInfoType=DSATTSY_PCMD_RSP_NO_INFO; |
|
366 |
|
367 sat.NotifyDisplayMultimediaMsgPCmd(reqStatus, *displayMMPckg); |
|
368 User::WaitForRequest(reqStatus); |
|
369 TEST(reqStatus.Int()==KErrNone); |
|
370 |
|
371 sat.TerminalRsp(reqStatus,RSat::EDisplayMultimediaMsg,*displayMMRspPckg); |
|
372 User::WaitForRequest(reqStatus); |
|
373 TEST(reqStatus.Int()==KErrNone); |
|
374 INFO_PRINTF2(_L("Test %d - RSat::TerminalRsp - Display Multimedia Message - passed"),iTestCount++); |
|
375 |
|
376 CleanupStack::PopAndDestroy(4); |
|
377 } |
|
378 |
|
379 void CTestSatPCmds1f::Release6Test2L() |
|
380 { |
|
381 /** |
|
382 Testing Set Frames Proactive command which has been newly |
|
383 added as part of the Release 6 Features of USIM Application ToolKit |
|
384 @test TSAT295 |
|
385 */ |
|
386 RSat::TSetFramesV6* setFrames = new (ELeave) RSat::TSetFramesV6; |
|
387 CleanupStack::PushL(setFrames); |
|
388 |
|
389 RSat::TSetFramesV6Pckg* setFramesPckg = new (ELeave) RSat::TSetFramesV6Pckg(*setFrames); |
|
390 CleanupStack::PushL(setFramesPckg); |
|
391 |
|
392 sat.NotifySetFramesPCmd(reqStatus, *setFramesPckg); |
|
393 |
|
394 User::WaitForRequest(reqStatus); |
|
395 TEST(reqStatus.Int()==KErrNone); |
|
396 TEST(setFrames->iDestination == DSATTSYV6_DEVICE_ID1); |
|
397 TEST(setFrames->iDefaultFrameId == DSATTSYV6_DEFAULT_FRAME_IDENTIFIER1); |
|
398 TEST(setFrames->iFrameId == DSATTSYV6_FRAME_IDENTIFIER1); |
|
399 TEST(setFrames->iFrameLayout.iFramesLayout == DSATTSYV6_FRAME_LAYOUT_FORMAT1); |
|
400 TEST(setFrames->iFrameLayout.iFrameLayoutBuf == DSATTSYV6_FRAME_LAYOUT1); |
|
401 |
|
402 /** |
|
403 Testing Cancel API for the Set Frames Proactive command |
|
404 @test TSAT296 |
|
405 */ |
|
406 |
|
407 //Cancel |
|
408 sat.NotifySetFramesPCmd(reqStatus, *setFramesPckg); |
|
409 sat.CancelAsyncRequest(ESatNotifySetFramesPCmd); |
|
410 User::WaitForRequest(reqStatus); |
|
411 TEST(reqStatus.Int()==KErrCancel); |
|
412 |
|
413 /** |
|
414 Testing Terminal Response for the Set Frames Proactive command |
|
415 @test TSAT343 |
|
416 */ |
|
417 |
|
418 //Response |
|
419 RSat::TSetFramesRspV6* setFramesRsp = new (ELeave) RSat::TSetFramesRspV6; |
|
420 CleanupStack::PushL(setFramesRsp); |
|
421 |
|
422 RSat::TSetFramesRspV6Pckg* setFramesRspPckg = new (ELeave) RSat::TSetFramesRspV6Pckg(*setFramesRsp); |
|
423 CleanupStack::PushL(setFramesRspPckg); |
|
424 |
|
425 setFramesRsp->SetPCmdNumber(DSATTSY_SET_FRAMES); |
|
426 setFramesRsp->iGeneralResult=DSATTSY_PCMD_RESULT_SUCCESS; |
|
427 setFramesRsp->iInfoType=DSATTSY_PCMD_RSP_NO_INFO; |
|
428 setFramesRsp->iFramesInformation.iFrameId=DSATTSY_FRAMES_INFORMATION_FRAMEID; |
|
429 setFramesRsp->iFramesInformation.iFrameList=DSATTSY_FRAMES_INFORMATION_FRAME_LIST; |
|
430 |
|
431 sat.NotifySetFramesPCmd(reqStatus, *setFramesPckg); |
|
432 User::WaitForRequest(reqStatus); |
|
433 TEST(reqStatus.Int()==KErrNone); |
|
434 |
|
435 sat.TerminalRsp(reqStatus,RSat::ESetFrames,*setFramesRspPckg); |
|
436 User::WaitForRequest(reqStatus); |
|
437 TEST(reqStatus.Int()==KErrNone); |
|
438 INFO_PRINTF2(_L("Test %d - RSat::TerminalRsp - Set Frames - passed"),iTestCount++); |
|
439 |
|
440 CleanupStack::PopAndDestroy(4); |
|
441 |
|
442 /** |
|
443 Testing Get Frames Status Proactive command which has been newly |
|
444 added as part of the Release 6 Features of USIM Application ToolKit |
|
445 @test TSAT297 |
|
446 */ |
|
447 RSat::TGetFramesStatusV6* getFramesStatus = new (ELeave) RSat::TGetFramesStatusV6; |
|
448 CleanupStack::PushL(getFramesStatus); |
|
449 |
|
450 RSat::TGetFramesStatusV6Pckg* getFramesStatusPckg = new (ELeave) RSat::TGetFramesStatusV6Pckg(*getFramesStatus); |
|
451 CleanupStack::PushL(getFramesStatusPckg); |
|
452 |
|
453 sat.NotifyGetFramesStatusPCmd(reqStatus, *getFramesStatusPckg); |
|
454 |
|
455 User::WaitForRequest(reqStatus); |
|
456 TEST(reqStatus.Int()==KErrNone); |
|
457 TEST(getFramesStatus->iDestination == DSATTSYV6_DEVICE_ID1); |
|
458 |
|
459 /** |
|
460 Testing Cancel API for the Get Frames Status Proactive command |
|
461 @test TSAT298 |
|
462 */ |
|
463 |
|
464 //Cancel |
|
465 sat.NotifyGetFramesStatusPCmd(reqStatus, *getFramesStatusPckg); |
|
466 sat.CancelAsyncRequest(ESatNotifyGetFramesStatusPCmd); |
|
467 User::WaitForRequest(reqStatus); |
|
468 TEST(reqStatus.Int()==KErrCancel); |
|
469 |
|
470 /** |
|
471 Testing Terminal Response for the Get Frames Status Proactive command |
|
472 @test TSAT344 |
|
473 */ |
|
474 |
|
475 //Response |
|
476 RSat::TGetFramesStatusRspV6* getFramesStatusRsp = new (ELeave) RSat::TGetFramesStatusRspV6; |
|
477 CleanupStack::PushL(getFramesStatusRsp); |
|
478 |
|
479 RSat::TGetFramesStatusRspV6Pckg* getFramesStatusRspPckg = new (ELeave) RSat::TGetFramesStatusRspV6Pckg(*getFramesStatusRsp); |
|
480 CleanupStack::PushL(getFramesStatusRspPckg); |
|
481 |
|
482 getFramesStatusRsp->SetPCmdNumber(DSATTSY_GET_FRAMES_STATUS); |
|
483 getFramesStatusRsp->iGeneralResult=DSATTSY_PCMD_RESULT_SUCCESS; |
|
484 getFramesStatusRsp->iInfoType=DSATTSY_PCMD_RSP_NO_INFO; |
|
485 getFramesStatusRsp->iFramesInformation.iFrameId=DSATTSY_FRAMES_INFORMATION_FRAMEID; |
|
486 getFramesStatusRsp->iFramesInformation.iFrameList=DSATTSY_FRAMES_INFORMATION_FRAME_LIST; |
|
487 |
|
488 sat.NotifyGetFramesStatusPCmd(reqStatus, *getFramesStatusPckg); |
|
489 User::WaitForRequest(reqStatus); |
|
490 TEST(reqStatus.Int()==KErrNone); |
|
491 |
|
492 sat.TerminalRsp(reqStatus,RSat::EGetFramesStatus,*getFramesStatusRspPckg); |
|
493 User::WaitForRequest(reqStatus); |
|
494 TEST(reqStatus.Int()==KErrNone); |
|
495 INFO_PRINTF2(_L("Test %d - RSat::TerminalRsp - Get Frames Status - passed"),iTestCount++); |
|
496 |
|
497 CleanupStack::PopAndDestroy(4); |
|
498 |
|
499 } |
|
500 |
|
501 void CTestSatPCmds1f::Release6Test3L() |
|
502 { |
|
503 /** |
|
504 Testing the LocalInfo proactive command which has been updated |
|
505 to support the Release 6 Features of USIM ToolKit |
|
506 @test TSAT304 |
|
507 @test TSAT307 |
|
508 */ |
|
509 RSat::TLocalInfoV6* localInfoV6 = new (ELeave) RSat::TLocalInfoV6; |
|
510 CleanupStack::PushL(localInfoV6); |
|
511 |
|
512 RSat::TLocalInfoV6Pckg* localInfoV6Pckg = new (ELeave) RSat::TLocalInfoV6Pckg(*localInfoV6); |
|
513 CleanupStack::PushL(localInfoV6Pckg); |
|
514 |
|
515 |
|
516 sat.NotifyLocalInfoPCmd(reqStatus, *localInfoV6Pckg); |
|
517 User::WaitForRequest(reqStatus); |
|
518 TEST(reqStatus.Int()==KErrNone); |
|
519 TEST(localInfoV6->iUtranMeasurementQualifier=DSATTSYV6_LOCAL_INFOV6); |
|
520 TEST(localInfoV6->iInfoType = RSat::KProvideLocalInfoSearchMode); |
|
521 TEST(localInfoV6->iDevideId = RSat::KKeypad); |
|
522 INFO_PRINTF2(_L("Test %d - NotifyLocalInfoPCmd -LocalInfo proactive command- passed"),iTestCount++); |
|
523 |
|
524 /** |
|
525 Testing Cancel API for the LocalInfo proactive command |
|
526 @test TSAT306 |
|
527 @test TSAT308 |
|
528 */ |
|
529 |
|
530 //Cancel |
|
531 sat.NotifyLocalInfoPCmd(reqStatus, *localInfoV6Pckg); |
|
532 sat.CancelAsyncRequest(ESatNotifyLocalInfoPCmd); |
|
533 User::WaitForRequest(reqStatus); |
|
534 TEST(reqStatus.Int()==KErrCancel); |
|
535 |
|
536 CleanupStack::PopAndDestroy(2); |
|
537 |
|
538 /** |
|
539 Testing the API GetMeSideSatProfile which has been updated |
|
540 to support the Release 6 Features of USIM ToolKit |
|
541 @test TSAT309 |
|
542 @test TSAT366 |
|
543 */ |
|
544 RSat::TSatProfileV6* profileV6 = new (ELeave) RSat::TSatProfileV6; |
|
545 CleanupStack::PushL(profileV6); |
|
546 |
|
547 RSat::TSatProfileV6Pckg* profileV6Pckg = new (ELeave) RSat::TSatProfileV6Pckg(*profileV6); |
|
548 CleanupStack::PushL(profileV6Pckg); |
|
549 |
|
550 sat.GetMeSideSatProfile(reqStatus, *profileV6Pckg); |
|
551 User::WaitForRequest(reqStatus); |
|
552 TEST(reqStatus.Int()==KErrNone); |
|
553 |
|
554 // Pre-version 5 parameters in SAT profile |
|
555 TEST(profileV6->iSatProfileByte1==0x01); |
|
556 TEST(profileV6->iSatProfileByte2==0x02); |
|
557 TEST(profileV6->iSatProfileByte3==0x03); |
|
558 TEST(profileV6->iSatProfileByte4==0x04); |
|
559 TEST(profileV6->iSatProfileByte5==0x05); |
|
560 TEST(profileV6->iSatProfileByte6==0x06); |
|
561 TEST(profileV6->iSatProfileByte7==0x07); |
|
562 TEST(profileV6->iSatProfileByte8==0x08); |
|
563 TEST(profileV6->iSatProfileByte9==0x09); |
|
564 TEST(profileV6->iSatProfileByte10==0x0A); |
|
565 TEST(profileV6->iSatProfileByte11==0x0B); |
|
566 TEST(profileV6->iSatProfileByte12==0x0C); |
|
567 TEST(profileV6->iSatProfileByte13==0x0D); |
|
568 TEST(profileV6->iSatProfileByte14==0x0E); |
|
569 TEST(profileV6->iSatProfileByte15==0x0F); |
|
570 TEST(profileV6->iSatProfileByte16==0x10); |
|
571 TEST(profileV6->iSatProfileByte17==0x20); |
|
572 TEST(profileV6->iSatProfileByte18==0x30); |
|
573 TEST(profileV6->iNumOfChannels==DSATTSY_NUMBER_OF_CHANNELS); |
|
574 TEST(profileV6->iScreenHeight==DSATTSY_SCREEN_HEIGHT); |
|
575 TEST(profileV6->iScreenWidth==DSATTSY_SCREEN_WIDTH); |
|
576 TEST(profileV6->iTiaEiaProtoVersion==DSATTSY_PROTO_VERSION); |
|
577 TEST(profileV6->iWidthReduction==DSATTSY_WIDTH_REDUCTION); |
|
578 // Version 5 parameters in profile |
|
579 // (test also that the TSatProfileByte28 and TSatProfileByte29 |
|
580 // have been defined correctly as each should set a different bit). |
|
581 TEST(profileV6->iSatProfileByte28== |
|
582 (RSat::KCapsTextAttributeAlignmentLeft | RSat::KCapsTextAttributeAlignmentCentre | |
|
583 RSat::KCapsTextAttributeAlignmentRight | RSat::KCapsTextAttributeFontSizeNormal | |
|
584 RSat::KCapsTextAttributeFontSizeLarge | RSat::KCapsTextAttributeFontSizeSmall)); // 0x3F |
|
585 TEST(profileV6->iSatProfileByte29==(RSat::KCapsTextAttributeStyleNormal | |
|
586 RSat::KCapsTextAttributeStyleBold | |
|
587 RSat::KCapsTextAttributeStyleItalic | |
|
588 RSat::KCapsTextAttributeStyleUnderline | |
|
589 RSat::KCapsTextAttributeStyleStrikethrough | |
|
590 RSat::KCapsTextAttributeStyleForeground | |
|
591 RSat::KCapsTextAttributeStyleBackground)); // 0x7F |
|
592 TEST(profileV6->iSatProfileByte21== |
|
593 (RSat::KCapsWML | RSat::KCapsXHTML | |
|
594 RSat::KCapsHTML | RSat::KCapsCHTML)); // 0x0F |
|
595 TEST(profileV6->iSatProfileByte22==(RSat::KCapsProvideLocalInfoUTRAN | RSat::KCapsProvideLocalInfoBatteryState | |
|
596 RSat::KCapsPlayThemedAndMelodyTone | RSat::KCapsSetUpCallMultimediaCall | |
|
597 RSat::KCapsRefreshGBA | RSat::KCapsRetrieveMultimediaMessage | |
|
598 RSat::KCapsSubmitMultimediaMessage | RSat::KCapsDisplayMultimediaMesage)); // 0xFF |
|
599 TEST(profileV6->iSatProfileByte23== |
|
600 (RSat::KCapsSetFrames | RSat::KCapsGetFramesStatus | |
|
601 RSat::KCapsMmsNotificationDownload | RSat::KCapsProvideLocalInfoMEID | |
|
602 RSat::KCapsProvideLocalInfoNmrUTRAN | RSat::KCapsUssdDataDownload)); //0xE7 |
|
603 TEST(profileV6->iSatProfileByte24==(RSat::KCapsMaxNumFramesBit1 | RSat::KCapsMaxNumFramesBit2 | |
|
604 RSat::KCapsMaxNumFramesBit3 | RSat::KCapsMaxNumFramesBit4)); // 0x0F |
|
605 TEST(profileV6->iSatProfileByte25==(RSat::KCapsBrowsingStatusEvent | RSat::KCapsMmsTransferStatusEvent | |
|
606 RSat::KCapsFrameParametersChangeEvent)); // 0x07 |
|
607 INFO_PRINTF2(_L("Test %d - RSat::GetMeSideSatProfile with RSat::TSatProfileV6 passed"),iTestCount++); |
|
608 |
|
609 /** |
|
610 Testing Cancel API for the GetMeSideProfile command |
|
611 @test TSAT310 |
|
612 @test TSAT367 |
|
613 */ |
|
614 |
|
615 //Cancel |
|
616 sat.GetMeSideSatProfile(reqStatus, *profileV6Pckg); |
|
617 sat.CancelAsyncRequest(ESatGetMeSideSatProfile); |
|
618 User::WaitForRequest(reqStatus); |
|
619 TEST(reqStatus.Int()==KErrCancel); |
|
620 |
|
621 /** |
|
622 Testing the API GetMeSideSatProfile which has been updated |
|
623 to support the Release 6 Features of USIM ToolKit |
|
624 @test TSAT368 |
|
625 */ |
|
626 |
|
627 TEST(sat.ClientSatProfileIndication(*profileV6Pckg)==KErrNone); |
|
628 INFO_PRINTF2(_L("Test %d - RSat::ClientSatProfileIndication RSat::TSatProfileV6 passed"),iTestCount++); |
|
629 CleanupStack::PopAndDestroy(2); |
|
630 |
|
631 } |
|
632 |
|
633 void CTestSatPCmds1f::Release6Test4L() |
|
634 { |
|
635 /** |
|
636 Testing Send Ussd Proactive command which has been updated |
|
637 as part of the Release 6 Features of USIM Application ToolKit |
|
638 @test TSAT311 |
|
639 @test TSAT371 |
|
640 */ |
|
641 RSat::TSendUssdV6* sendUssd = new (ELeave) RSat::TSendUssdV6; |
|
642 CleanupStack::PushL(sendUssd); |
|
643 |
|
644 RSat::TSendUssdV6Pckg* sendUssdPckg = new (ELeave) RSat::TSendUssdV6Pckg(*sendUssd); |
|
645 CleanupStack::PushL(sendUssdPckg); |
|
646 |
|
647 sat.NotifySendUssdPCmd(reqStatus, *sendUssdPckg); |
|
648 User::WaitForRequest(reqStatus); |
|
649 TEST(reqStatus.Int()==KErrNone); |
|
650 TEST(sendUssd->iAlphaId.iAlphaId == DSATTSY_ALPHA_ID1); |
|
651 TEST(sendUssd->iAlphaId.iStatus == DSATTSY_ALPHA_ID1_STATUS); |
|
652 TEST(sendUssd->iUssdString.iDcs == DSATTSY_DCS); |
|
653 TEST(sendUssd->iUssdString.iUssdString == DSATTSY_USSD_STRING); |
|
654 TEST(sendUssd->iIconId.iIdentifier == DSATTSY_ICON_ID1); |
|
655 TEST(sendUssd->iIconId.iQualifier == DSATTSY_ICON_QUALIFIER1); |
|
656 |
|
657 RSat::TTextAttribute textAttribute; |
|
658 textAttribute.iStatus = DSATTSY_TEXT_ATTRIBUTE_STATUS; |
|
659 const TUint8 textAttributeData[DSATTSY_TEXT_ATTRIBUTE_DATA_LENGTH] = DSATTSY_TEXT_ATTRIBUTE_DATA; |
|
660 textAttribute.iTextAttributeData.Append(textAttributeData, DSATTSY_TEXT_ATTRIBUTE_DATA_LENGTH); |
|
661 |
|
662 TEST(sendUssd->iTextAttribute.iStatus == textAttribute.iStatus); |
|
663 TEST(sendUssd->iTextAttribute.iTextAttributeData == textAttribute.iTextAttributeData); |
|
664 |
|
665 INFO_PRINTF2(_L("Test %d - UssdDataDownload - Ussd Data Download command- passed"),iTestCount++); |
|
666 |
|
667 /** |
|
668 Testing Cancel API for the Send Ussd Proactive command |
|
669 @test TSAT312 |
|
670 @test TSAT372 |
|
671 */ |
|
672 |
|
673 //Cancel |
|
674 sat.NotifySendUssdPCmd(reqStatus, *sendUssdPckg); |
|
675 sat.CancelAsyncRequest(ESatNotifySendUssdPCmd); |
|
676 User::WaitForRequest(reqStatus); |
|
677 TEST(reqStatus.Int()==KErrCancel); |
|
678 |
|
679 CleanupStack::PopAndDestroy(2); |
|
680 |
|
681 /** |
|
682 Testing Play Tone Proactive command which has been updated |
|
683 as part of the Release 6 Features of USIM Application ToolKit |
|
684 @test TSAT320 |
|
685 @test TSAT338 |
|
686 */ |
|
687 RSat::TPlayToneV6* playTone = new (ELeave) RSat::TPlayToneV6; |
|
688 CleanupStack::PushL(playTone); |
|
689 |
|
690 RSat::TPlayToneV6Pckg* playTonePckg = new (ELeave) RSat::TPlayToneV6Pckg(*playTone); |
|
691 CleanupStack::PushL(playTonePckg); |
|
692 |
|
693 sat.NotifyPlayTonePCmd(reqStatus, *playTonePckg); |
|
694 User::WaitForRequest(reqStatus); |
|
695 TEST(reqStatus.Int()==KErrNone); |
|
696 TEST(playTone->iAlphaId.iAlphaId == DSATTSY_ALPHA_ID1); |
|
697 TEST(playTone->iAlphaId.iStatus == DSATTSY_ALPHA_ID1_STATUS); |
|
698 TEST(playTone->iTone == DSATTSY_TONEV6); |
|
699 TEST(playTone->iDuration.iTimeUnit == DSATTSY_TIME_UNIT); |
|
700 TEST(playTone->iDuration.iNumOfUnits ==DSATTSY_NUM_OF_UNITS); |
|
701 TEST(playTone->iIconId.iIdentifier == DSATTSY_ICON_ID1); |
|
702 TEST(playTone->iIconId.iQualifier == DSATTSY_ICON_QUALIFIER1); |
|
703 TEST(playTone->iTextAttribute.iStatus == textAttribute.iStatus); |
|
704 TEST(playTone->iTextAttribute.iTextAttributeData == textAttribute.iTextAttributeData); |
|
705 TEST(playTone->iFrameId==DSATTSYV6_DEFAULT_FRAME_IDENTIFIER1); |
|
706 |
|
707 INFO_PRINTF2(_L("Test %d - NotifyPlayTone - Play Tone command- passed"),iTestCount++); |
|
708 |
|
709 /** |
|
710 Testing Cancel API for the Play Tone command |
|
711 @test TSAT321 |
|
712 @test TSAT339 |
|
713 */ |
|
714 |
|
715 //Cancel |
|
716 sat.NotifyPlayTonePCmd(reqStatus, *playTonePckg); |
|
717 sat.CancelAsyncRequest(ESatNotifyPlayTonePCmd); |
|
718 User::WaitForRequest(reqStatus); |
|
719 TEST(reqStatus.Int()==KErrCancel); |
|
720 |
|
721 CleanupStack::PopAndDestroy(2); |
|
722 |
|
723 /** |
|
724 Testing SetUpEventList Proactive command which has been updated |
|
725 as part of the Release 6 Features of USIM Application ToolKit |
|
726 @test TSAT322 |
|
727 */ |
|
728 RSat::TSetUpEventListV1* setUpEventList = new (ELeave) RSat::TSetUpEventListV1; |
|
729 CleanupStack::PushL(setUpEventList); |
|
730 |
|
731 RSat::TSetUpEventListV1Pckg* setUpEventListPckg = new (ELeave) RSat::TSetUpEventListV1Pckg(*setUpEventList); |
|
732 CleanupStack::PushL(setUpEventListPckg); |
|
733 |
|
734 sat.NotifySetUpEventListPCmd(reqStatus, *setUpEventListPckg); |
|
735 User::WaitForRequest(reqStatus); |
|
736 TEST(reqStatus.Int()==KErrNone); |
|
737 |
|
738 INFO_PRINTF2(_L("Test %d - SetUpEventList - SetUp EventList command- passed"),iTestCount++); |
|
739 |
|
740 /** |
|
741 Testing Cancel API for the SetUpEventList Proactive command |
|
742 @test TSAT323 |
|
743 */ |
|
744 |
|
745 //Cancel |
|
746 sat.NotifySetUpEventListPCmd(reqStatus, *setUpEventListPckg); |
|
747 sat.CancelAsyncRequest(ESatNotifySetUpEventListPCmd); |
|
748 User::WaitForRequest(reqStatus); |
|
749 TEST(reqStatus.Int()==KErrCancel); |
|
750 |
|
751 CleanupStack::PopAndDestroy(2); |
|
752 |
|
753 /** |
|
754 Testing LaunchBrowser Proactive command which has been updated |
|
755 as part of the Release 6 Features of USIM Application ToolKit |
|
756 @test TSAT330 |
|
757 @test TSAT368 |
|
758 */ |
|
759 RSat::TLaunchBrowserV6* launchBrowser = new (ELeave) RSat::TLaunchBrowserV6; |
|
760 CleanupStack::PushL(launchBrowser); |
|
761 |
|
762 RSat::TLaunchBrowserV6Pckg* launchBrowserPckg = new (ELeave) RSat::TLaunchBrowserV6Pckg(*launchBrowser); |
|
763 CleanupStack::PushL(launchBrowserPckg); |
|
764 |
|
765 sat.NotifyLaunchBrowserPCmd(reqStatus, *launchBrowserPckg); |
|
766 User::WaitForRequest(reqStatus); |
|
767 TEST(reqStatus.Int()==KErrNone); |
|
768 TEST(launchBrowser->iBrowserSel == DSATTSY_BROWSER_SELECTION_MODE); |
|
769 TEST(launchBrowser->iBrowserId == DSATTSY_BROWSER_ID); |
|
770 TEST(launchBrowser->iUrl == DSATTSY_URL); |
|
771 TEST(launchBrowser->iBearerList == DSATTSY_BEARER_LIST); |
|
772 TEST(launchBrowser->iText == DSATTSY_PROXY_NAME); |
|
773 TEST(launchBrowser->iAlphaId.iStatus == DSATTSY_ALPHA_ID1_STATUS); |
|
774 TEST(launchBrowser->iAlphaId.iAlphaId == DSATTSY_ALPHA_ID1); |
|
775 TEST(launchBrowser->iIconId.iIdentifier == DSATTSY_ICON_ID1); |
|
776 TEST(launchBrowser->iIconId.iQualifier == DSATTSY_ICON_QUALIFIER1); |
|
777 TEST(launchBrowser->iTextAttribute.iStatus == textAttribute.iStatus); |
|
778 TEST(launchBrowser->iTextAttribute.iTextAttributeData == textAttribute.iTextAttributeData); |
|
779 TEST(launchBrowser->iFrameId==DSATTSYV6_DEFAULT_FRAME_IDENTIFIER1); |
|
780 |
|
781 INFO_PRINTF2(_L("Test %d - NotifyLaunchBrowserPCmd - Launch Browser command- passed"),iTestCount++); |
|
782 |
|
783 /** |
|
784 Testing Cancel API for the LauchBrowser Proactive command |
|
785 @test TSAT331 |
|
786 @test TSAT369 |
|
787 */ |
|
788 |
|
789 //Cancel |
|
790 sat.NotifyLaunchBrowserPCmd(reqStatus, *launchBrowserPckg); |
|
791 sat.CancelAsyncRequest(ESatNotifyLaunchBrowserPCmd); |
|
792 User::WaitForRequest(reqStatus); |
|
793 TEST(reqStatus.Int()==KErrCancel); |
|
794 |
|
795 CleanupStack::PopAndDestroy(2); |
|
796 |
|
797 /** |
|
798 Testing DisplayText Proactive command which has been updated |
|
799 as part of the Release 6 Features of USIM Application ToolKit |
|
800 @test TSAT332 |
|
801 */ |
|
802 RSat::TDisplayTextV6* displayText = new (ELeave) RSat::TDisplayTextV6; |
|
803 CleanupStack::PushL(displayText); |
|
804 |
|
805 RSat::TDisplayTextV6Pckg* displayTextPckg = new (ELeave) RSat::TDisplayTextV6Pckg(*displayText); |
|
806 CleanupStack::PushL(displayTextPckg); |
|
807 |
|
808 |
|
809 sat.NotifyDisplayTextPCmd(reqStatus, *displayTextPckg); |
|
810 User::WaitForRequest(reqStatus); |
|
811 TEST(reqStatus.Int()==KErrNone); |
|
812 TEST(displayText->iPriority ==DSATTSY_TEXT_PRIORITY); |
|
813 TEST(displayText->iClearScreenTrigger ==DSATTSY_CLEAR_SCREEN_TRIGGER); |
|
814 TEST(displayText->iText ==DSATTSY_TEXT_TO_DISPLAY); |
|
815 TEST(displayText->iIconId.iIdentifier ==DSATTSY_ICON_ID1); |
|
816 TEST(displayText->iIconId.iQualifier ==DSATTSY_ICON_QUALIFIER1); |
|
817 TEST(displayText->iImmediateRsp ==DSATTSY_IMMEDIATE_RSP); |
|
818 TEST(displayText->iDuration.iTimeUnit ==DSATTSY_TIME_UNIT); |
|
819 TEST(displayText->iDuration.iNumOfUnits ==DSATTSY_NUM_OF_UNITS); |
|
820 TEST(displayText->iTextAttribute.iStatus == textAttribute.iStatus); |
|
821 TEST(displayText->iTextAttribute.iTextAttributeData == textAttribute.iTextAttributeData); |
|
822 TEST(displayText->iFrameId==DSATTSYV6_DEFAULT_FRAME_IDENTIFIER1); |
|
823 |
|
824 INFO_PRINTF2(_L("Test %d - NotifyDisplayTextPCmd - DisplayText command- passed"),iTestCount++); |
|
825 |
|
826 /** |
|
827 Testing Cancel API for the DisplayText Proactive command |
|
828 @test TSAT333 |
|
829 */ |
|
830 |
|
831 //Cancel |
|
832 sat.NotifyDisplayTextPCmd(reqStatus, *displayTextPckg); |
|
833 sat.CancelAsyncRequest(ESatNotifyDisplayTextPCmd); |
|
834 User::WaitForRequest(reqStatus); |
|
835 TEST(reqStatus.Int()==KErrCancel); |
|
836 |
|
837 CleanupStack::PopAndDestroy(2); |
|
838 |
|
839 } |
|
840 |
|
841 void CTestSatPCmds1f::Release6Test5L() |
|
842 { |
|
843 /** |
|
844 Testing GetInkey Proactive command which has been updated |
|
845 as part of the Release 6 Features of USIM Application ToolKit |
|
846 @test TSAT334 |
|
847 */ |
|
848 RSat::TGetInkeyV6* getInkey = new (ELeave) RSat::TGetInkeyV6; |
|
849 CleanupStack::PushL(getInkey); |
|
850 |
|
851 RSat::TGetInkeyV6Pckg* getInkeyPckg = new (ELeave) RSat::TGetInkeyV6Pckg(*getInkey); |
|
852 CleanupStack::PushL(getInkeyPckg); |
|
853 |
|
854 sat.NotifyGetInkeyPCmd(reqStatus, *getInkeyPckg); |
|
855 User::WaitForRequest(reqStatus); |
|
856 TEST(reqStatus.Int()==KErrNone); |
|
857 TEST(getInkey->iRspFormat ==DSATTSY_USER_RSP_FORMAT); |
|
858 TEST(getInkey->iText ==DSATTSY_TEXT_TO_DISPLAY); |
|
859 TEST(getInkey->iIconId.iIdentifier ==DSATTSY_ICON_ID1); |
|
860 TEST(getInkey->iIconId.iQualifier ==DSATTSY_ICON_QUALIFIER1); |
|
861 TEST(getInkey->iHelp ==DSATTSY_HELP); |
|
862 TEST(getInkey->iDuration.iTimeUnit ==DSATTSY_TIME_UNIT); |
|
863 TEST(getInkey->iDuration.iNumOfUnits==DSATTSY_NUM_OF_UNITS); |
|
864 TEST(getInkey->iMode ==DSATTSY_GET_INKEY_RSP_MODE); |
|
865 |
|
866 RSat::TTextAttribute textAttribute; |
|
867 textAttribute.iStatus = DSATTSY_TEXT_ATTRIBUTE_STATUS; |
|
868 const TUint8 textAttributeData[DSATTSY_TEXT_ATTRIBUTE_DATA_LENGTH] = DSATTSY_TEXT_ATTRIBUTE_DATA; |
|
869 textAttribute.iTextAttributeData.Append(textAttributeData, DSATTSY_TEXT_ATTRIBUTE_DATA_LENGTH); |
|
870 |
|
871 TEST(getInkey->iTextAttribute.iStatus == textAttribute.iStatus); |
|
872 TEST(getInkey->iTextAttribute.iTextAttributeData == textAttribute.iTextAttributeData); |
|
873 TEST(getInkey->iFrameId==DSATTSYV6_DEFAULT_FRAME_IDENTIFIER1); |
|
874 |
|
875 INFO_PRINTF2(_L("Test %d - NotifyGetInkeyPCmd - GetInkey command- passed"),iTestCount++); |
|
876 |
|
877 /** |
|
878 Testing Cancel API for the GetInkey Proactive command |
|
879 @test TSAT335 |
|
880 */ |
|
881 |
|
882 //Cancel |
|
883 sat.NotifyGetInkeyPCmd(reqStatus, *getInkeyPckg); |
|
884 sat.CancelAsyncRequest(ESatNotifyGetInkeyPCmd); |
|
885 User::WaitForRequest(reqStatus); |
|
886 TEST(reqStatus.Int()==KErrCancel); |
|
887 |
|
888 CleanupStack::PopAndDestroy(2); |
|
889 |
|
890 /** |
|
891 Testing GetInput Proactive command which has been updated |
|
892 as part of the Release 6 Features of USIM Application ToolKit |
|
893 @test TSAT336 |
|
894 */ |
|
895 RSat::TGetInputV6* getInput = new (ELeave) RSat::TGetInputV6; |
|
896 CleanupStack::PushL(getInput); |
|
897 |
|
898 RSat::TGetInputV6Pckg* getInputPckg = new (ELeave) RSat::TGetInputV6Pckg(*getInput); |
|
899 CleanupStack::PushL(getInputPckg); |
|
900 |
|
901 sat.NotifyGetInputPCmd(reqStatus, *getInputPckg); |
|
902 User::WaitForRequest(reqStatus); |
|
903 TEST(reqStatus.Int()==KErrNone); |
|
904 TEST(getInput->iInputDisplayOption == DSATTSY_INPUT_DISPLAY_OPTION); |
|
905 TEST(getInput->iRspFormat == DSATTSY_GET_INPUT_RSP_FORMAT); |
|
906 TEST(getInput->iText == DSATTSY_TEXT_TO_DISPLAY); |
|
907 TEST(getInput->iRspLength.iMinRspLength == DSATTSY_MIN_RSP_LENGTH); |
|
908 TEST(getInput->iRspLength.iMaxRspLength == DSATTSY_MAX_RSP_LENGTH); |
|
909 TEST(getInput->iDefaultText == DSATTSY_DEFAULT_TEXT); |
|
910 TEST(getInput->iIconId.iIdentifier == DSATTSY_ICON_ID1); |
|
911 TEST(getInput->iIconId.iQualifier == DSATTSY_ICON_QUALIFIER1); |
|
912 TEST(getInput->iHelp == DSATTSY_HELP); |
|
913 TEST(getInput->iTextAttribute.iStatus == textAttribute.iStatus); |
|
914 TEST(getInput->iTextAttribute.iTextAttributeData == textAttribute.iTextAttributeData); |
|
915 TEST(getInput->iFrameId==DSATTSYV6_DEFAULT_FRAME_IDENTIFIER1); |
|
916 |
|
917 INFO_PRINTF2(_L("Test %d - NotifyGetInputPCmd - GetInput command- passed"),iTestCount++); |
|
918 |
|
919 /** |
|
920 Testing Cancel API for the DisplayText Proactive command |
|
921 @test TSAT337 |
|
922 */ |
|
923 |
|
924 //Cancel |
|
925 sat.NotifyGetInputPCmd(reqStatus, *getInputPckg); |
|
926 sat.CancelAsyncRequest(ESatNotifyGetInputPCmd); |
|
927 User::WaitForRequest(reqStatus); |
|
928 TEST(reqStatus.Int()==KErrCancel); |
|
929 |
|
930 CleanupStack::PopAndDestroy(2); |
|
931 |
|
932 /** |
|
933 Testing SelectItem Proactive command which has been updated |
|
934 as part of the Release 6 Features of USIM Application ToolKit |
|
935 @test TSAT340 |
|
936 */ |
|
937 RSat::TSelectItemV6* selectItem = new (ELeave) RSat::TSelectItemV6; |
|
938 CleanupStack::PushL(selectItem); |
|
939 |
|
940 RSat::TSelectItemV6Pckg* selectItemPckg = new (ELeave) RSat::TSelectItemV6Pckg(*selectItem); |
|
941 CleanupStack::PushL(selectItemPckg); |
|
942 |
|
943 sat.NotifySelectItemPCmd(reqStatus, *selectItemPckg); |
|
944 User::WaitForRequest(reqStatus); |
|
945 TEST(reqStatus.Int()==KErrNone); |
|
946 TEST(selectItem->iPresentationType ==DSATTSY_PRESENTATION_TYPE); |
|
947 TEST(selectItem->iHelp ==DSATTSY_HELP); |
|
948 TEST(selectItem->iAlphaId.iAlphaId ==DSATTSY_ALPHA_ID1); |
|
949 TEST(selectItem->iAlphaId.iStatus ==DSATTSY_ALPHA_ID1_STATUS); |
|
950 TEST(selectItem->iDefaultItemId ==DSATTSY_DEFAULT_ITEM); |
|
951 TEST(selectItem->iIconId.iIdentifier ==DSATTSY_ICON_ID1); |
|
952 TEST(selectItem->iIconId.iQualifier ==DSATTSY_ICON_QUALIFIER1); |
|
953 TEST(selectItem->iIconListQualifier ==DSATTSY_ICON_QUALIFIER2); |
|
954 TEST(selectItem->iPreference=DSATTSY_SELECTION_PREFERENCE); |
|
955 TEST(selectItem->iTextAttribute.iStatus == textAttribute.iStatus); |
|
956 TEST(selectItem->iTextAttribute.iTextAttributeData == textAttribute.iTextAttributeData); |
|
957 TEST(selectItem->iFrameId==DSATTSYV6_DEFAULT_FRAME_IDENTIFIER1); |
|
958 |
|
959 INFO_PRINTF2(_L("Test %d - SelectItemPCmd - SelectItem command- passed"),iTestCount++); |
|
960 |
|
961 /** |
|
962 Testing Cancel API for the SelectItem Proactive command |
|
963 @test TSAT341 |
|
964 */ |
|
965 |
|
966 //Cancel |
|
967 sat.NotifySelectItemPCmd(reqStatus, *selectItemPckg); |
|
968 sat.CancelAsyncRequest(ESatNotifySelectItemPCmd); |
|
969 User::WaitForRequest(reqStatus); |
|
970 TEST(reqStatus.Int()==KErrCancel); |
|
971 INFO_PRINTF2(_L("Test %d - SelectItemPCmd - SelectItem cancel command- passed"),iTestCount++); |
|
972 |
|
973 CleanupStack::PopAndDestroy(2); |
|
974 |
|
975 /** |
|
976 Testing SendSm Proactive command which has been updated |
|
977 as part of the Release 6 Features of USIM Application ToolKit |
|
978 @test TSAT342 |
|
979 */ |
|
980 RSat::TSendSmV6* sendSm = new (ELeave) RSat::TSendSmV6; |
|
981 CleanupStack::PushL(sendSm); |
|
982 |
|
983 RSat::TSendSmV6Pckg* sendSmPckg = new (ELeave) RSat::TSendSmV6Pckg(*sendSm); |
|
984 CleanupStack::PushL(sendSmPckg); |
|
985 |
|
986 sat.NotifySendSmPCmd(reqStatus, *sendSmPckg); |
|
987 User::WaitForRequest(reqStatus); |
|
988 TEST(reqStatus.Int()==KErrNone); |
|
989 TEST(sendSm->iAlphaId.iAlphaId ==DSATTSY_ALPHA_ID1); |
|
990 TEST(sendSm->iAlphaId.iStatus ==DSATTSY_ALPHA_ID1_STATUS); |
|
991 TEST(sendSm->iAddress.iTypeOfNumber ==DSATTSY_TON); |
|
992 TEST(sendSm->iAddress.iNumberPlan ==DSATTSY_NPI); |
|
993 TEST(sendSm->iAddress.iTelNumber ==DSATTSY_TEL_NUMBER); |
|
994 TEST(sendSm->iSmsTpdu ==DSATTSY_SMS_TPDU); |
|
995 TEST(sendSm->iIconId.iIdentifier ==DSATTSY_ICON_ID1); |
|
996 TEST(sendSm->iIconId.iQualifier ==DSATTSY_ICON_QUALIFIER1); |
|
997 TEST(sendSm->iTextAttribute.iStatus == textAttribute.iStatus); |
|
998 TEST(sendSm->iTextAttribute.iTextAttributeData == textAttribute.iTextAttributeData); |
|
999 TEST(sendSm->iFrameId==DSATTSYV6_DEFAULT_FRAME_IDENTIFIER1); |
|
1000 |
|
1001 INFO_PRINTF2(_L("Test %d - SendSmPCmd - SendSm command- passed"),iTestCount++); |
|
1002 |
|
1003 /** |
|
1004 Testing Cancel API for the SendSm Proactive command |
|
1005 @test TSAT343 |
|
1006 */ |
|
1007 |
|
1008 //Cancel |
|
1009 sat.NotifySendSmPCmd(reqStatus, *sendSmPckg); |
|
1010 sat.CancelAsyncRequest(ESatNotifySendSmPCmd); |
|
1011 User::WaitForRequest(reqStatus); |
|
1012 TEST(reqStatus.Int()==KErrCancel); |
|
1013 |
|
1014 CleanupStack::PopAndDestroy(2); |
|
1015 |
|
1016 /** |
|
1017 Testing SetUpCall Proactive command which has been updated |
|
1018 as part of the Release 6 Features of USIM Application ToolKit |
|
1019 @test TSAT344 |
|
1020 */ |
|
1021 RSat::TSetUpCallV6* setUpCall = new (ELeave) RSat::TSetUpCallV6; |
|
1022 CleanupStack::PushL(setUpCall); |
|
1023 |
|
1024 RSat::TSetUpCallV6Pckg* setUpCallPckg = new (ELeave) RSat::TSetUpCallV6Pckg(*setUpCall); |
|
1025 CleanupStack::PushL(setUpCallPckg); |
|
1026 |
|
1027 sat.NotifySetUpCallPCmd(reqStatus, *setUpCallPckg); |
|
1028 User::WaitForRequest(reqStatus); |
|
1029 TEST(reqStatus.Int()==KErrNone); |
|
1030 TEST(setUpCall->iType ==DSATTSY_SET_UP_CALL_TYPE); |
|
1031 TEST(setUpCall->iAlphaIdConfirmationPhase.iAlphaId ==DSATTSY_ALPHA_ID1); |
|
1032 TEST(setUpCall->iAlphaIdConfirmationPhase.iStatus ==DSATTSY_ALPHA_ID1_STATUS); |
|
1033 TEST(setUpCall->iIconIdConfirmationPhase.iIdentifier==DSATTSY_ICON_ID1); |
|
1034 TEST(setUpCall->iIconIdConfirmationPhase.iQualifier ==DSATTSY_ICON_QUALIFIER1); |
|
1035 TEST(setUpCall->iAddress.iTypeOfNumber ==DSATTSY_TON); |
|
1036 TEST(setUpCall->iAddress.iNumberPlan ==DSATTSY_NPI); |
|
1037 TEST(setUpCall->iAddress.iTelNumber ==DSATTSY_TEL_NUMBER); |
|
1038 TEST(setUpCall->iCapabilityConfigParams ==DSATTSY_CCP1); |
|
1039 TEST(setUpCall->iSubAddress ==DSATTSY_SUBADDRESS); |
|
1040 TEST(setUpCall->iDuration.iTimeUnit ==DSATTSY_TIME_UNIT); |
|
1041 TEST(setUpCall->iDuration.iNumOfUnits ==DSATTSY_NUM_OF_UNITS); |
|
1042 TEST(setUpCall->iAlphaIdCallSetUpPhase.iAlphaId ==DSATTSY_ALPHA_ID2); |
|
1043 TEST(setUpCall->iAlphaIdCallSetUpPhase.iStatus ==DSATTSY_ALPHA_ID2_STATUS); |
|
1044 TEST(setUpCall->iIconIdCallSetUpPhase.iIdentifier ==DSATTSY_ICON_ID2); |
|
1045 TEST(setUpCall->iIconIdCallSetUpPhase.iQualifier ==DSATTSY_ICON_QUALIFIER2); |
|
1046 TEST(setUpCall->iFrameId==DSATTSYV6_DEFAULT_FRAME_IDENTIFIER1); |
|
1047 |
|
1048 INFO_PRINTF2(_L("Test %d - SetUpCall - SetUp Call command- passed"),iTestCount++); |
|
1049 |
|
1050 /** |
|
1051 Testing Cancel API for the SetUpCall Proactive command |
|
1052 @test TSAT345 |
|
1053 */ |
|
1054 |
|
1055 //Cancel |
|
1056 sat.NotifySetUpCallPCmd(reqStatus, *setUpCallPckg); |
|
1057 sat.CancelAsyncRequest(ESatNotifySetUpCallPCmd); |
|
1058 User::WaitForRequest(reqStatus); |
|
1059 TEST(reqStatus.Int()==KErrCancel); |
|
1060 |
|
1061 CleanupStack::PopAndDestroy(2); |
|
1062 |
|
1063 /** |
|
1064 Testing SetUpIdleModeText Proactive command which has been updated |
|
1065 as part of the Release 6 Features of USIM Application ToolKit |
|
1066 @test TSAT346 |
|
1067 @test TSAT347 |
|
1068 */ |
|
1069 RSat::TSetUpIdleModeTextV6* setUpIdleModeText = new (ELeave) RSat::TSetUpIdleModeTextV6; |
|
1070 CleanupStack::PushL(setUpIdleModeText); |
|
1071 |
|
1072 RSat::TSetUpIdleModeTextV6Pckg* setUpIdleModeTextPckg = new (ELeave) RSat::TSetUpIdleModeTextV6Pckg(*setUpIdleModeText); |
|
1073 CleanupStack::PushL(setUpIdleModeTextPckg); |
|
1074 |
|
1075 TEST(setUpIdleModeText->ExtensionId() == RSat::KSatV6); |
|
1076 TEST(setUpIdleModeText->iTextAttribute.iStatus == RSat::ETextAttributeNotSet); |
|
1077 |
|
1078 sat.NotifySetUpIdleModeTextPCmd(reqStatus,*setUpIdleModeTextPckg); |
|
1079 User::WaitForRequest(reqStatus); |
|
1080 TEST(reqStatus.Int()==KErrNone); |
|
1081 |
|
1082 TEST(setUpIdleModeText->PCmdNumber()==DSATTSY_SET_UP_IDLE_MODE_TEXT_NUMBER); |
|
1083 |
|
1084 TEST(setUpIdleModeText->iType==DSATTSY_IDLE_MODE_TXT_TYPE); |
|
1085 TEST(setUpIdleModeText->iText==DSATTSY_IDLE_MODE_TEXT); |
|
1086 TEST(setUpIdleModeText->iIconId.iIdentifier==DSATTSY_ICON_ID1); |
|
1087 TEST(setUpIdleModeText->iIconId.iQualifier==DSATTSY_ICON_QUALIFIER1); |
|
1088 TEST(setUpIdleModeText->iCodingScheme==DSATTSY_TEXT_ENCODING_SCHEME); |
|
1089 |
|
1090 TEST(setUpIdleModeText->iTextAttribute.iStatus == textAttribute.iStatus); |
|
1091 TEST(setUpIdleModeText->iTextAttribute.iTextAttributeData == textAttribute.iTextAttributeData); |
|
1092 |
|
1093 INFO_PRINTF2(_L("Test %d - RSat::NotifySetUpIdleModeText (Unicode) with RSat::TSetUpIdleModeTextV6 passed"),iTestCount++); |
|
1094 |
|
1095 // Set Up Idle Mode Text Cancel |
|
1096 sat.NotifySetUpIdleModeTextPCmd(reqStatus,*setUpIdleModeTextPckg); |
|
1097 sat.CancelAsyncRequest(ESatNotifySetUpIdleModeTextPCmd); |
|
1098 |
|
1099 User::WaitForRequest(reqStatus); |
|
1100 TEST(reqStatus.Int()==KErrCancel); |
|
1101 INFO_PRINTF2(_L("Test %d - RSat::NotifySetUpIdleModeTextPCmdCancel with RSat::TSetUpIdleModeTextV6 passed"),iTestCount++); |
|
1102 |
|
1103 // Issue another request. The DTSY will set the idle text mode to an 8-bit string |
|
1104 sat.NotifySetUpIdleModeTextPCmd(reqStatus,*setUpIdleModeTextPckg); |
|
1105 User::WaitForRequest(reqStatus); |
|
1106 TEST(reqStatus.Int()==KErrNone); |
|
1107 |
|
1108 TEST(setUpIdleModeText->PCmdNumber()==DSATTSY_SET_UP_IDLE_MODE_TEXT_NUMBER); |
|
1109 |
|
1110 TPtrC8 textIdleMode8(DSATTSY_IDLE_MODE_TEXT_8BIT); |
|
1111 TEST(setUpIdleModeText->iType==DSATTSY_IDLE_MODE_TXT_TYPE); |
|
1112 TBuf8<276> text8; |
|
1113 CnvUtfConverter::ConvertFromUnicodeToUtf8(text8,setUpIdleModeText->iText); |
|
1114 TEST(text8==DSATTSY_IDLE_MODE_TEXT_8BIT); |
|
1115 TEST(setUpIdleModeText->iIconId.iIdentifier==DSATTSY_ICON_ID1); |
|
1116 TEST(setUpIdleModeText->iIconId.iQualifier==DSATTSY_ICON_QUALIFIER1); |
|
1117 TEST(setUpIdleModeText->iCodingScheme==DSATTSY_TEXT_ENCODING_SCHEME_8); |
|
1118 |
|
1119 TEST(setUpIdleModeText->iTextAttribute.iStatus == textAttribute.iStatus); |
|
1120 TEST(setUpIdleModeText->iTextAttribute.iTextAttributeData == textAttribute.iTextAttributeData); |
|
1121 |
|
1122 INFO_PRINTF2(_L("Test %d - RSat::NotifySetUpIdleModeText (8-bit) with RSat::TSetUpIdleModeTextV6 passed"),iTestCount++); |
|
1123 |
|
1124 // Set Up Idle Mode Text Cancel |
|
1125 sat.NotifySetUpIdleModeTextPCmd(reqStatus,*setUpIdleModeTextPckg); |
|
1126 sat.CancelAsyncRequest(ESatNotifySetUpIdleModeTextPCmd); |
|
1127 |
|
1128 User::WaitForRequest(reqStatus); |
|
1129 TEST(reqStatus.Int()==KErrCancel); |
|
1130 INFO_PRINTF2(_L("Test %d - RSat::NotifySetUpIdleModeTextPCmdCancel with RSat::TSetUpIdleModeTextV6 passed"),iTestCount++); |
|
1131 |
|
1132 INFO_PRINTF2(_L("Test %d - SetUpCall - SetUp Call command- passed"),iTestCount++); |
|
1133 |
|
1134 CleanupStack::PopAndDestroy(2); |
|
1135 |
|
1136 } |
|
1137 |
|
1138 void CTestSatPCmds1f::Release6Test6L() |
|
1139 { |
|
1140 /** |
|
1141 Testing RunAtCommand Proactive command which has been updated |
|
1142 as part of the Release 6 Features of USIM Application ToolKit |
|
1143 @test TSAT348 |
|
1144 */ |
|
1145 RSat::TRunAtCommandV6* runAtCmd = new (ELeave) RSat::TRunAtCommandV6; |
|
1146 CleanupStack::PushL(runAtCmd); |
|
1147 |
|
1148 RSat::TRunAtCommandV6Pckg* runAtCmdPckg = new (ELeave) RSat::TRunAtCommandV6Pckg(*runAtCmd); |
|
1149 CleanupStack::PushL(runAtCmdPckg); |
|
1150 |
|
1151 sat.NotifyRunAtCommandPCmd(reqStatus, *runAtCmdPckg); |
|
1152 User::WaitForRequest(reqStatus); |
|
1153 TEST(reqStatus.Int()==KErrNone); |
|
1154 TEST(runAtCmd->iAlphaId.iStatus==DSATTSY_ALPHA_ID1_STATUS); |
|
1155 TEST(runAtCmd->iAlphaId.iAlphaId==DSATTSY_ALPHA_ID1); |
|
1156 TEST(runAtCmd->iAtCommand==DSATTSY_AT_COMMAND); |
|
1157 TEST(runAtCmd->iIconId.iIdentifier==DSATTSY_ICON_ID1); |
|
1158 TEST(runAtCmd->iIconId.iQualifier==DSATTSY_ICON_QUALIFIER1); |
|
1159 |
|
1160 RSat::TTextAttribute textAttribute; |
|
1161 textAttribute.iStatus = DSATTSY_TEXT_ATTRIBUTE_STATUS; |
|
1162 const TUint8 textAttributeData[DSATTSY_TEXT_ATTRIBUTE_DATA_LENGTH] = DSATTSY_TEXT_ATTRIBUTE_DATA; |
|
1163 textAttribute.iTextAttributeData.Append(textAttributeData, DSATTSY_TEXT_ATTRIBUTE_DATA_LENGTH); |
|
1164 |
|
1165 TEST(runAtCmd->iTextAttribute.iStatus == textAttribute.iStatus); |
|
1166 TEST(runAtCmd->iTextAttribute.iTextAttributeData == textAttribute.iTextAttributeData); |
|
1167 TEST(runAtCmd->iFrameId==DSATTSYV6_DEFAULT_FRAME_IDENTIFIER1); |
|
1168 |
|
1169 INFO_PRINTF2(_L("Test %d - RunAtCmd - TRunAtCommandV6- passed"),iTestCount++); |
|
1170 |
|
1171 /** |
|
1172 Testing Cancel API for the RunAtCommand Proactive command |
|
1173 @test TSAT349 |
|
1174 */ |
|
1175 |
|
1176 //Cancel |
|
1177 sat.NotifyRunAtCommandPCmd(reqStatus, *runAtCmdPckg); |
|
1178 sat.CancelAsyncRequest(ESatNotifyRunAtCommandPCmd); |
|
1179 User::WaitForRequest(reqStatus); |
|
1180 TEST(reqStatus.Int()==KErrCancel); |
|
1181 |
|
1182 CleanupStack::PopAndDestroy(2); |
|
1183 |
|
1184 /** |
|
1185 Testing SendDtmf Proactive command which has been updated |
|
1186 as part of the Release 6 Features of USIM Application ToolKit |
|
1187 @test TSAT350 |
|
1188 */ |
|
1189 RSat::TSendDtmfV6* sendDtmf = new (ELeave) RSat::TSendDtmfV6; |
|
1190 CleanupStack::PushL(sendDtmf); |
|
1191 |
|
1192 RSat::TSendDtmfV6Pckg* sendDtmfPckg = new (ELeave) RSat::TSendDtmfV6Pckg(*sendDtmf); |
|
1193 CleanupStack::PushL(sendDtmfPckg); |
|
1194 |
|
1195 sat.NotifySendDtmfPCmd(reqStatus, *sendDtmfPckg); |
|
1196 User::WaitForRequest(reqStatus); |
|
1197 TEST(reqStatus.Int()==KErrNone); |
|
1198 TEST(sendDtmf->iAlphaId.iAlphaId ==DSATTSY_ALPHA_ID1); |
|
1199 TEST(sendDtmf->iAlphaId.iStatus ==DSATTSY_ALPHA_ID1_STATUS); |
|
1200 TEST(sendDtmf->iDtmfString ==DSATTSY_DTMF_STRING); |
|
1201 TEST(sendDtmf->iIconId.iIdentifier ==DSATTSY_ICON_ID1); |
|
1202 TEST(sendDtmf->iIconId.iQualifier ==DSATTSY_ICON_QUALIFIER1); |
|
1203 TEST(sendDtmf->iTextAttribute.iStatus == textAttribute.iStatus); |
|
1204 TEST(sendDtmf->iTextAttribute.iTextAttributeData == textAttribute.iTextAttributeData); |
|
1205 TEST(sendDtmf->iFrameId==DSATTSYV6_DEFAULT_FRAME_IDENTIFIER1); |
|
1206 |
|
1207 INFO_PRINTF2(_L("Test %d - SendDtmf - TSendDtmfV6- passed"),iTestCount++); |
|
1208 |
|
1209 /** |
|
1210 Testing Cancel API for the SendDtmf Proactive command |
|
1211 @test TSAT351 |
|
1212 */ |
|
1213 |
|
1214 //Cancel |
|
1215 sat.NotifySendDtmfPCmd(reqStatus, *sendDtmfPckg); |
|
1216 sat.CancelAsyncRequest(ESatNotifySendDtmfPCmd); |
|
1217 User::WaitForRequest(reqStatus); |
|
1218 TEST(reqStatus.Int()==KErrCancel); |
|
1219 |
|
1220 CleanupStack::PopAndDestroy(2); |
|
1221 |
|
1222 /** |
|
1223 Testing CloseChannel Proactive command which has been updated |
|
1224 as part of the Release 6 Features of USIM Application ToolKit |
|
1225 @test TSAT352 |
|
1226 */ |
|
1227 RSat::TCloseChannelV6* closeChannel = new (ELeave) RSat::TCloseChannelV6; |
|
1228 CleanupStack::PushL(closeChannel); |
|
1229 |
|
1230 RSat::TCloseChannelV6Pckg* closeChannelPckg = new (ELeave) RSat::TCloseChannelV6Pckg(*closeChannel); |
|
1231 CleanupStack::PushL(closeChannelPckg); |
|
1232 |
|
1233 sat.NotifyCloseChannelPCmd(reqStatus, *closeChannelPckg); |
|
1234 User::WaitForRequest(reqStatus); |
|
1235 TEST(reqStatus.Int()==KErrNone); |
|
1236 TEST(closeChannel->iDestination==DSATTSY_CARD_READER_1); |
|
1237 TEST(closeChannel->iAlphaId.iStatus==DSATTSY_ALPHA_ID1_STATUS); |
|
1238 TEST(closeChannel->iAlphaId.iAlphaId==DSATTSY_ALPHA_ID1); |
|
1239 TEST(closeChannel->iIconId.iIdentifier==DSATTSY_ICON_ID1); |
|
1240 TEST(closeChannel->iIconId.iQualifier==DSATTSY_ICON_QUALIFIER1); |
|
1241 TEST(closeChannel->iTextAttribute.iStatus == textAttribute.iStatus); |
|
1242 TEST(closeChannel->iTextAttribute.iTextAttributeData == textAttribute.iTextAttributeData); |
|
1243 TEST(closeChannel->iFrameId==DSATTSYV6_DEFAULT_FRAME_IDENTIFIER1); |
|
1244 |
|
1245 INFO_PRINTF2(_L("Test %d - CloseChannel - TCloseChannelV6- passed"),iTestCount++); |
|
1246 |
|
1247 /** |
|
1248 Testing Cancel API for the CloseChannel Proactive command |
|
1249 @test TSAT353 |
|
1250 */ |
|
1251 |
|
1252 //Cancel |
|
1253 sat.NotifyCloseChannelPCmd(reqStatus, *closeChannelPckg); |
|
1254 sat.CancelAsyncRequest(ESatNotifyCloseChannelPCmd); |
|
1255 User::WaitForRequest(reqStatus); |
|
1256 TEST(reqStatus.Int()==KErrCancel); |
|
1257 |
|
1258 CleanupStack::PopAndDestroy(2); |
|
1259 |
|
1260 /** |
|
1261 Testing ReceiveData Proactive command which has been updated |
|
1262 as part of the Release 6 Features of USIM Application ToolKit |
|
1263 @test TSAT354 |
|
1264 */ |
|
1265 RSat::TReceiveDataV6* receiveData = new (ELeave) RSat::TReceiveDataV6; |
|
1266 CleanupStack::PushL(receiveData); |
|
1267 |
|
1268 RSat::TReceiveDataV6Pckg* receiveDataPckg = new (ELeave) RSat::TReceiveDataV6Pckg(*receiveData); |
|
1269 CleanupStack::PushL(receiveDataPckg); |
|
1270 |
|
1271 sat.NotifyReceiveDataPCmd(reqStatus, *receiveDataPckg); |
|
1272 User::WaitForRequest(reqStatus); |
|
1273 TEST(reqStatus.Int()==KErrNone); |
|
1274 TEST(receiveData->iDestination==DSATTSY_CARD_READER_1); |
|
1275 TEST(receiveData->iAlphaId.iStatus==DSATTSY_ALPHA_ID1_STATUS); |
|
1276 TEST(receiveData->iAlphaId.iAlphaId==DSATTSY_ALPHA_ID1); |
|
1277 TEST(receiveData->iIconId.iIdentifier==DSATTSY_ICON_ID1); |
|
1278 TEST(receiveData->iIconId.iQualifier==DSATTSY_ICON_QUALIFIER1); |
|
1279 TEST(receiveData->iChannelDataLength==DSATTSY_DATA_LENGTH); |
|
1280 TEST(receiveData->iTextAttribute.iStatus == textAttribute.iStatus); |
|
1281 TEST(receiveData->iTextAttribute.iTextAttributeData == textAttribute.iTextAttributeData); |
|
1282 TEST(receiveData->iFrameId==DSATTSYV6_DEFAULT_FRAME_IDENTIFIER1); |
|
1283 |
|
1284 INFO_PRINTF2(_L("Test %d - ReceiveData - TReceiveDataV6- passed"),iTestCount++); |
|
1285 |
|
1286 /** |
|
1287 Testing Cancel API for the ReceiveData Proactive command |
|
1288 @test TSAT355 |
|
1289 */ |
|
1290 |
|
1291 //Cancel |
|
1292 sat.NotifyReceiveDataPCmd(reqStatus, *receiveDataPckg); |
|
1293 sat.CancelAsyncRequest(ESatNotifyReceiveDataPCmd); |
|
1294 User::WaitForRequest(reqStatus); |
|
1295 TEST(reqStatus.Int()==KErrCancel); |
|
1296 |
|
1297 CleanupStack::PopAndDestroy(2); |
|
1298 |
|
1299 } |
|
1300 |
|
1301 void CTestSatPCmds1f::Release6Test7L() |
|
1302 { |
|
1303 /** |
|
1304 Testing SendData Proactive command which has been updated |
|
1305 as part of the Release 6 Features of USIM Application ToolKit |
|
1306 @test TSAT356 |
|
1307 */ |
|
1308 RSat::TSendDataV6* sendData = new (ELeave) RSat::TSendDataV6; |
|
1309 CleanupStack::PushL(sendData); |
|
1310 |
|
1311 RSat::TSendDataV6Pckg* sendDataPckg = new (ELeave) RSat::TSendDataV6Pckg(*sendData); |
|
1312 CleanupStack::PushL(sendDataPckg); |
|
1313 |
|
1314 |
|
1315 sat.NotifySendDataPCmd(reqStatus, *sendDataPckg); |
|
1316 User::WaitForRequest(reqStatus); |
|
1317 TEST(reqStatus.Int()==KErrNone); |
|
1318 TEST(sendData->iDestination==DSATTSY_CARD_READER_1); |
|
1319 TEST(sendData->iMode==DSATTSY_SEND_DATA_MODE); |
|
1320 TEST(sendData->iAlphaId.iStatus==DSATTSY_ALPHA_ID1_STATUS); |
|
1321 TEST(sendData->iAlphaId.iAlphaId==DSATTSY_ALPHA_ID1); |
|
1322 TEST(sendData->iIconId.iIdentifier==DSATTSY_ICON_ID1); |
|
1323 TEST(sendData->iIconId.iQualifier==DSATTSY_ICON_QUALIFIER1); |
|
1324 TEST(sendData->iChannelData==DSATTSY_CHANNEL_DATA); |
|
1325 |
|
1326 RSat::TTextAttribute textAttribute; |
|
1327 textAttribute.iStatus = DSATTSY_TEXT_ATTRIBUTE_STATUS; |
|
1328 const TUint8 textAttributeData[DSATTSY_TEXT_ATTRIBUTE_DATA_LENGTH] = DSATTSY_TEXT_ATTRIBUTE_DATA; |
|
1329 textAttribute.iTextAttributeData.Append(textAttributeData, DSATTSY_TEXT_ATTRIBUTE_DATA_LENGTH); |
|
1330 |
|
1331 TEST(sendData->iTextAttribute.iStatus == textAttribute.iStatus); |
|
1332 TEST(sendData->iTextAttribute.iTextAttributeData == textAttribute.iTextAttributeData); |
|
1333 TEST(sendData->iFrameId==DSATTSYV6_DEFAULT_FRAME_IDENTIFIER1); |
|
1334 |
|
1335 INFO_PRINTF2(_L("Test %d - SendData - TSendDataV6- passed"),iTestCount++); |
|
1336 |
|
1337 /** |
|
1338 Testing Cancel API for the SendData Proactive command |
|
1339 @test TSAT357 |
|
1340 */ |
|
1341 |
|
1342 //Cancel |
|
1343 sat.NotifySendDataPCmd(reqStatus, *sendDataPckg); |
|
1344 sat.CancelAsyncRequest(ESatNotifySendDataPCmd); |
|
1345 User::WaitForRequest(reqStatus); |
|
1346 TEST(reqStatus.Int()==KErrCancel); |
|
1347 |
|
1348 CleanupStack::PopAndDestroy(2); |
|
1349 |
|
1350 /** |
|
1351 Testing GetServiceSearch command of the Release 6 Features of USIM Application ToolKit |
|
1352 @test TSAT358 |
|
1353 */ |
|
1354 RSat::TServiceSearchV6* serviceSearch = new (ELeave) RSat::TServiceSearchV6; |
|
1355 CleanupStack::PushL(serviceSearch); |
|
1356 |
|
1357 RSat::TServiceSearchV6Pckg* serviceSearchPckg = new (ELeave) RSat::TServiceSearchV6Pckg(*serviceSearch); |
|
1358 CleanupStack::PushL(serviceSearchPckg); |
|
1359 |
|
1360 sat.NotifyServiceSearchPCmd(reqStatus, *serviceSearchPckg); |
|
1361 User::WaitForRequest(reqStatus); |
|
1362 TEST(reqStatus.Int()==KErrNone); |
|
1363 TEST(serviceSearch->iAlphaId.iStatus=DSATTSY_ALPHA_ID1_STATUS); |
|
1364 TEST(serviceSearch->iAlphaId.iAlphaId==DSATTSY_ALPHA_ID1); |
|
1365 TEST(serviceSearch->iIconId.iIdentifier==DSATTSY_ICON_ID1); |
|
1366 TEST(serviceSearch->iIconId.iQualifier==DSATTSY_ICON_QUALIFIER1); |
|
1367 TEST(serviceSearch->iSearch.iBearerId==DSATTSY_BEARER_TECH_INDEPENDENT); |
|
1368 TEST(serviceSearch->iSearch.iSearchParam==DSATTSY_SERVICE_SEARCH_PARAMS); |
|
1369 TEST(serviceSearch->iFilter.iBearerId==DSATTSY_BEARER_TECH_INDEPENDENT); |
|
1370 TEST(serviceSearch->iFilter.iDeviceFilter==DSATTSY_FILTER_INFO); |
|
1371 TEST(serviceSearch->iTextAttribute.iStatus == textAttribute.iStatus); |
|
1372 TEST(serviceSearch->iTextAttribute.iTextAttributeData == textAttribute.iTextAttributeData); |
|
1373 TEST(serviceSearch->iFrameId==DSATTSYV6_DEFAULT_FRAME_IDENTIFIER1); |
|
1374 |
|
1375 INFO_PRINTF2(_L("Test %d - ServiceSearch - TServiceSearchV6- passed"),iTestCount++); |
|
1376 |
|
1377 /** |
|
1378 Testing Cancel API for the ServiceSearch Proactive command |
|
1379 @test TSAT359 |
|
1380 */ |
|
1381 |
|
1382 //Cancel |
|
1383 sat.NotifyServiceSearchPCmd(reqStatus, *serviceSearchPckg); |
|
1384 sat.CancelAsyncRequest(ESatNotifyServiceSearchPCmd); |
|
1385 User::WaitForRequest(reqStatus); |
|
1386 TEST(reqStatus.Int()==KErrCancel); |
|
1387 |
|
1388 CleanupStack::PopAndDestroy(2); |
|
1389 |
|
1390 /** |
|
1391 Testing GetServiceInfo command of the Release 6 Features of USIM Application ToolKit |
|
1392 @test TSAT360 |
|
1393 */ |
|
1394 RSat::TGetServiceInfoV6* getServiceInfo = new (ELeave) RSat::TGetServiceInfoV6; |
|
1395 CleanupStack::PushL(getServiceInfo); |
|
1396 |
|
1397 RSat::TGetServiceInfoV6Pckg* getServiceInfoPckg = new (ELeave) RSat::TGetServiceInfoV6Pckg(*getServiceInfo); |
|
1398 CleanupStack::PushL(getServiceInfoPckg); |
|
1399 |
|
1400 sat.NotifyGetServiceInfoPCmd(reqStatus, *getServiceInfoPckg); |
|
1401 User::WaitForRequest(reqStatus); |
|
1402 TEST(reqStatus.Int()==KErrNone); |
|
1403 TEST(getServiceInfo->iAlphaId.iStatus==DSATTSY_ALPHA_ID1_STATUS); |
|
1404 TEST(getServiceInfo->iAlphaId.iAlphaId==DSATTSY_ALPHA_ID1); |
|
1405 TEST(getServiceInfo->iIconId.iIdentifier==DSATTSY_ICON_ID1); |
|
1406 TEST(getServiceInfo->iIconId.iQualifier==DSATTSY_ICON_QUALIFIER1); |
|
1407 TEST(getServiceInfo->iAttributeInfo.iBearerId==DSATTSY_BEARER_TECH_INDEPENDENT); |
|
1408 TEST(getServiceInfo->iAttributeInfo.iAttributeInfo==DSATTSY_ATTRIBUTE_INFO); |
|
1409 TEST(getServiceInfo->iTextAttribute.iStatus == textAttribute.iStatus); |
|
1410 TEST(getServiceInfo->iTextAttribute.iTextAttributeData == textAttribute.iTextAttributeData); |
|
1411 TEST(getServiceInfo->iFrameId==DSATTSYV6_DEFAULT_FRAME_IDENTIFIER1); |
|
1412 |
|
1413 INFO_PRINTF2(_L("Test %d - getServiceInfo - TGetServiceInfoV6- passed"),iTestCount++); |
|
1414 |
|
1415 /** |
|
1416 Testing Cancel API for the GetServiceInfo Proactive command |
|
1417 @test TSAT361 |
|
1418 */ |
|
1419 |
|
1420 //Cancel |
|
1421 sat.NotifyGetServiceInfoPCmd(reqStatus, *getServiceInfoPckg); |
|
1422 sat.CancelAsyncRequest(ESatNotifyGetServiceInfoPCmd); |
|
1423 User::WaitForRequest(reqStatus); |
|
1424 TEST(reqStatus.Int()==KErrCancel); |
|
1425 |
|
1426 CleanupStack::PopAndDestroy(2); |
|
1427 |
|
1428 /** |
|
1429 Testing SendSs Proactive command which has been updated |
|
1430 as part of the Release 6 Features of USIM Application ToolKit |
|
1431 @test TSAT369 |
|
1432 */ |
|
1433 RSat::TSendSsV6* sendSs = new (ELeave) RSat::TSendSsV6; |
|
1434 CleanupStack::PushL(sendSs); |
|
1435 |
|
1436 RSat::TSendSsV6Pckg* sendSsPckg = new (ELeave) RSat::TSendSsV6Pckg(*sendSs); |
|
1437 CleanupStack::PushL(sendSsPckg); |
|
1438 |
|
1439 sat.NotifySendSsPCmd(reqStatus, *sendSsPckg); |
|
1440 User::WaitForRequest(reqStatus); |
|
1441 TEST(reqStatus.Int()==KErrNone); |
|
1442 TEST(sendSs->iAlphaId.iAlphaId ==DSATTSY_ALPHA_ID1); |
|
1443 TEST(sendSs->iAlphaId.iStatus ==DSATTSY_ALPHA_ID1_STATUS); |
|
1444 TEST(sendSs->iSsString.iTypeOfNumber ==DSATTSY_TON); |
|
1445 TEST(sendSs->iSsString.iNumberPlan ==DSATTSY_NPI); |
|
1446 TEST(sendSs->iSsString.iSsString ==DSATTSY_SS_STRING); |
|
1447 TEST(sendSs->iIconId.iIdentifier ==DSATTSY_ICON_ID1); |
|
1448 TEST(sendSs->iIconId.iQualifier ==DSATTSY_ICON_QUALIFIER1); |
|
1449 TEST(sendSs->iTextAttribute.iStatus == textAttribute.iStatus); |
|
1450 TEST(sendSs->iTextAttribute.iTextAttributeData == textAttribute.iTextAttributeData); |
|
1451 INFO_PRINTF2(_L("Test %d - SendSs - SendSs command- passed"),iTestCount++); |
|
1452 |
|
1453 /** |
|
1454 Testing Cancel API for the SendSs Proactive command |
|
1455 @test TSAT370 |
|
1456 */ |
|
1457 |
|
1458 //Cancel |
|
1459 sat.NotifySendSsPCmd(reqStatus, *sendSsPckg); |
|
1460 sat.CancelAsyncRequest(ESatNotifySendSsPCmd); |
|
1461 User::WaitForRequest(reqStatus); |
|
1462 TEST(reqStatus.Int()==KErrCancel); |
|
1463 |
|
1464 CleanupStack::PopAndDestroy(2); |
|
1465 |
|
1466 // Now test Open Channel with version 6 of classes |
|
1467 |
|
1468 /** |
|
1469 Open Channel Cs with V6 |
|
1470 @test TSAT362 |
|
1471 @test TSAT363 |
|
1472 */ |
|
1473 |
|
1474 RSat::TOpenCsChannelV6* openCsChannelV6 = new (ELeave) RSat::TOpenCsChannelV6; |
|
1475 CleanupStack::PushL(openCsChannelV6); |
|
1476 |
|
1477 RSat::TOpenCsChannelV6Pckg* openCsChannelV6Pckg = new (ELeave) RSat::TOpenCsChannelV6Pckg(*openCsChannelV6); |
|
1478 CleanupStack::PushL(openCsChannelV6Pckg); |
|
1479 |
|
1480 openCsChannelV6->iPCmdType = DSATTSY_CS_BEARER; |
|
1481 |
|
1482 sat.NotifyOpenChannelPCmd(reqStatus, *openCsChannelV6Pckg); |
|
1483 User::WaitForRequest(reqStatus); |
|
1484 TEST(reqStatus.Int()==KErrNone); |
|
1485 |
|
1486 TEST(openCsChannelV6->PCmdNumber()==DSATTSY_OPEN_CHANNEL_NUMBER); |
|
1487 TEST(openCsChannelV6->iPCmdType==DSATTSY_CS_BEARER); |
|
1488 TEST(openCsChannelV6->iLinkEst==DSATTSY_ON_DEMAND_ESTABLISHMENT); |
|
1489 TEST(openCsChannelV6->iReconnectionMode==DSATTSY_AUTO_RECONNECTION); |
|
1490 TEST(openCsChannelV6->iAlphaId.iStatus==DSATTSY_ALPHA_ID1_STATUS); |
|
1491 TEST(openCsChannelV6->iAlphaId.iAlphaId==DSATTSY_ALPHA_ID1); |
|
1492 TEST(openCsChannelV6->iIconId.iIdentifier==DSATTSY_ICON_ID1); |
|
1493 TEST(openCsChannelV6->iIconId.iQualifier==DSATTSY_ICON_QUALIFIER1); |
|
1494 TEST(openCsChannelV6->iBearer.iType==DSATTSY_CSD_BEARER_TYPE); |
|
1495 TEST(openCsChannelV6->iBearer.iParams==DSATTSY_BEARER_PARAMS); |
|
1496 TEST(openCsChannelV6->iBufferSize==DSATTSY_BUFFER_SIZE); |
|
1497 TEST(openCsChannelV6->iSimMeInterface.iPrtNumber==DSATTSY_PORT_1); |
|
1498 TEST(openCsChannelV6->iSimMeInterface.iTransportProto==DSATTSY_TCP_PROTO); |
|
1499 TEST(openCsChannelV6->iDestinationAddress.iType==DSATTSY_IPV4_TYPE); |
|
1500 TEST(openCsChannelV6->iDestinationAddress.iAddress==DSATTSY_ADDRESS); |
|
1501 TEST(openCsChannelV6->iAddress.iTypeOfNumber==DSATTSY_TON); |
|
1502 TEST(openCsChannelV6->iAddress.iNumberPlan==DSATTSY_NPI); |
|
1503 TEST(openCsChannelV6->iAddress.iTelNumber==DSATTSY_TEL_NUMBER); |
|
1504 TEST(openCsChannelV6->iSubAddress==DSATTSY_SUBADDRESS); |
|
1505 TEST(openCsChannelV6->iDuration1.iTimeUnit==DSATTSY_TIME_UNIT); |
|
1506 TEST(openCsChannelV6->iDuration1.iNumOfUnits==DSATTSY_NUM_OF_UNITS); |
|
1507 TEST(openCsChannelV6->iDuration2.iTimeUnit==DSATTSY_TIME_UNIT); |
|
1508 TEST(openCsChannelV6->iDuration2.iNumOfUnits==DSATTSY_TIME_UNIT); |
|
1509 TEST(openCsChannelV6->iLocalAddress.iType==DSATTSY_IPV4_TYPE); |
|
1510 TEST(openCsChannelV6->iLocalAddress.iAddress==DSATTSY_ADDRESS); |
|
1511 TEST(openCsChannelV6->iUserLogin==DSATTSY_LOGIN); |
|
1512 TEST(openCsChannelV6->iUserPassword==DSATTSY_PASSWORD); |
|
1513 TEST(openCsChannelV6->iTextAttribute.iStatus == textAttribute.iStatus); |
|
1514 TEST(openCsChannelV6->iTextAttribute.iTextAttributeData == textAttribute.iTextAttributeData); |
|
1515 TEST(openCsChannelV6->iFrameId==DSATTSYV6_FRAME_IDENTIFIER1); |
|
1516 |
|
1517 INFO_PRINTF2(_L("Test %d - RSat::NotifyOpenChannelPCmd - CS channel (RSat::TOpenCsChannelV6) - passed"),iTestCount++); |
|
1518 |
|
1519 // Open Channel Cancel |
|
1520 sat.NotifyOpenChannelPCmd(reqStatus,*openCsChannelV6Pckg); |
|
1521 sat.CancelAsyncRequest(ESatNotifyOpenChannelPCmd); |
|
1522 |
|
1523 User::WaitForRequest(reqStatus); |
|
1524 TEST(reqStatus.Int()==KErrCancel); |
|
1525 INFO_PRINTF2(_L("Test %d - RSat::NotifyOpenChannelPCmd Cancel (RSat::TOpenCsChannelV6) passed"),iTestCount++); |
|
1526 |
|
1527 CleanupStack::PopAndDestroy(2); |
|
1528 |
|
1529 /** |
|
1530 Open Channel Gprs with V6 |
|
1531 @test TSAT375 |
|
1532 @test TSAT376 |
|
1533 */ |
|
1534 |
|
1535 RSat::TOpenGprsChannelV6* openGprsChannelV6 = new (ELeave) RSat::TOpenGprsChannelV6; |
|
1536 CleanupStack::PushL(openGprsChannelV6); |
|
1537 |
|
1538 RSat::TOpenGprsChannelV6Pckg* openGprsChannelV6Pckg = new (ELeave) RSat::TOpenGprsChannelV6Pckg(*openGprsChannelV6); |
|
1539 CleanupStack::PushL(openGprsChannelV6Pckg); |
|
1540 |
|
1541 openGprsChannelV6->iPCmdType=DSATTSY_GPRS_BEARER; |
|
1542 |
|
1543 sat.NotifyOpenChannelPCmd(reqStatus,*openGprsChannelV6Pckg); |
|
1544 User::WaitForRequest(reqStatus); |
|
1545 TEST(reqStatus.Int()==KErrNone); |
|
1546 |
|
1547 TEST(openGprsChannelV6->PCmdNumber()==DSATTSY_OPEN_CHANNEL_NUMBER); |
|
1548 TEST(openGprsChannelV6->iPCmdType==DSATTSY_GPRS_BEARER); |
|
1549 TEST(openGprsChannelV6->iLinkEst==DSATTSY_ON_DEMAND_ESTABLISHMENT); |
|
1550 TEST(openGprsChannelV6->iReconnectionMode==DSATTSY_AUTO_RECONNECTION); |
|
1551 TEST(openGprsChannelV6->iAlphaId.iStatus==DSATTSY_ALPHA_ID1_STATUS); |
|
1552 TEST(openGprsChannelV6->iAlphaId.iAlphaId==DSATTSY_ALPHA_ID1); |
|
1553 TEST(openGprsChannelV6->iIconId.iIdentifier==DSATTSY_ICON_ID1); |
|
1554 TEST(openGprsChannelV6->iIconId.iQualifier==DSATTSY_ICON_QUALIFIER1); |
|
1555 TEST(openGprsChannelV6->iBearer.iType==DSATTSYV6_GPRS_BEARER_TYPE1); |
|
1556 TEST(openGprsChannelV6->iBearer.iParams==DSATTSY_BEARER_PARAMS); |
|
1557 TEST(openGprsChannelV6->iBufferSize==DSATTSY_BUFFER_SIZE); |
|
1558 TEST(openGprsChannelV6->iSimMeInterface.iPrtNumber==DSATTSY_PORT_1); |
|
1559 TEST(openGprsChannelV6->iSimMeInterface.iTransportProto==DSATTSY_TCP_PROTO); |
|
1560 TEST(openGprsChannelV6->iDestinationAddress.iType==DSATTSY_IPV4_TYPE); |
|
1561 TEST(openGprsChannelV6->iDestinationAddress.iAddress==DSATTSY_ADDRESS); |
|
1562 TEST(openGprsChannelV6->iAccessName==DSATTSY_ACCESS_NAME); |
|
1563 TEST(openGprsChannelV6->iLocalAddress.iType==DSATTSY_IPV4_TYPE); |
|
1564 TEST(openGprsChannelV6->iLocalAddress.iAddress==DSATTSY_ADDRESS); |
|
1565 TEST(openGprsChannelV6->iUserLogin==DSATTSY_LOGIN); |
|
1566 TEST(openGprsChannelV6->iUserPassword==DSATTSY_PASSWORD); |
|
1567 TEST(openGprsChannelV6->iTextAttribute.iStatus == textAttribute.iStatus); |
|
1568 TEST(openGprsChannelV6->iTextAttribute.iTextAttributeData == textAttribute.iTextAttributeData); |
|
1569 TEST(openGprsChannelV6->iFrameId==DSATTSYV6_FRAME_IDENTIFIER1); |
|
1570 |
|
1571 INFO_PRINTF2(_L("Test %d - RSat::NotifyOpenChannelPCmd - GPRS Channel (RSat::TOpenGprsChannelV6) - passed"),iTestCount++); |
|
1572 |
|
1573 // Open Channel Cancel with V6 |
|
1574 sat.NotifyOpenChannelPCmd(reqStatus,*openGprsChannelV6Pckg); |
|
1575 sat.CancelAsyncRequest(ESatNotifyOpenChannelPCmd); |
|
1576 |
|
1577 User::WaitForRequest(reqStatus); |
|
1578 TEST(reqStatus.Int()==KErrCancel); |
|
1579 INFO_PRINTF2(_L("Test %d - RSat::NotifyOpenChannelPCmd Cancel (RSat::TOpenGprsChannelV6) passed"),iTestCount++); |
|
1580 |
|
1581 CleanupStack::PopAndDestroy(2); |
|
1582 |
|
1583 /** |
|
1584 Open Channel LocalLinks with version 6 |
|
1585 @test TSAT377 |
|
1586 @test TSAT378 |
|
1587 */ |
|
1588 |
|
1589 RSat::TOpenLocalLinksChannelV6* openLocalChannelV6 = new(ELeave) RSat::TOpenLocalLinksChannelV6; |
|
1590 CleanupStack::PushL(openLocalChannelV6); |
|
1591 |
|
1592 RSat::TOpenLocalLinksChannelV6Pckg* openLocalChannelV6Pckg = new(ELeave) RSat::TOpenLocalLinksChannelV6Pckg(*openLocalChannelV6); |
|
1593 CleanupStack::PushL(openLocalChannelV6Pckg); |
|
1594 |
|
1595 TEST(openLocalChannelV6->ExtensionId() == RSat::KSatV6); |
|
1596 TEST(openLocalChannelV6->iTextAttribute.iStatus == RSat::ETextAttributeNotSet); |
|
1597 |
|
1598 openLocalChannelV6->iPCmdType=DSATTSY_LOCAL_BEARER; |
|
1599 |
|
1600 sat.NotifyOpenChannelPCmd(reqStatus,*openLocalChannelV6Pckg); |
|
1601 User::WaitForRequest(reqStatus); |
|
1602 TEST(reqStatus.Int()==KErrNone); |
|
1603 |
|
1604 TEST(openLocalChannelV6->PCmdNumber()==DSATTSY_OPEN_CHANNEL_NUMBER); |
|
1605 TEST(openLocalChannelV6->iPCmdType==DSATTSY_LOCAL_BEARER); |
|
1606 TEST(openLocalChannelV6->iLinkEst==DSATTSY_ON_DEMAND_ESTABLISHMENT); |
|
1607 TEST(openLocalChannelV6->iReconnectionMode==DSATTSY_AUTO_RECONNECTION); |
|
1608 TEST(openLocalChannelV6->iAlphaId.iStatus==DSATTSY_ALPHA_ID1_STATUS); |
|
1609 TEST(openLocalChannelV6->iAlphaId.iAlphaId==DSATTSY_ALPHA_ID1); |
|
1610 TEST(openLocalChannelV6->iIconId.iIdentifier==DSATTSY_ICON_ID1); |
|
1611 TEST(openLocalChannelV6->iIconId.iQualifier==DSATTSY_ICON_QUALIFIER1); |
|
1612 TEST(openLocalChannelV6->iBearer.iType==DSATTSY_CSD_BEARER_TYPE); |
|
1613 TEST(openLocalChannelV6->iBearer.iParams==DSATTSY_BEARER_PARAMS); |
|
1614 TEST(openLocalChannelV6->iBufferSize==DSATTSY_BUFFER_SIZE); |
|
1615 TEST(openLocalChannelV6->iSimMeInterface.iPrtNumber==DSATTSY_PORT_1); |
|
1616 TEST(openLocalChannelV6->iSimMeInterface.iTransportProto==DSATTSY_TCP_PROTO); |
|
1617 TEST(openLocalChannelV6->iDestinationAddress.iType==DSATTSY_IPV4_TYPE); |
|
1618 TEST(openLocalChannelV6->iDestinationAddress.iAddress==DSATTSY_ADDRESS); |
|
1619 TEST(openLocalChannelV6->iDuration1.iTimeUnit==DSATTSY_TIME_UNIT); |
|
1620 TEST(openLocalChannelV6->iDuration1.iNumOfUnits==DSATTSY_TIME_UNIT); |
|
1621 TEST(openLocalChannelV6->iDuration2.iTimeUnit==DSATTSY_TIME_UNIT); |
|
1622 TEST(openLocalChannelV6->iDuration2.iNumOfUnits==DSATTSY_TIME_UNIT); |
|
1623 TEST(openLocalChannelV6->iRemoteAddress.iCoding==DSATTSY_CODING); |
|
1624 TEST(openLocalChannelV6->iRemoteAddress.iAddress==DSATTSY_ADDRESS); |
|
1625 TEST(openLocalChannelV6->iUserPassword==DSATTSY_PASSWORD); |
|
1626 TEST(openLocalChannelV6->iTextAttribute.iStatus == textAttribute.iStatus); |
|
1627 TEST(openLocalChannelV6->iTextAttribute.iTextAttributeData == textAttribute.iTextAttributeData); |
|
1628 TEST(openLocalChannelV6->iFrameId==DSATTSYV6_FRAME_IDENTIFIER1); |
|
1629 |
|
1630 INFO_PRINTF2(_L("Test %d - RSat::NotifyOpenChannelPCmd - Local Channel (RSat::TOpenLocalLinksChannelV6) - passed"),iTestCount++); |
|
1631 |
|
1632 // Open Channel Cancel with version 6 |
|
1633 sat.NotifyOpenChannelPCmd(reqStatus,*openLocalChannelV6Pckg); |
|
1634 sat.CancelAsyncRequest(ESatNotifyOpenChannelPCmd); |
|
1635 |
|
1636 User::WaitForRequest(reqStatus); |
|
1637 TEST(reqStatus.Int()==KErrCancel); |
|
1638 INFO_PRINTF2(_L("Test %d - RSat::NotifyOpenChannelPCmd Cancel (RSat::TOpenLocalLinksChannelV6) passed"),iTestCount++); |
|
1639 |
|
1640 CleanupStack::PopAndDestroy(2); |
|
1641 } |
|
1642 |