24
|
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 |
// Test step definitions for the PhoneIdentity functional unit.
|
|
15 |
//
|
|
16 |
//
|
|
17 |
|
|
18 |
/**
|
|
19 |
@internalTechnology
|
|
20 |
*/
|
|
21 |
|
|
22 |
#include "cctsyintegrationtestphoneidentity.h"
|
|
23 |
|
|
24 |
#include "cctsyinidata.h"
|
|
25 |
|
|
26 |
|
|
27 |
CCTSYIntegrationTestPhoneIdentityBase::CCTSYIntegrationTestPhoneIdentityBase(CEtelSessionMgr& aEtelSessionMgr)
|
|
28 |
: CCTSYIntegrationTestSuiteStepBase(aEtelSessionMgr), iCallControlHelper(*this), iSupplementalHelper(*this), iNetworkTestHelper(*this)
|
|
29 |
/**
|
|
30 |
* Constructor
|
|
31 |
*/
|
|
32 |
{
|
|
33 |
}
|
|
34 |
|
|
35 |
CCTSYIntegrationTestPhoneIdentityBase::~CCTSYIntegrationTestPhoneIdentityBase()
|
|
36 |
/*
|
|
37 |
* Destructor
|
|
38 |
*/
|
|
39 |
{
|
|
40 |
}
|
|
41 |
|
|
42 |
|
|
43 |
CCTSYIntegrationTestPhoneIdentity0001::CCTSYIntegrationTestPhoneIdentity0001(CEtelSessionMgr& aEtelSessionMgr)
|
|
44 |
: CCTSYIntegrationTestPhoneIdentityBase(aEtelSessionMgr)
|
|
45 |
/**
|
|
46 |
* Constructor.
|
|
47 |
*/
|
|
48 |
{
|
|
49 |
SetTestStepName(CCTSYIntegrationTestPhoneIdentity0001::GetTestStepName());
|
|
50 |
}
|
|
51 |
|
|
52 |
CCTSYIntegrationTestPhoneIdentity0001::~CCTSYIntegrationTestPhoneIdentity0001()
|
|
53 |
/**
|
|
54 |
* Destructor.
|
|
55 |
*/
|
|
56 |
{
|
|
57 |
}
|
|
58 |
|
|
59 |
TVerdict CCTSYIntegrationTestPhoneIdentity0001::doTestStepL()
|
|
60 |
/**
|
|
61 |
* @SYMTestCaseID BA-CTSY-INT-PID-0001
|
|
62 |
* @SYMFssID BA/CTSY/PID-0001
|
|
63 |
* @SYMTestCaseDesc Deactivate Calling Line Identification Restriction (CLIR).
|
|
64 |
* @SYMTestPriority High
|
|
65 |
* @SYMTestActions RMobileCall::NotifyMobileCallStatusChange, RMobilePhone::SetIdentityServiceStatus, RMobilePhone::NotifyIdentityServiceStatus, RMobileCall::GetMobileCallInfo, RCall::Dial, RCall::HangUp
|
|
66 |
* @SYMTestExpectedResults Pass - CLIR can be deactivated and remote party can get the calling number.
|
|
67 |
* @SYMTestType CIT
|
|
68 |
* @SYMTestCaseDependencies live/manual
|
|
69 |
*
|
|
70 |
* Reason for test: Verify service status notifications complete and called party can get the calling number.
|
|
71 |
*
|
|
72 |
* @return - TVerdict code
|
|
73 |
*/
|
|
74 |
{
|
|
75 |
|
|
76 |
//
|
|
77 |
// SET UP
|
|
78 |
//
|
|
79 |
|
|
80 |
// Ensure RMobilePhone::GetCallServiceCaps returns caps in set of KCapsGetClirStatus
|
|
81 |
RMobilePhone& mobilePhone = iEtelSessionMgr.GetPhoneL(KMainServer, KMainPhone);
|
|
82 |
TUint32 callServiceCaps;
|
|
83 |
|
|
84 |
CHECK_TRUE_L(mobilePhone.GetCallServiceCaps(callServiceCaps)==KErrNone, _L("RMobilePhone::GetCallServiceCaps return value is not KErrNone"));
|
|
85 |
TUint32 expectedServiceCaps = RMobilePhone::KCapsGetClirStatus;
|
|
86 |
CHECK_BITS_SET_L(callServiceCaps, expectedServiceCaps, KNoUnwantedBits, _L("RMobilePhone::GetCallServiceCaps returned wrong caps"));
|
|
87 |
|
|
88 |
CHECK_EQUALS_L(iNetworkTestHelper.WaitForRegisteredOnHomeNetworkL(mobilePhone), KErrNone, _L("TNetworkTsyTestHelper::WaitForRegisteredOnHomeNetworkL returned with an error"));
|
|
89 |
|
|
90 |
|
|
91 |
// Get Voice Line 1.
|
|
92 |
RMobileLine& mobileLine= iEtelSessionMgr.GetLineL(KMainServer, KMainPhone, KVoiceLine);
|
|
93 |
|
|
94 |
// Get Call 1.
|
|
95 |
RMobileCall& mobileCall= iEtelSessionMgr.GetCallL(KMainServer, KMainPhone, KVoiceLine, KCall1);
|
|
96 |
|
|
97 |
//
|
|
98 |
// SET UP END
|
|
99 |
//
|
|
100 |
|
|
101 |
StartTest();
|
|
102 |
|
|
103 |
//
|
|
104 |
// TEST START
|
|
105 |
//
|
|
106 |
|
|
107 |
// Check RMobilePhone::GetIdentityServiceStatus with aService=EIdServiceCallerRestriction and aLocation=EInfoLocationCachePreferred returns aStatus=EIdServiceActiveDefaultAllowed
|
|
108 |
RMobilePhone::TMobilePhoneIdServiceStatus idServiceStatus;
|
|
109 |
TExtEtelRequestStatus getIdentityServiceStatus(mobilePhone, EMobilePhoneGetIdentityServiceStatus);
|
|
110 |
CleanupStack::PushL(getIdentityServiceStatus);
|
|
111 |
|
|
112 |
mobilePhone.GetIdentityServiceStatus(getIdentityServiceStatus, RMobilePhone::EIdServiceCallerRestriction, idServiceStatus);
|
|
113 |
|
|
114 |
ASSERT_EQUALS(WaitForRequestWithTimeOut(getIdentityServiceStatus, ETimeMedium), KErrNone, _L("RMobilePhone::GetIdentityServiceStatus timed-out"));
|
|
115 |
ASSERT_EQUALS(getIdentityServiceStatus.Int(), KErrNone, _L("RMobilePhone::GetIdentityServiceStatus getIdentityServiceStatus completed with incorrect error"));
|
|
116 |
|
|
117 |
ASSERT_EQUALS(idServiceStatus, RMobilePhone::EIdServiceActiveDefaultAllowed, _L("RMobilePhone::GetIdentityServiceStatus idServiceStatus is not RMobilePhone::EIdServiceActiveDefaultAllowed"));
|
|
118 |
|
|
119 |
/* $CTSYProblem
|
|
120 |
* The CTSY does not support setting of the identity service status with RMobilePhone::SetIdentityServiceStatus API.
|
|
121 |
* If support is added, the rest of this test case can be used.
|
|
122 |
*/
|
|
123 |
ERR_PRINTF1(_L("<font color=Cyan>$CTSYProblem: RMobilePhone::SetIdentityServiceStatus not supported by CTSY.<font color=Black>"));
|
|
124 |
|
|
125 |
// Set CLIR with RMobilePhone::SetIdentityServiceStatus with aService=EIdServiceCallerRestriction aSetting=EIdServicePresentationRestricted
|
|
126 |
/*TExtEtelRequestStatus setIdentityServiceStatus(mobilePhone, EMobilePhoneSetIdentityServiceStatus);
|
|
127 |
CleanupStack::PushL(setIdentityServiceStatus);
|
|
128 |
|
|
129 |
mobilePhone.SetIdentityServiceStatus(setIdentityServiceStatus, RMobilePhone::EIdServiceCallerRestriction, RMobilePhone::EIdServicePresentationRestricted);
|
|
130 |
|
|
131 |
ASSERT_EQUALS(WaitForRequestWithTimeOut(setIdentityServiceStatus, ETimeMedium), KErrNone, _L("RMobilePhone::SetIdentityServiceStatus timed-out"));
|
|
132 |
ASSERT_EQUALS(setIdentityServiceStatus.Int(), KErrNone, _L("RMobilePhone::SetIdentityServiceStatus setIdentityServiceStatus completed with incorrect error"));
|
|
133 |
|
|
134 |
// Check RMobilePhone::GetIdentityServiceStatus with aService=EIdServiceCallerRestriction and aLocation=EInfoLocationCachePreferred returns aStatus=EIdServiceActiveDefaultRestricted
|
|
135 |
mobilePhone.GetIdentityServiceStatus(getIdentityServiceStatus, RMobilePhone::EIdServiceCallerRestriction, idServiceStatus);
|
|
136 |
|
|
137 |
ASSERT_EQUALS(WaitForRequestWithTimeOut(getIdentityServiceStatus, ETimeMedium), KErrNone, _L("RMobilePhone::GetIdentityServiceStatus timed-out"));
|
|
138 |
ASSERT_EQUALS(getIdentityServiceStatus.Int(), KErrNone, _L("RMobilePhone::GetIdentityServiceStatus getIdentityServiceStatus completed with incorrect error"));
|
|
139 |
|
|
140 |
ASSERT_EQUALS(idServiceStatus, RMobilePhone::EIdServiceActiveDefaultRestricted, _L("RMobilePhone::GetIdentityServiceStatus idServiceStatus is not RMobilePhone::EIdServiceActiveDefaultRestricted"));
|
|
141 |
|
|
142 |
|
|
143 |
// === Check that caller ID is not available when CLIR is active ===
|
|
144 |
|
|
145 |
// Display a prompt to the user to telling them that they should have set their own phone number to voice number 1 in the config file
|
|
146 |
DisplayUserInteractionPromptL(_L("You should have set your own phone number to voice number 1 in the config file?"), ETimeMedium);
|
|
147 |
|
|
148 |
// Dial the user's phone number.
|
|
149 |
RMobileCall::TMobileCallStatus mobileCallState;
|
|
150 |
|
|
151 |
// Post notification for RMobileCall::NotifyMobileCallStatusChange
|
|
152 |
TExtEtelRequestStatus notifyMobileCallStatus(mobileCall, EMobileCallNotifyMobileCallStatusChange);
|
|
153 |
CleanupStack::PushL(notifyMobileCallStatus);
|
|
154 |
|
|
155 |
mobileCall.NotifyMobileCallStatusChange(notifyMobileCallStatus, mobileCallState);
|
|
156 |
|
|
157 |
TPtrC number;
|
|
158 |
ASSERT_TRUE(GetStringFromConfig(KIniVoiceNumSection, KIniVoiceNumber1, number) != EFalse, _L("GetStringFromConfig did not complete as expected"));
|
|
159 |
DEBUG_PRINTF2(_L("Board Now Dialling: %S"), &number);
|
|
160 |
TCoreEtelRequestStatus<RCall> dialStatus(mobileCall, &RCall::DialCancel);
|
|
161 |
CleanupStack::PushL(dialStatus);
|
|
162 |
mobileCall.Dial(dialStatus, number);
|
|
163 |
ASSERT_EQUALS(WaitForRequestWithTimeOut(dialStatus, ETimeMedium), KErrNone, _L("RCall::Dial timed-out"));
|
|
164 |
ASSERT_EQUALS(dialStatus.Int(), KErrNone, _L("RCall::Dial problem dialling"));
|
|
165 |
|
|
166 |
// Check RMobileCall::NotifyMobileCallStatusChange completes with EStatusConnected.
|
|
167 |
RMobileCall::TMobileCallStatus expectedMobileCallStatus=RMobileCall::EStatusConnected;
|
|
168 |
iCallControlHelper.WaitForMobileCallNotifyMobileCallStatusChange(mobileCall,
|
|
169 |
notifyMobileCallStatus,
|
|
170 |
mobileCallState,
|
|
171 |
expectedMobileCallStatus,
|
|
172 |
KErrNone);
|
|
173 |
|
|
174 |
mobileCall.NotifyMobileCallStatusChange(notifyMobileCallStatus, mobileCallState);
|
|
175 |
|
|
176 |
// User should check that they can not see the caller's number
|
|
177 |
DisplayUserInteractionPromptL(_L("User should check that they have received a phone call and should check that can not see the caller's number."), ETimeMedium);
|
|
178 |
|
|
179 |
// Hang up.
|
|
180 |
DEBUG_PRINTF1(_L("Hangup call"));
|
|
181 |
ASSERT_EQUALS(mobileCall.HangUp(), KErrNone, _L("RCall::HangUp return value not KErrNone"));
|
|
182 |
|
|
183 |
// Check RMobileCall::NotifyMobileCallStatusChange completes with EStatusIdle.
|
|
184 |
expectedMobileCallStatus=RMobileCall::EStatusIdle;
|
|
185 |
iCallControlHelper.WaitForMobileCallNotifyMobileCallStatusChange(mobileCall,
|
|
186 |
notifyMobileCallStatus,
|
|
187 |
mobileCallState,
|
|
188 |
expectedMobileCallStatus,
|
|
189 |
KErrNone);
|
|
190 |
|
|
191 |
mobileCall.NotifyMobileCallStatusChange(notifyMobileCallStatus, mobileCallState);
|
|
192 |
|
|
193 |
// === Deactivate CLIR ===
|
|
194 |
|
|
195 |
// Deactivate CLIR with RMobilePhone::SetIdentityServiceStatus with aService=EIdServiceCallerRestriction aSetting=EIdServicePresentationAllowed
|
|
196 |
RMobilePhone::TMobilePhoneIdService idService = RMobilePhone::EIdServiceCallerRestriction;
|
|
197 |
RMobilePhone::TMobilePhoneIdServiceStatus idServiceStateNotify;
|
|
198 |
|
|
199 |
// Post notification for RMobileCall::NotifyIdentityServiceStatus
|
|
200 |
TExtEtelRequestStatus notifyIdentityServiceStatus(mobilePhone, EMobilePhoneNotifyIdentityServiceStatus);
|
|
201 |
CleanupStack::PushL(notifyIdentityServiceStatus);
|
|
202 |
|
|
203 |
mobilePhone.NotifyIdentityServiceStatus(notifyIdentityServiceStatus, idService, idServiceStateNotify);
|
|
204 |
|
|
205 |
mobilePhone.SetIdentityServiceStatus(setIdentityServiceStatus, RMobilePhone::EIdServiceCallerRestriction, RMobilePhone::EIdServicePresentationAllowed);
|
|
206 |
|
|
207 |
ASSERT_EQUALS(WaitForRequestWithTimeOut(setIdentityServiceStatus, ETimeMedium), KErrNone, _L("RMobilePhone::SetIdentityServiceStatus timed-out"));
|
|
208 |
ASSERT_EQUALS(setIdentityServiceStatus.Int(), KErrNone, _L("RMobilePhone::SetIdentityServiceStatus setIdentityServiceStatus completed with incorrect error"));
|
|
209 |
|
|
210 |
// Check RMobilePhone::NotifyIdentityServiceStatus with aService=EIdServiceCallerRestriction completes with aStatus=EIdServiceActiveDefaultAllowed
|
|
211 |
RMobilePhone::TMobilePhoneIdService expectedService=RMobilePhone::EIdServiceCallerRestriction;
|
|
212 |
iSupplementalHelper.WaitForMobilePhoneNotifyIdentityServiceStatus(mobilePhone,
|
|
213 |
notifyIdentityServiceStatus,
|
|
214 |
idService,
|
|
215 |
expectedService,
|
|
216 |
idServiceStateNotify,
|
|
217 |
KErrNone);
|
|
218 |
|
|
219 |
mobilePhone.NotifyIdentityServiceStatus(notifyIdentityServiceStatus, idService, idServiceStateNotify);
|
|
220 |
|
|
221 |
// Check RMobilePhone::GetIdentityServiceStatus with aService=EIdServiceCallerRestriction and aLocation=EInfoLocationCachePreferred returns aStatus=EIdServiceActiveDefaultAllowed
|
|
222 |
mobilePhone.GetIdentityServiceStatus(getIdentityServiceStatus, RMobilePhone::EIdServiceCallerRestriction, idServiceStatus);
|
|
223 |
|
|
224 |
ASSERT_EQUALS(WaitForRequestWithTimeOut(getIdentityServiceStatus, ETimeMedium), KErrNone, _L("RMobilePhone::GetIdentityServiceStatus timed-out"));
|
|
225 |
ASSERT_EQUALS(getIdentityServiceStatus.Int(), KErrNone, _L("RMobilePhone::GetIdentityServiceStatus getIdentityServiceStatus completed with incorrect error"));
|
|
226 |
|
|
227 |
ASSERT_EQUALS(idServiceStatus, RMobilePhone::EIdServiceActiveDefaultAllowed, _L("RMobilePhone::GetIdentityServiceStatus idServiceStatus is not RMobilePhone::EIdServiceActiveDefaultAllowed"));
|
|
228 |
|
|
229 |
// === Make a call and see if the remote number is present ===
|
|
230 |
|
|
231 |
// Dial the user's phone number.
|
|
232 |
DisplayUserInteractionPromptL(_L("You should have set your own phone number to voice number 1 in the config file?"), ETimeMedium);
|
|
233 |
|
|
234 |
DEBUG_PRINTF2(_L("Board Now Dialling: %S"), &number);
|
|
235 |
mobileCall.Dial(dialStatus, number);
|
|
236 |
ASSERT_EQUALS(WaitForRequestWithTimeOut(dialStatus, ETimeMedium), KErrNone, _L("RCall::Dial timed-out"));
|
|
237 |
ASSERT_EQUALS(dialStatus.Int(), KErrNone, _L("RCall::Dial problem dialling"));
|
|
238 |
|
|
239 |
// Check RMobileCall::NotifyMobileCallStatusChange completes with EStatusConnected.
|
|
240 |
expectedMobileCallStatus=RMobileCall::EStatusConnected;
|
|
241 |
iCallControlHelper.WaitForMobileCallNotifyMobileCallStatusChange(mobileCall,
|
|
242 |
notifyMobileCallStatus,
|
|
243 |
mobileCallState,
|
|
244 |
expectedMobileCallStatus,
|
|
245 |
KErrNone);
|
|
246 |
|
|
247 |
// User should check that they can see the caller's number
|
|
248 |
DisplayUserInteractionPromptL(_L("User should check that they have received a phone call and should check that can see the caller's number."), ETimeMedium);
|
|
249 |
|
|
250 |
// Hang up.
|
|
251 |
DEBUG_PRINTF1(_L("Hangup call"));
|
|
252 |
ASSERT_EQUALS(mobileCall.HangUp(), KErrNone, _L("RCall::HangUp return value not KErrNone"));
|
|
253 |
|
|
254 |
// Check RMobileCall::NotifyMobileCallStatusChange completes with EStatusIdle.
|
|
255 |
ASSERT_EQUALS(WaitForRequestWithTimeOut(notifyMobileCallStatus, ETimeMedium), KErrNone, _L("RMobileCall::HangUp timed-out"));
|
|
256 |
ASSERT_EQUALS(notifyMobileCallStatus.Int(), KErrNone, _L("RMobileCall::HangUp notifyMobileCallStatus completed with incorrect error"));
|
|
257 |
|
|
258 |
ASSERT_EQUALS(mobileCallState, RMobileCall::EStatusIdle, _L("RMobileCall::HangUp mobileCallState is not EStatusIdle"));
|
|
259 |
|
|
260 |
// === Reactivate CLIR ===
|
|
261 |
|
|
262 |
// Activate CLIR with RMobilePhone::SetIdentityServiceStatus with aService=EIdServiceCallerRestriction aSetting=EIdServicePresentationRestricted
|
|
263 |
mobilePhone.SetIdentityServiceStatus(setIdentityServiceStatus, RMobilePhone::EIdServiceCallerRestriction, RMobilePhone::EIdServicePresentationRestricted);
|
|
264 |
|
|
265 |
ASSERT_EQUALS(WaitForRequestWithTimeOut(setIdentityServiceStatus, ETimeMedium), KErrNone, _L("RMobilePhone::SetIdentityServiceStatus timed-out"));
|
|
266 |
ASSERT_EQUALS(setIdentityServiceStatus.Int(), KErrNone, _L("RMobilePhone::SetIdentityServiceStatus setIdentityServiceStatus completed with incorrect error"));
|
|
267 |
|
|
268 |
// Check RMobilePhone::NotifyIdentityServiceStatus with aService=EIdServiceCallerRestriction completes with aStatus=EIdServiceActiveDefaultRestricted
|
|
269 |
expectedService=RMobilePhone::EIdServiceCallerRestriction;
|
|
270 |
iSupplementalHelper.WaitForMobilePhoneNotifyIdentityServiceStatus(mobilePhone,
|
|
271 |
notifyIdentityServiceStatus,
|
|
272 |
idService,
|
|
273 |
expectedService,
|
|
274 |
idServiceStateNotify,
|
|
275 |
KErrNone);
|
|
276 |
|
|
277 |
// Check RMobilePhone::GetIdentityServiceStatus with aService=EIdServiceCallerRestriction and aLocation=EInfoLocationCachePreferred returns aStatus=EIdServiceActiveDefaultRestricted
|
|
278 |
mobilePhone.GetIdentityServiceStatus(getIdentityServiceStatus, RMobilePhone::EIdServiceCallerRestriction, idServiceStatus);
|
|
279 |
|
|
280 |
ASSERT_EQUALS(WaitForRequestWithTimeOut(getIdentityServiceStatus, ETimeMedium), KErrNone, _L("RMobilePhone::GetIdentityServiceStatus timed-out"));
|
|
281 |
ASSERT_EQUALS(getIdentityServiceStatus.Int(), KErrNone, _L("RMobilePhone::GetIdentityServiceStatus getIdentityServiceStatus completed with incorrect error"));
|
|
282 |
|
|
283 |
ASSERT_EQUALS(idServiceStatus, RMobilePhone::EIdServiceActiveDefaultRestricted, _L("RMobilePhone::GetIdentityServiceStatus idServiceStatus is not RMobilePhone::EIdServiceActiveDefaultRestricted"));
|
|
284 |
*/
|
|
285 |
//
|
|
286 |
// TEST END
|
|
287 |
//
|
|
288 |
|
|
289 |
StartCleanup();
|
|
290 |
|
|
291 |
CleanupStack::PopAndDestroy(&getIdentityServiceStatus);
|
|
292 |
|
|
293 |
return TestStepResult();
|
|
294 |
}
|
|
295 |
|
|
296 |
TPtrC CCTSYIntegrationTestPhoneIdentity0001::GetTestStepName()
|
|
297 |
/**
|
|
298 |
* @return The test step name.
|
|
299 |
*/
|
|
300 |
{
|
|
301 |
return _L("CCTSYIntegrationTestPhoneIdentity0001");
|
|
302 |
}
|
|
303 |
|
|
304 |
|
|
305 |
|
|
306 |
CCTSYIntegrationTestPhoneIdentity0002::CCTSYIntegrationTestPhoneIdentity0002(CEtelSessionMgr& aEtelSessionMgr)
|
|
307 |
: CCTSYIntegrationTestPhoneIdentityBase(aEtelSessionMgr)
|
|
308 |
/**
|
|
309 |
* Constructor.
|
|
310 |
*/
|
|
311 |
{
|
|
312 |
SetTestStepName(CCTSYIntegrationTestPhoneIdentity0002::GetTestStepName());
|
|
313 |
}
|
|
314 |
|
|
315 |
CCTSYIntegrationTestPhoneIdentity0002::~CCTSYIntegrationTestPhoneIdentity0002()
|
|
316 |
/**
|
|
317 |
* Destructor.
|
|
318 |
*/
|
|
319 |
{
|
|
320 |
}
|
|
321 |
|
|
322 |
TVerdict CCTSYIntegrationTestPhoneIdentity0002::doTestStepL()
|
|
323 |
/**
|
|
324 |
* @SYMTestCaseID BA-CTSY-INT-PID-0002
|
|
325 |
* @SYMFssID BA/CTSY/PID-0002
|
|
326 |
* @SYMTestCaseDesc Activate Calling Line Identification Restriction (CLIR).
|
|
327 |
* @SYMTestPriority High
|
|
328 |
* @SYMTestActions RMobilePhone::GetIdentityServiceStatus, RMobilePhone::SetIdentityServiceStatus, RMobilePhone::NotifyIdentityServiceStatus, RMobileCall::GetMobileCallInfo, RCall::Dial, RCall::HangUp
|
|
329 |
* @SYMTestExpectedResults Pass - CLIR can be activated.
|
|
330 |
* @SYMTestType CIT
|
|
331 |
* @SYMTestCaseDependencies live/manual
|
|
332 |
*
|
|
333 |
* Reason for test: Verify service status notifications complete and called party does not get the calling party's number.
|
|
334 |
*
|
|
335 |
* @return - TVerdict code
|
|
336 |
*/
|
|
337 |
{
|
|
338 |
|
|
339 |
//
|
|
340 |
// SET UP
|
|
341 |
//
|
|
342 |
|
|
343 |
// Ensure RMobilePhone::GetCallServiceCaps returns caps in set of KCapsGetClirStatus
|
|
344 |
RMobilePhone& mobilePhone = iEtelSessionMgr.GetPhoneL(KMainServer, KMainPhone);
|
|
345 |
TUint32 callServiceCaps;
|
|
346 |
|
|
347 |
CHECK_TRUE_L(mobilePhone.GetCallServiceCaps(callServiceCaps)==KErrNone, _L("RMobilePhone::GetCallServiceCaps return value is not KErrNone"));
|
|
348 |
TUint32 expectedservicecaps = RMobilePhone::KCapsGetClirStatus;
|
|
349 |
CHECK_BITS_SET_L(callServiceCaps, expectedservicecaps, KNoUnwantedBits, _L("RMobilePhone::GetCallServiceCaps returned wrong caps"));
|
|
350 |
|
|
351 |
CHECK_EQUALS_L(iNetworkTestHelper.WaitForRegisteredOnHomeNetworkL(mobilePhone), KErrNone, _L("TNetworkTsyTestHelper::WaitForRegisteredOnHomeNetworkL returned with an error"));
|
|
352 |
|
|
353 |
|
|
354 |
// Get Voice Line 1.
|
|
355 |
RMobileLine& mobileLine= iEtelSessionMgr.GetLineL(KMainServer, KMainPhone, KVoiceLine);
|
|
356 |
|
|
357 |
// Get Call 1.
|
|
358 |
RMobileCall& mobileCall= iEtelSessionMgr.GetCallL(KMainServer, KMainPhone, KVoiceLine, KCall1);
|
|
359 |
|
|
360 |
//
|
|
361 |
// SET UP END
|
|
362 |
//
|
|
363 |
|
|
364 |
StartTest();
|
|
365 |
|
|
366 |
//
|
|
367 |
// TEST START
|
|
368 |
//
|
|
369 |
|
|
370 |
|
|
371 |
// Check RMobilePhone::GetIdentityServiceStatus with aService=EIdServiceCallerRestriction and aLocation=EInfoLocationCachePreferred returns aStatus=EIdServiceActiveDefaultAllowed
|
|
372 |
RMobilePhone::TMobilePhoneIdServiceStatus idServiceStatus;
|
|
373 |
TExtEtelRequestStatus getIdentityServiceStatus(mobilePhone, EMobilePhoneGetIdentityServiceStatus);
|
|
374 |
CleanupStack::PushL(getIdentityServiceStatus);
|
|
375 |
|
|
376 |
mobilePhone.GetIdentityServiceStatus(getIdentityServiceStatus, RMobilePhone::EIdServiceCallerRestriction, idServiceStatus);
|
|
377 |
|
|
378 |
ASSERT_EQUALS(WaitForRequestWithTimeOut(getIdentityServiceStatus, ETimeMedium), KErrNone, _L("RMobilePhone::GetIdentityServiceStatus timed-out"));
|
|
379 |
ASSERT_EQUALS(getIdentityServiceStatus.Int(), KErrNone, _L("RMobilePhone::GetIdentityServiceStatus getIdentityServiceStatus completed with incorrect error"));
|
|
380 |
ASSERT_EQUALS(idServiceStatus, RMobilePhone::EIdServiceActiveDefaultAllowed, _L("RMobilePhone::GetIdentityServiceStatus idServiceStatus is not RMobilePhone::EIdServiceActiveDefaultAllowed"));
|
|
381 |
|
|
382 |
// $CTSYProblem
|
|
383 |
// The CTSY currently does not support RMobilePhone::SetIdentityServiceStatus
|
|
384 |
// so the rest of this test case is not applicable. If support is added for this API
|
|
385 |
// The rest of this test can be uncommented and used.
|
|
386 |
ERR_PRINTF1(_L("<font color=Cyan>$CTSYProblem: RMobilePhone::SetIdentityServiceStatus not supported by CTSY.<font color=Black>"));
|
|
387 |
/*
|
|
388 |
// === Activate CLIR ===
|
|
389 |
|
|
390 |
// Activate CLIR with RMobilePhone::SetIdentityServiceStatus with aService=EIdServiceCallerRestriction aSetting=EIdServicePresentationRestricted
|
|
391 |
RMobilePhone::TMobilePhoneIdService idService = RMobilePhone::EIdServiceCallerRestriction;
|
|
392 |
RMobilePhone::TMobilePhoneIdServiceStatus idServiceStateNotify;
|
|
393 |
|
|
394 |
// Post notification for RMobileCall::NotifyIdentityServiceStatus
|
|
395 |
TExtEtelRequestStatus notifyIdentityServiceStatus(mobilePhone, EMobilePhoneNotifyIdentityServiceStatus);
|
|
396 |
CleanupStack::PushL(notifyIdentityServiceStatus);
|
|
397 |
|
|
398 |
mobilePhone.NotifyIdentityServiceStatus(notifyIdentityServiceStatus, idService, idServiceStateNotify);
|
|
399 |
|
|
400 |
mobilePhone.SetIdentityServiceStatus(setIdentityServiceStatus, RMobilePhone::EIdServiceCallerRestriction, RMobilePhone::EIdServicePresentationRestricted);
|
|
401 |
|
|
402 |
ASSERT_EQUALS(WaitForRequestWithTimeOut(setIdentityServiceStatus, ETimeMedium), KErrNone, _L("RMobilePhone::SetIdentityServiceStatus timed-out"));
|
|
403 |
ASSERT_EQUALS(setIdentityServiceStatus.Int(), KErrNone, _L("RMobilePhone::SetIdentityServiceStatus setIdentityServiceStatus completed with incorrect error"));
|
|
404 |
|
|
405 |
// Check RMobilePhone::NotifyIdentityServiceStatus with aService=EIdServiceCallerRestriction completes with aStatus=EIdServiceActiveDefaultRestricted
|
|
406 |
RMobilePhone::TMobilePhoneIdService expectedService=RMobilePhone::EIdServiceCallerRestriction;
|
|
407 |
iSupplementalHelper.WaitForMobilePhoneNotifyIdentityServiceStatus(mobilePhone,
|
|
408 |
notifyIdentityServiceStatus,
|
|
409 |
idService,
|
|
410 |
expectedService,
|
|
411 |
idServiceStateNotify,
|
|
412 |
KErrNone);
|
|
413 |
|
|
414 |
// Check RMobilePhone::GetIdentityServiceStatus with aService=EIdServiceCallerRestriction and aLocation=EInfoLocationCachePreferred returns aStatus=EIdServiceActiveDefaultRestricted
|
|
415 |
mobilePhone.GetIdentityServiceStatus(getIdentityServiceStatus, RMobilePhone::EIdServiceCallerRestriction, idServiceStatus);
|
|
416 |
|
|
417 |
ASSERT_EQUALS(WaitForRequestWithTimeOut(getIdentityServiceStatus, ETimeMedium), KErrNone, _L("RMobilePhone::GetIdentityServiceStatus timed-out"));
|
|
418 |
ASSERT_EQUALS(getIdentityServiceStatus.Int(), KErrNone, _L("RMobilePhone::GetIdentityServiceStatus getIdentityServiceStatus completed with incorrect error"));
|
|
419 |
|
|
420 |
ASSERT_EQUALS(idServiceStatus, RMobilePhone::EIdServiceActiveDefaultRestricted, _L("RMobilePhone::GetIdentityServiceStatus idServiceStatus is not RMobilePhone::EIdServiceActiveDefaultAllowed"));
|
|
421 |
|
|
422 |
// === Check that caller ID is not available when CLIR is active ===
|
|
423 |
|
|
424 |
// Display a prompt to the user to telling them that they should have set their own phone number to voice number 1 in the config file
|
|
425 |
DisplayUserInteractionPromptL(_L("You should have set your own phone number to voice number 1 in the config file?"), ETimeMedium);
|
|
426 |
|
|
427 |
// Dial the user's phone number.
|
|
428 |
RMobileCall::TMobileCallStatus mobileCallState;
|
|
429 |
|
|
430 |
TExtEtelRequestStatus notifyMobileCallStatus(mobileCall, EMobileCallNotifyMobileCallStatusChange);
|
|
431 |
CleanupStack::PushL(notifyMobileCallStatus);
|
|
432 |
|
|
433 |
mobileCall.NotifyMobileCallStatusChange(notifyMobileCallStatus, mobileCallState);
|
|
434 |
|
|
435 |
TPtrC number;
|
|
436 |
ASSERT_TRUE(GetStringFromConfig(KIniVoiceNumSection, KIniVoiceNumber1, number) != EFalse, _L("GetStringFromConfig did not complete as expected"));
|
|
437 |
DEBUG_PRINTF2(_L("Board Now Dialling: %S"), &number);
|
|
438 |
TCoreEtelRequestStatus<RCall> dialStatus(mobileCall, &RCall::DialCancel);
|
|
439 |
CleanupStack::PushL(dialStatus);
|
|
440 |
mobileCall.Dial(dialStatus, number);
|
|
441 |
ASSERT_EQUALS(WaitForRequestWithTimeOut(dialStatus, ETimeMedium), KErrNone, _L("RCall::Dial timed-out"));
|
|
442 |
ASSERT_EQUALS(dialStatus.Int(), KErrNone, _L("RCall::Dial problem dialling"));
|
|
443 |
|
|
444 |
// Check RMobileCall::NotifyMobileCallStatusChange completes with EStatusConnected.
|
|
445 |
RMobileCall::TMobileCallStatus expectedMobileCallState=RMobileCall::EStatusConnected;
|
|
446 |
iCallControlHelper.WaitForMobileCallNotifyMobileCallStatusChange(mobileCall,
|
|
447 |
notifyMobileCallStatus,
|
|
448 |
mobileCallState,
|
|
449 |
expectedMobileCallState,
|
|
450 |
KErrNone);
|
|
451 |
|
|
452 |
mobileCall.NotifyMobileCallStatusChange(notifyMobileCallStatus, mobileCallState);
|
|
453 |
|
|
454 |
// User should check that they can not see the caller's number
|
|
455 |
DisplayUserInteractionPromptL(_L("User should check that they have received a phone call and should check that can not see the caller's number."), ETimeMedium);
|
|
456 |
|
|
457 |
// Hang up.
|
|
458 |
DEBUG_PRINTF1(_L("Hangup call"));
|
|
459 |
ASSERT_EQUALS(mobileCall.HangUp(), KErrNone, _L("RCall::HangUp return value not KErrNone"));
|
|
460 |
|
|
461 |
// Check RMobileCall::NotifyMobileCallStatusChange completes with EStatusIdle.
|
|
462 |
expectedMobileCallState=RMobileCall::EStatusIdle;
|
|
463 |
iCallControlHelper.WaitForMobileCallNotifyMobileCallStatusChange(mobileCall,
|
|
464 |
notifyMobileCallStatus,
|
|
465 |
mobileCallState,
|
|
466 |
expectedMobileCallState,
|
|
467 |
KErrNone);
|
|
468 |
*/
|
|
469 |
//
|
|
470 |
// TEST END
|
|
471 |
//
|
|
472 |
|
|
473 |
StartCleanup();
|
|
474 |
|
|
475 |
CleanupStack::PopAndDestroy(&getIdentityServiceStatus);
|
|
476 |
|
|
477 |
return TestStepResult();
|
|
478 |
}
|
|
479 |
|
|
480 |
TPtrC CCTSYIntegrationTestPhoneIdentity0002::GetTestStepName()
|
|
481 |
/**
|
|
482 |
* @return The test step name.
|
|
483 |
*/
|
|
484 |
{
|
|
485 |
return _L("CCTSYIntegrationTestPhoneIdentity0002");
|
|
486 |
}
|
|
487 |
|
|
488 |
|
|
489 |
|
|
490 |
CCTSYIntegrationTestPhoneIdentity0003::CCTSYIntegrationTestPhoneIdentity0003(CEtelSessionMgr& aEtelSessionMgr)
|
|
491 |
: CCTSYIntegrationTestPhoneIdentityBase(aEtelSessionMgr)
|
|
492 |
/**
|
|
493 |
* Constructor.
|
|
494 |
*/
|
|
495 |
{
|
|
496 |
SetTestStepName(CCTSYIntegrationTestPhoneIdentity0003::GetTestStepName());
|
|
497 |
}
|
|
498 |
|
|
499 |
CCTSYIntegrationTestPhoneIdentity0003::~CCTSYIntegrationTestPhoneIdentity0003()
|
|
500 |
/**
|
|
501 |
* Destructor.
|
|
502 |
*/
|
|
503 |
{
|
|
504 |
}
|
|
505 |
|
|
506 |
TVerdict CCTSYIntegrationTestPhoneIdentity0003::doTestStepL()
|
|
507 |
/**
|
|
508 |
* @SYMTestCaseID BA-CTSY-INT-PID-0003
|
|
509 |
* @SYMFssID BA/CTSY/PID-0003
|
|
510 |
* @SYMTestCaseDesc Activate Calling Line Identity Presentation (CLIP)
|
|
511 |
* @SYMTestPriority High
|
|
512 |
* @SYMTestActions RCall::AnswerIncomingCall, RMobileCall::NotifyMobileCallStatusChange, RMobilePhone::GetIdentityServiceStatus, RMobilePhone::SetIdentityServiceStatus, RMobilePhone::NotifyIdentityServiceStatus, RMobileCall::GetMobileCallInfo, RCall::HangUp
|
|
513 |
* @SYMTestExpectedResults Pass - Remote party's number retrieved correctly.
|
|
514 |
* @SYMTestType CIT
|
|
515 |
* @SYMTestCaseDependencies live/automatic
|
|
516 |
*
|
|
517 |
* Reason for test: Verify service status notifications complete and remote party information is correct.
|
|
518 |
*
|
|
519 |
* @return - TVerdict code
|
|
520 |
*/
|
|
521 |
{
|
|
522 |
|
|
523 |
//
|
|
524 |
// SET UP
|
|
525 |
//
|
|
526 |
|
|
527 |
|
|
528 |
// Ensure RMobilePhone::GetCallServiceCaps returns caps in set of KCapsGetClipStatus capability.
|
|
529 |
|
|
530 |
// Ensure RMobilePhone::GetIdentityServiceStatus with aService=EIdServiceCallerPresentation and aLocation=EInfoLocationCachePreferred does not return aStatus=EIdServiceActiveDefaultAllowed
|
|
531 |
|
|
532 |
// Get Voice Line 1
|
|
533 |
|
|
534 |
// Get Call 1
|
|
535 |
|
|
536 |
|
|
537 |
//
|
|
538 |
// SET UP END
|
|
539 |
//
|
|
540 |
|
|
541 |
StartTest();
|
|
542 |
|
|
543 |
//
|
|
544 |
// TEST START
|
|
545 |
//
|
|
546 |
|
|
547 |
|
|
548 |
// === Activate CLIP - Be able to see who is calling you - check notification completes ===
|
|
549 |
|
|
550 |
// Activate CLIP with RMobilePhone::SetIdentityServiceStatus with aService=EIdServiceCallerPresentation and aSetting=EIdServicePresentationAllowed
|
|
551 |
|
|
552 |
// Check RMobilePhone::NotifyIdentityServiceStatus with aService=EIdServiceCallerPresentation completes with aStatus=EIdServiceActivePermanent
|
|
553 |
|
|
554 |
// Check RMobilePhone::GetIdentityServiceStatus with aService=EIdServiceCallerPresentation and aLocation=EInfoLocationCachePreferred returns aStatus=EIdServiceActivePermanent
|
|
555 |
|
|
556 |
// === Request incoming call and check that the remote number can be retrieved ===
|
|
557 |
|
|
558 |
// Request an incoming call from RPS.
|
|
559 |
|
|
560 |
// Answer the call.
|
|
561 |
|
|
562 |
// Check RMobileCall::NotifyMobileCallStatusChange completes with EStatusConnected.
|
|
563 |
|
|
564 |
// Check RMobileCall::GetMobileCallInfo returns iRemoteParty.iCallingName has length > 0
|
|
565 |
// Check RMobileCall::GetMobileCallInfo returns iRemoteParty.iDirection = EMobileTerminated
|
|
566 |
// Check RMobileCall::GetMobileCallInfo returns iRemoteParty.iRemoteIdStatus = ERemoteIdentityAvailable
|
|
567 |
// Check RMobileCall::GetMobileCallInfo returns iRemoteParty.iRemoteNumber is the number RPS is calling from (coded in BCD)
|
|
568 |
// Check RMobileCall::GetMobileCallInfo returns iValid > 0.
|
|
569 |
// Check RMobileCall::GetMobileCallInfo returns data for attributes marked as valid in iValid.
|
|
570 |
|
|
571 |
// Hang up call.
|
|
572 |
|
|
573 |
|
|
574 |
//
|
|
575 |
// TEST END
|
|
576 |
//
|
|
577 |
|
|
578 |
StartCleanup();
|
|
579 |
|
|
580 |
// Put any required test clean up here, then remove this comment
|
|
581 |
|
|
582 |
return TestStepResult();
|
|
583 |
}
|
|
584 |
|
|
585 |
TPtrC CCTSYIntegrationTestPhoneIdentity0003::GetTestStepName()
|
|
586 |
/**
|
|
587 |
* @return The test step name.
|
|
588 |
*/
|
|
589 |
{
|
|
590 |
return _L("CCTSYIntegrationTestPhoneIdentity0003");
|
|
591 |
}
|
|
592 |
|
|
593 |
|
|
594 |
|
|
595 |
CCTSYIntegrationTestPhoneIdentity0004::CCTSYIntegrationTestPhoneIdentity0004(CEtelSessionMgr& aEtelSessionMgr)
|
|
596 |
: CCTSYIntegrationTestPhoneIdentityBase(aEtelSessionMgr)
|
|
597 |
/**
|
|
598 |
* Constructor.
|
|
599 |
*/
|
|
600 |
{
|
|
601 |
SetTestStepName(CCTSYIntegrationTestPhoneIdentity0004::GetTestStepName());
|
|
602 |
}
|
|
603 |
|
|
604 |
CCTSYIntegrationTestPhoneIdentity0004::~CCTSYIntegrationTestPhoneIdentity0004()
|
|
605 |
/**
|
|
606 |
* Destructor.
|
|
607 |
*/
|
|
608 |
{
|
|
609 |
}
|
|
610 |
|
|
611 |
TVerdict CCTSYIntegrationTestPhoneIdentity0004::doTestStepL()
|
|
612 |
/**
|
|
613 |
* @SYMTestCaseID BA-CTSY-INT-PID-0004
|
|
614 |
* @SYMFssID BA/CTSY/PID-0004
|
|
615 |
* @SYMTestCaseDesc Deactivate Calling Line Identity Presentation (CLIP)
|
|
616 |
* @SYMTestPriority High
|
|
617 |
* @SYMTestActions RCall::AnswerIncomingCall, RMobileCall::NotifyMobileCallStatusChange, RMobilePhone::GetIdentityServiceStatus, RMobilePhone::SetIdentityServiceStatus, RMobilePhone::NotifyIdentityServiceStatus, RMobileCall::GetMobileCallInfo, RCall::HangUp
|
|
618 |
* @SYMTestExpectedResults Pass - Remote party's number not retrieved.
|
|
619 |
* @SYMTestType CIT
|
|
620 |
* @SYMTestCaseDependencies live/automatic
|
|
621 |
*
|
|
622 |
* Reason for test: Verify service status notifications complete and it is not possible to get the calling line identity.
|
|
623 |
*
|
|
624 |
* @return - TVerdict code
|
|
625 |
*/
|
|
626 |
{
|
|
627 |
|
|
628 |
//
|
|
629 |
// SET UP
|
|
630 |
//
|
|
631 |
|
|
632 |
|
|
633 |
// Ensure RMobilePhone::GetCallServiceCaps returns caps in set of KCapsGetClipStatus capability.
|
|
634 |
|
|
635 |
// Ensure RMobilePhone::GetIdentityServiceStatus with aService=EIdServiceCallerPresentation and aLocation=EInfoLocationCachePreferred does not return aStatus=EIdServiceActiveDefaultRestricted
|
|
636 |
|
|
637 |
// Get Voice Line 1
|
|
638 |
|
|
639 |
// Get Call 1
|
|
640 |
|
|
641 |
|
|
642 |
//
|
|
643 |
// SET UP END
|
|
644 |
//
|
|
645 |
|
|
646 |
StartTest();
|
|
647 |
|
|
648 |
//
|
|
649 |
// TEST START
|
|
650 |
//
|
|
651 |
|
|
652 |
|
|
653 |
// === Deactivate (restrict) CLIP - Not be able to see who is calling you - check notification completes ===
|
|
654 |
|
|
655 |
// Deactivate CLIP with RMobilePhone::SetIdentityServiceStatus with aService=EIdServiceCallerPresentation and aSetting=EIdServicePresentationRestricted
|
|
656 |
|
|
657 |
// Check RMobilePhone::NotifyIdentityServiceStatus with aService=EIdServiceCallerPresentation completes with aStatus=EIdServiceActivePermanent
|
|
658 |
|
|
659 |
// Check RMobilePhone::GetIdentityServiceStatus with aService=EIdServiceCallerPresentation and aLocation=EInfoLocationCachePreferred returns aStatus!=EIdServiceActivePermanent
|
|
660 |
|
|
661 |
// === Request incoming call and check that the remote number can be retrieved ===
|
|
662 |
|
|
663 |
// Request an incoming call from RPS.
|
|
664 |
|
|
665 |
// Answer the call.
|
|
666 |
|
|
667 |
// Check RMobileCall::NotifyMobileCallStatusChange completes with EStatusConnected.
|
|
668 |
|
|
669 |
// Check RMobileCall::GetMobileCallInfo returns iRemoteParty.iCallingName has length > 0
|
|
670 |
// Check RMobileCall::GetMobileCallInfo returns iRemoteParty.iDirection = EMobileTerminated
|
|
671 |
// Check RMobileCall::GetMobileCallInfo returns iRemoteParty.iRemoteIdStatus = ERemoteIdentityAvailableNoCliUnavailable or = ERemoteIdentityUnavailableNoCliInteractionWithOtherService
|
|
672 |
// Check RMobileCall::GetMobileCallInfo returns iValid > 0.
|
|
673 |
// Check RMobileCall::GetMobileCallInfo returns data for attributes marked as valid in iValid.
|
|
674 |
|
|
675 |
// Hang up call.
|
|
676 |
|
|
677 |
|
|
678 |
//
|
|
679 |
// TEST END
|
|
680 |
//
|
|
681 |
|
|
682 |
StartCleanup();
|
|
683 |
|
|
684 |
// Put any required test clean up here, then remove this comment
|
|
685 |
|
|
686 |
return TestStepResult();
|
|
687 |
}
|
|
688 |
|
|
689 |
TPtrC CCTSYIntegrationTestPhoneIdentity0004::GetTestStepName()
|
|
690 |
/**
|
|
691 |
* @return The test step name.
|
|
692 |
*/
|
|
693 |
{
|
|
694 |
return _L("CCTSYIntegrationTestPhoneIdentity0004");
|
|
695 |
}
|
|
696 |
|
|
697 |
|
|
698 |
|
|
699 |
CCTSYIntegrationTestPhoneIdentity0005::CCTSYIntegrationTestPhoneIdentity0005(CEtelSessionMgr& aEtelSessionMgr)
|
|
700 |
: CCTSYIntegrationTestPhoneIdentityBase(aEtelSessionMgr)
|
|
701 |
/**
|
|
702 |
* Constructor.
|
|
703 |
*/
|
|
704 |
{
|
|
705 |
SetTestStepName(CCTSYIntegrationTestPhoneIdentity0005::GetTestStepName());
|
|
706 |
}
|
|
707 |
|
|
708 |
CCTSYIntegrationTestPhoneIdentity0005::~CCTSYIntegrationTestPhoneIdentity0005()
|
|
709 |
/**
|
|
710 |
* Destructor.
|
|
711 |
*/
|
|
712 |
{
|
|
713 |
}
|
|
714 |
|
|
715 |
TVerdict CCTSYIntegrationTestPhoneIdentity0005::doTestStepL()
|
|
716 |
/**
|
|
717 |
* @SYMTestCaseID BA-CTSY-INT-PID-0005
|
|
718 |
* @SYMFssID BA/CTSY/PID-0005
|
|
719 |
* @SYMTestCaseDesc Receive rejection of suppression of calling identity.
|
|
720 |
* @SYMTestPriority High
|
|
721 |
* @SYMTestActions RMobilePhone::SetIdentityServiceStatus, RMobilePhone::NotifyIdentitySuppressionRejected
|
|
722 |
* @SYMTestExpectedResults Pass - Notification of identity suppression rejected completes.
|
|
723 |
* @SYMTestType CIT
|
|
724 |
* @SYMTestCaseDependencies simulated/manual
|
|
725 |
*
|
|
726 |
* Reason for test: Verify notification completes.
|
|
727 |
*
|
|
728 |
* @return - TVerdict code
|
|
729 |
*/
|
|
730 |
{
|
|
731 |
|
|
732 |
//
|
|
733 |
// SET UP
|
|
734 |
//
|
|
735 |
|
|
736 |
|
|
737 |
// Ensure RMobilePhone::GetCallServiceCaps returns caps in set of KCapsGetClirStatus capability.
|
|
738 |
|
|
739 |
|
|
740 |
//
|
|
741 |
// SET UP END
|
|
742 |
//
|
|
743 |
|
|
744 |
StartTest();
|
|
745 |
|
|
746 |
//
|
|
747 |
// TEST START
|
|
748 |
//
|
|
749 |
|
|
750 |
|
|
751 |
// === Attempt to restrict caller ID ===
|
|
752 |
|
|
753 |
// Activate CLIR with RMobilePhone::SetIdentityServiceStatus with aService=EIdServiceCallerRestriction aSetting=EIdServicePresentationRestricted
|
|
754 |
|
|
755 |
// Simulator should reject CLIR activation
|
|
756 |
|
|
757 |
// Check RMobilePhone::NotifyIdentitySuppressionRejected completes with KErrNone
|
|
758 |
|
|
759 |
// Check RMobilePhone::GetIdentityServiceStatus with aService=EIdServiceCallerRestriction and aLocation=EInfoLocationCachePreferred returns aStatus!=EIdServiceActiveDefaultRestricted
|
|
760 |
|
|
761 |
|
|
762 |
//
|
|
763 |
// TEST END
|
|
764 |
//
|
|
765 |
|
|
766 |
StartCleanup();
|
|
767 |
|
|
768 |
// Put any required test clean up here, then remove this comment
|
|
769 |
|
|
770 |
return TestStepResult();
|
|
771 |
}
|
|
772 |
|
|
773 |
TPtrC CCTSYIntegrationTestPhoneIdentity0005::GetTestStepName()
|
|
774 |
/**
|
|
775 |
* @return The test step name.
|
|
776 |
*/
|
|
777 |
{
|
|
778 |
return _L("CCTSYIntegrationTestPhoneIdentity0005");
|
|
779 |
}
|
|
780 |
|
|
781 |
|
|
782 |
|
|
783 |
CCTSYIntegrationTestPhoneIdentity0006::CCTSYIntegrationTestPhoneIdentity0006(CEtelSessionMgr& aEtelSessionMgr)
|
|
784 |
: CCTSYIntegrationTestPhoneIdentityBase(aEtelSessionMgr)
|
|
785 |
/**
|
|
786 |
* Constructor.
|
|
787 |
*/
|
|
788 |
{
|
|
789 |
SetTestStepName(CCTSYIntegrationTestPhoneIdentity0006::GetTestStepName());
|
|
790 |
}
|
|
791 |
|
|
792 |
CCTSYIntegrationTestPhoneIdentity0006::~CCTSYIntegrationTestPhoneIdentity0006()
|
|
793 |
/**
|
|
794 |
* Destructor.
|
|
795 |
*/
|
|
796 |
{
|
|
797 |
}
|
|
798 |
|
|
799 |
TVerdict CCTSYIntegrationTestPhoneIdentity0006::doTestStepL()
|
|
800 |
/**
|
|
801 |
* @SYMTestCaseID BA-CTSY-INT-PID-0006
|
|
802 |
* @SYMFssID BA/CTSY/PID-0006
|
|
803 |
* @SYMTestCaseDesc Activate and deactivate CNAP (calling name presentation)
|
|
804 |
* @SYMTestPriority High
|
|
805 |
* @SYMTestActions RMobilePhone::SetIdentityServiceStatus, RMobilePhone::NotifyIdentityServiceStatus
|
|
806 |
* @SYMTestExpectedResults Pass - Identity service status notification completes and service status is correct.
|
|
807 |
* @SYMTestType CIT
|
|
808 |
* @SYMTestCaseDependencies live/automatic
|
|
809 |
*
|
|
810 |
* Reason for test: Verify notification completes and identity status is correct.
|
|
811 |
*
|
|
812 |
* @return - TVerdict code
|
|
813 |
*/
|
|
814 |
{
|
|
815 |
|
|
816 |
//
|
|
817 |
// SET UP
|
|
818 |
//
|
|
819 |
|
|
820 |
|
|
821 |
// Ensure RMobilePhone::GetCallServiceCaps returns caps in set of KCapsGetCnapStatus capability.
|
|
822 |
|
|
823 |
// Ensure RMobilePhone::GetIdentityServiceStatus with aService=EIdServiceCallerName and aLocation=EInfoLocationCachePreferred returns aStatus!=EIdServiceActivePermanent
|
|
824 |
|
|
825 |
|
|
826 |
//
|
|
827 |
// SET UP END
|
|
828 |
//
|
|
829 |
|
|
830 |
StartTest();
|
|
831 |
|
|
832 |
//
|
|
833 |
// TEST START
|
|
834 |
//
|
|
835 |
|
|
836 |
|
|
837 |
// === Activate CNAP ===
|
|
838 |
|
|
839 |
// Activate CNAP with RMobilePhone::SetIdentityServiceStatus with aService=EIdServiceCallerName and aSetting=EIdServicePresentationRestricted
|
|
840 |
|
|
841 |
// Check RMobilePhone::NotifyIdentityServiceStatus with aService=EIdServiceCallerName completes with aStatus=EIdServicePresentationRestricted
|
|
842 |
|
|
843 |
// Check RMobilePhone::GetIdentityServiceStatus with aService=EIdServiceCallerName and aLocation=EInfoLocationCachePreferred returns aStatus=EIdServiceActivePermanent
|
|
844 |
|
|
845 |
// === Deactivate CNAP ===
|
|
846 |
|
|
847 |
// Deactivate CNAP with RMobilePhone::SetIdentityServiceStatus with aService=EIdServiceCallerName and aSetting=EIdServicePresentationAllowed
|
|
848 |
|
|
849 |
// Check RMobilePhone::NotifyIdentityServiceStatus with aService=EIdServiceCallerName completes with aStatus=EIdServicePresentationAllowed
|
|
850 |
|
|
851 |
// Check RMobilePhone::GetIdentityServiceStatus with aService=EIdServiceCallerName and aLocation=EInfoLocationCachePreferred returns aStatus!=EIdServiceActivePermanent
|
|
852 |
|
|
853 |
|
|
854 |
//
|
|
855 |
// TEST END
|
|
856 |
//
|
|
857 |
|
|
858 |
StartCleanup();
|
|
859 |
|
|
860 |
// Put any required test clean up here, then remove this comment
|
|
861 |
|
|
862 |
return TestStepResult();
|
|
863 |
}
|
|
864 |
|
|
865 |
TPtrC CCTSYIntegrationTestPhoneIdentity0006::GetTestStepName()
|
|
866 |
/**
|
|
867 |
* @return The test step name.
|
|
868 |
*/
|
|
869 |
{
|
|
870 |
return _L("CCTSYIntegrationTestPhoneIdentity0006");
|
|
871 |
}
|
|
872 |
|
|
873 |
|
|
874 |
|
|
875 |
CCTSYIntegrationTestPhoneIdentity0007::CCTSYIntegrationTestPhoneIdentity0007(CEtelSessionMgr& aEtelSessionMgr)
|
|
876 |
: CCTSYIntegrationTestPhoneIdentityBase(aEtelSessionMgr)
|
|
877 |
/**
|
|
878 |
* Constructor.
|
|
879 |
*/
|
|
880 |
{
|
|
881 |
SetTestStepName(CCTSYIntegrationTestPhoneIdentity0007::GetTestStepName());
|
|
882 |
}
|
|
883 |
|
|
884 |
CCTSYIntegrationTestPhoneIdentity0007::~CCTSYIntegrationTestPhoneIdentity0007()
|
|
885 |
/**
|
|
886 |
* Destructor.
|
|
887 |
*/
|
|
888 |
{
|
|
889 |
}
|
|
890 |
|
|
891 |
TVerdict CCTSYIntegrationTestPhoneIdentity0007::doTestStepL()
|
|
892 |
/**
|
|
893 |
* @SYMTestCaseID BA-CTSY-INT-PID-0007
|
|
894 |
* @SYMFssID BA/CTSY/PID-0007
|
|
895 |
* @SYMTestCaseDesc Get subscriber ID (IMSI) when no SIM present.
|
|
896 |
* @SYMTestPriority High
|
|
897 |
* @SYMTestActions RMobileCall::GetSubscriberId
|
|
898 |
* @SYMTestExpectedResults Pass - Error returned on attempt to get IMSI with no SIM.
|
|
899 |
* @SYMTestType CIT
|
|
900 |
* @SYMTestCaseDependencies live/manual
|
|
901 |
*
|
|
902 |
* Reason for test: Verify IMSI retrieval fails.
|
|
903 |
*
|
|
904 |
* @return - TVerdict code
|
|
905 |
*/
|
|
906 |
{
|
|
907 |
|
|
908 |
//
|
|
909 |
// SET UP
|
|
910 |
//
|
|
911 |
|
|
912 |
RMobilePhone& mobilePhone = iEtelSessionMgr.GetPhoneL(KMainServer, KMainPhone);
|
|
913 |
|
|
914 |
//
|
|
915 |
// SET UP END
|
|
916 |
//
|
|
917 |
|
|
918 |
StartTest();
|
|
919 |
|
|
920 |
//
|
|
921 |
// TEST START
|
|
922 |
//
|
|
923 |
|
|
924 |
|
|
925 |
// Remove the SIM.
|
|
926 |
TBuf<100> prompt(_L("Ensure SIM is not present"));
|
|
927 |
DisplayUserInteractionPromptL(prompt); // 30 seconds
|
|
928 |
|
|
929 |
// Check RMobilePhone::GetSubscriberId completes with error != KErrNone
|
|
930 |
TExtEtelRequestStatus getSubscriberIdStatus(mobilePhone, EMobilePhoneGetSubscriberId);
|
|
931 |
RMobilePhone::TMobilePhoneSubscriberId subscriberId;
|
|
932 |
CleanupStack::PushL(getSubscriberIdStatus);
|
|
933 |
|
|
934 |
mobilePhone.GetSubscriberId(getSubscriberIdStatus,subscriberId);
|
|
935 |
|
|
936 |
ASSERT_EQUALS(WaitForRequestWithTimeOut(getSubscriberIdStatus, ETimeShort), KErrNone, _L("RMobilePhone::GetSubscriberId timed-out"));
|
|
937 |
ASSERT_TRUE(getSubscriberIdStatus.Int() != KErrNone, _L("RMobilePhone::getSubscriberIdStatus returned with an error"));
|
|
938 |
|
|
939 |
//
|
|
940 |
// TEST END
|
|
941 |
//
|
|
942 |
|
|
943 |
StartCleanup();
|
|
944 |
|
|
945 |
CleanupStack::PopAndDestroy(&getSubscriberIdStatus);
|
|
946 |
|
|
947 |
return TestStepResult();
|
|
948 |
}
|
|
949 |
|
|
950 |
TPtrC CCTSYIntegrationTestPhoneIdentity0007::GetTestStepName()
|
|
951 |
/**
|
|
952 |
* @return The test step name.
|
|
953 |
*/
|
|
954 |
{
|
|
955 |
return _L("CCTSYIntegrationTestPhoneIdentity0007");
|
|
956 |
}
|
|
957 |
|
|
958 |
|
|
959 |
|
|
960 |
CCTSYIntegrationTestPhoneIdentity0008::CCTSYIntegrationTestPhoneIdentity0008(CEtelSessionMgr& aEtelSessionMgr)
|
|
961 |
: CCTSYIntegrationTestPhoneIdentityBase(aEtelSessionMgr)
|
|
962 |
/**
|
|
963 |
* Constructor.
|
|
964 |
*/
|
|
965 |
{
|
|
966 |
SetTestStepName(CCTSYIntegrationTestPhoneIdentity0008::GetTestStepName());
|
|
967 |
}
|
|
968 |
|
|
969 |
CCTSYIntegrationTestPhoneIdentity0008::~CCTSYIntegrationTestPhoneIdentity0008()
|
|
970 |
/**
|
|
971 |
* Destructor.
|
|
972 |
*/
|
|
973 |
{
|
|
974 |
}
|
|
975 |
|
|
976 |
TVerdict CCTSYIntegrationTestPhoneIdentity0008::doTestStepL()
|
|
977 |
/**
|
|
978 |
* @SYMTestCaseID BA-CTSY-INT-PID-0008
|
|
979 |
* @SYMFssID BA/CTSY/PID-0008
|
|
980 |
* @SYMTestCaseDesc Activate and deactivate COLP (connected line identification presentation)
|
|
981 |
* @SYMTestPriority High
|
|
982 |
* @SYMTestActions RMobilePhone::SetIdentityServiceStatus, RMobilePhone::NotifyIdentityServiceStatus
|
|
983 |
* @SYMTestExpectedResults Pass - Identity service status notification completes and service status is correct.
|
|
984 |
* @SYMTestType CIT
|
|
985 |
* @SYMTestCaseDependencies live/automatic
|
|
986 |
*
|
|
987 |
* Reason for test: Verify notification completes and identity status is correct.
|
|
988 |
*
|
|
989 |
* @return - TVerdict code
|
|
990 |
*/
|
|
991 |
{
|
|
992 |
|
|
993 |
//
|
|
994 |
// SET UP
|
|
995 |
//
|
|
996 |
|
|
997 |
|
|
998 |
// Ensure RMobilePhone::GetCallServiceCaps returns caps in set of KCapsGetColpStatus
|
|
999 |
|
|
1000 |
// Ensure RMobilePhone::GetIdentityServiceStatus with aService=EIdServiceConnectedPresentation and aLocation=EInfoLocationCachePreferred returns aStatus!=EIdServiceActivePermanent
|
|
1001 |
|
|
1002 |
|
|
1003 |
//
|
|
1004 |
// SET UP END
|
|
1005 |
//
|
|
1006 |
|
|
1007 |
StartTest();
|
|
1008 |
|
|
1009 |
//
|
|
1010 |
// TEST START
|
|
1011 |
//
|
|
1012 |
|
|
1013 |
|
|
1014 |
// === Activate COLP ===
|
|
1015 |
|
|
1016 |
// Activate COLP with RMobilePhone::SetIdentityServiceStatus with aService=EIdServiceConnectedPresentation and aSetting=EIdServicePresentationRestricted
|
|
1017 |
|
|
1018 |
// Check RMobilePhone::NotifyIdentityServiceStatus with aService=EIdServiceConnectedPresentation completes with aStatus=EIdServicePresentationRestricted
|
|
1019 |
|
|
1020 |
// Check RMobilePhone::GetIdentityServiceStatus with aService=EIdServiceConnectedPresentation and aLocation=EInfoLocationCachePreferred returns aStatus=EIdServiceActivePermanent
|
|
1021 |
|
|
1022 |
// === Deactivate COLP ===
|
|
1023 |
|
|
1024 |
// Deactivate COLP with RMobilePhone::SetIdentityServiceStatus with aService=EIdServiceConnectedPresentation and aSetting=EIdServicePresentationAllowed
|
|
1025 |
|
|
1026 |
// Check RMobilePhone::NotifyIdentityServiceStatus with aService=EIdServiceConnectedPresentation completes with aStatus=EIdServicePresentationAllowed
|
|
1027 |
|
|
1028 |
// Check RMobilePhone::GetIdentityServiceStatus with aService=EIdServiceConnectedPresentation and aLocation=EInfoLocationCachePreferred returns aStatus!=EIdServiceActivePermanent
|
|
1029 |
|
|
1030 |
|
|
1031 |
//
|
|
1032 |
// TEST END
|
|
1033 |
//
|
|
1034 |
|
|
1035 |
StartCleanup();
|
|
1036 |
|
|
1037 |
// Put any required test clean up here, then remove this comment
|
|
1038 |
|
|
1039 |
return TestStepResult();
|
|
1040 |
}
|
|
1041 |
|
|
1042 |
TPtrC CCTSYIntegrationTestPhoneIdentity0008::GetTestStepName()
|
|
1043 |
/**
|
|
1044 |
* @return The test step name.
|
|
1045 |
*/
|
|
1046 |
{
|
|
1047 |
return _L("CCTSYIntegrationTestPhoneIdentity0008");
|
|
1048 |
}
|
|
1049 |
|
|
1050 |
|
|
1051 |
|
|
1052 |
CCTSYIntegrationTestPhoneIdentity0009::CCTSYIntegrationTestPhoneIdentity0009(CEtelSessionMgr& aEtelSessionMgr)
|
|
1053 |
: CCTSYIntegrationTestPhoneIdentityBase(aEtelSessionMgr)
|
|
1054 |
/**
|
|
1055 |
* Constructor.
|
|
1056 |
*/
|
|
1057 |
{
|
|
1058 |
SetTestStepName(CCTSYIntegrationTestPhoneIdentity0009::GetTestStepName());
|
|
1059 |
}
|
|
1060 |
|
|
1061 |
CCTSYIntegrationTestPhoneIdentity0009::~CCTSYIntegrationTestPhoneIdentity0009()
|
|
1062 |
/**
|
|
1063 |
* Destructor.
|
|
1064 |
*/
|
|
1065 |
{
|
|
1066 |
}
|
|
1067 |
|
|
1068 |
TVerdict CCTSYIntegrationTestPhoneIdentity0009::doTestStepL()
|
|
1069 |
/**
|
|
1070 |
* @SYMTestCaseID BA-CTSY-INT-PID-0009
|
|
1071 |
* @SYMFssID BA/CTSY/PID-0009
|
|
1072 |
* @SYMTestCaseDesc Activate and deactivate COLR (connected line identity restriction)
|
|
1073 |
* @SYMTestPriority High
|
|
1074 |
* @SYMTestActions
|
|
1075 |
* @SYMTestExpectedResults Pass - COLR activated and deactivated.
|
|
1076 |
* @SYMTestType CIT
|
|
1077 |
* @SYMTestCaseDependencies live/automatic
|
|
1078 |
*
|
|
1079 |
* Reason for test: Verify notification completes and identity status is correct.
|
|
1080 |
*
|
|
1081 |
* @return - TVerdict code
|
|
1082 |
*/
|
|
1083 |
{
|
|
1084 |
|
|
1085 |
//
|
|
1086 |
// SET UP
|
|
1087 |
//
|
|
1088 |
|
|
1089 |
|
|
1090 |
// Ensure RMobilePhone::GetCallServiceCaps returns caps in set of KCapsGetColrStatus
|
|
1091 |
|
|
1092 |
// Ensure RMobilePhone::GetIdentityServiceStatus with aService=EIdServiceConnectedRestriction and aLocation=EInfoLocationCachePreferred returns aStatus!=EIdServiceActivePermanent
|
|
1093 |
|
|
1094 |
|
|
1095 |
//
|
|
1096 |
// SET UP END
|
|
1097 |
//
|
|
1098 |
|
|
1099 |
StartTest();
|
|
1100 |
|
|
1101 |
//
|
|
1102 |
// TEST START
|
|
1103 |
//
|
|
1104 |
|
|
1105 |
|
|
1106 |
// === Activate COLR ===
|
|
1107 |
|
|
1108 |
// Activate COLR with RMobilePhone::SetIdentityServiceStatus with aService=EIdServiceConnectedRestriction and aSetting=EIdServicePresentationRestricted
|
|
1109 |
|
|
1110 |
// Check RMobilePhone::NotifyIdentityServiceStatus with aService=EIdServiceConnectedRestriction completes with aStatus=EIdServicePresentationRestricted
|
|
1111 |
|
|
1112 |
// Check RMobilePhone::GetIdentityServiceStatus with aService=EIdServiceConnectedRestriction and aLocation=EInfoLocationCachePreferred returns aStatus=EIdServiceActivePermanent
|
|
1113 |
|
|
1114 |
// === Deactivate COLR ===
|
|
1115 |
|
|
1116 |
// Deactivate COLR with RMobilePhone::SetIdentityServiceStatus with aService=EIdServiceConnectedRestriction and aSetting=EIdServicePresentationAllowed
|
|
1117 |
|
|
1118 |
// Check RMobilePhone::NotifyIdentityServiceStatus with aService=EIdServiceConnectedRestriction completes with aStatus=EIdServicePresentationAllowed
|
|
1119 |
|
|
1120 |
// Check RMobilePhone::GetIdentityServiceStatus with aService=EIdServiceConnectedRestriction and aLocation=EInfoLocationCachePreferred returns aStatus!=EIdServiceActivePermanent
|
|
1121 |
|
|
1122 |
|
|
1123 |
//
|
|
1124 |
// TEST END
|
|
1125 |
//
|
|
1126 |
|
|
1127 |
StartCleanup();
|
|
1128 |
|
|
1129 |
// Put any required test clean up here, then remove this comment
|
|
1130 |
|
|
1131 |
return TestStepResult();
|
|
1132 |
}
|
|
1133 |
|
|
1134 |
TPtrC CCTSYIntegrationTestPhoneIdentity0009::GetTestStepName()
|
|
1135 |
/**
|
|
1136 |
* @return The test step name.
|
|
1137 |
*/
|
|
1138 |
{
|
|
1139 |
return _L("CCTSYIntegrationTestPhoneIdentity0009");
|
|
1140 |
}
|
|
1141 |
|
|
1142 |
|
|
1143 |
|
|
1144 |
CCTSYIntegrationTestPhoneIdentity0010::CCTSYIntegrationTestPhoneIdentity0010(CEtelSessionMgr& aEtelSessionMgr)
|
|
1145 |
: CCTSYIntegrationTestPhoneIdentityBase(aEtelSessionMgr)
|
|
1146 |
/**
|
|
1147 |
* Constructor.
|
|
1148 |
*/
|
|
1149 |
{
|
|
1150 |
SetTestStepName(CCTSYIntegrationTestPhoneIdentity0010::GetTestStepName());
|
|
1151 |
}
|
|
1152 |
|
|
1153 |
CCTSYIntegrationTestPhoneIdentity0010::~CCTSYIntegrationTestPhoneIdentity0010()
|
|
1154 |
/**
|
|
1155 |
* Destructor.
|
|
1156 |
*/
|
|
1157 |
{
|
|
1158 |
}
|
|
1159 |
|
|
1160 |
TVerdict CCTSYIntegrationTestPhoneIdentity0010::doTestStepL()
|
|
1161 |
/**
|
|
1162 |
* @SYMTestCaseID BA-CTSY-INT-PID-0010
|
|
1163 |
* @SYMFssID BA/CTSY/PID-0010
|
|
1164 |
* @SYMTestCaseDesc Get the phone identity
|
|
1165 |
* @SYMTestPriority High
|
|
1166 |
* @SYMTestActions
|
|
1167 |
* @SYMTestExpectedResults Pass - Phone manufacturer, model, revision and serial number returned.
|
|
1168 |
* @SYMTestType CIT
|
|
1169 |
* @SYMTestCaseDependencies live/automatic
|
|
1170 |
*
|
|
1171 |
* Reason for test: Verify manufacturer, model, revision and serial number returned.
|
|
1172 |
*
|
|
1173 |
* @return - TVerdict code
|
|
1174 |
*/
|
|
1175 |
{
|
|
1176 |
|
|
1177 |
//
|
|
1178 |
// SET UP
|
|
1179 |
//
|
|
1180 |
|
|
1181 |
RMobilePhone& phone = iEtelSessionMgr.GetPhoneL(KMainServer, KMainPhone);
|
|
1182 |
|
|
1183 |
// EnsureRMobilePhone::GetIdentityCaps returns caps in set of
|
|
1184 |
// RMobilePhone::KCapsGetManufacturer | RMobilePhone::KCapsGetModel | RMobilePhone::KCapsGetRevision |
|
|
1185 |
// RMobilePhone::KCapsGetSerialNumber
|
|
1186 |
|
|
1187 |
TUint32 caps;
|
|
1188 |
TInt result = phone.GetIdentityCaps(caps);
|
|
1189 |
CHECK_TRUE_L(result == KErrNone, _L("RMobilePhone::GetIdentityCaps failed."))
|
|
1190 |
|
|
1191 |
// Needs all caps
|
|
1192 |
TUint neededCaps = RMobilePhone::KCapsGetManufacturer | RMobilePhone::KCapsGetModel |
|
|
1193 |
RMobilePhone::KCapsGetRevision | RMobilePhone::KCapsGetSerialNumber;
|
|
1194 |
CHECK_BITS_SET_L( caps, neededCaps, KNoUnwantedBits, _L("RMobilePhone::GetIdentityCaps returned wrong mask") )
|
|
1195 |
//
|
|
1196 |
// SET UP END
|
|
1197 |
//
|
|
1198 |
|
|
1199 |
StartTest();
|
|
1200 |
|
|
1201 |
//
|
|
1202 |
// TEST START
|
|
1203 |
//
|
|
1204 |
|
|
1205 |
|
|
1206 |
// === Get the phone identity ===
|
|
1207 |
RMobilePhone::TMobilePhoneIdentityV1 phoneId;
|
|
1208 |
TExtEtelRequestStatus requestStatus(phone, EMobilePhoneGetPhoneId);
|
|
1209 |
CleanupStack::PushL(requestStatus);
|
|
1210 |
phone.GetPhoneId(requestStatus, phoneId);
|
|
1211 |
|
|
1212 |
ASSERT_EQUALS(WaitForRequestWithTimeOut(requestStatus, ETimeLong),
|
|
1213 |
KErrNone, _L("RMobilePhone::GetPhoneId timed out."))
|
|
1214 |
ASSERT_EQUALS(requestStatus.Int(), KErrNone, _L("RMobilePhone::GetPhoneId completed with incorrect status"))
|
|
1215 |
|
|
1216 |
// Check RMobilePhone::GetPhoneId returns aId.iManufacturer with length > 0
|
|
1217 |
ASSERT_TRUE(phoneId.iManufacturer.Length() > 0,
|
|
1218 |
_L("RMobilePhone::GetPhoneId returned invalid manufacturer"))
|
|
1219 |
|
|
1220 |
// Check RMobilePhone::GetPhoneId returns aId.iModel with length > 0
|
|
1221 |
ASSERT_TRUE(phoneId.iModel.Length() > 0,
|
|
1222 |
_L("RMobilePhone::GetPhoneId returned invalid model"))
|
|
1223 |
|
|
1224 |
// Check RMobilePhone::GetPhoneId returns aId.iRevision with length > 0
|
|
1225 |
ASSERT_TRUE(phoneId.iRevision.Length() > 0,
|
|
1226 |
_L("RMobilePhone::GetPhoneId returned invalid revision"))
|
|
1227 |
|
|
1228 |
// Check RMobilePhone::GetPhoneId returns aId.iSerialNumber with length > 0
|
|
1229 |
ASSERT_TRUE(phoneId.iSerialNumber.Length() > 0,
|
|
1230 |
_L("RMobilePhone::GetPhoneId returned invalid serial number"))
|
|
1231 |
|
|
1232 |
|
|
1233 |
//
|
|
1234 |
// TEST END
|
|
1235 |
//
|
|
1236 |
|
|
1237 |
StartCleanup();
|
|
1238 |
|
|
1239 |
CleanupStack::Pop(); // requestStatus
|
|
1240 |
|
|
1241 |
return TestStepResult();
|
|
1242 |
}
|
|
1243 |
|
|
1244 |
|
|
1245 |
TPtrC CCTSYIntegrationTestPhoneIdentity0010::GetTestStepName()
|
|
1246 |
/**
|
|
1247 |
* @return The test step name.
|
|
1248 |
*/
|
|
1249 |
{
|
|
1250 |
return _L("CCTSYIntegrationTestPhoneIdentity0010");
|
|
1251 |
}
|
|
1252 |
|
|
1253 |
|
|
1254 |
|