|
1 // Copyright (c) 2006-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 // @file CT_LbsClientStep.h |
|
15 // This contains the header file for LBS Client Test Step Base |
|
16 // |
|
17 // |
|
18 |
|
19 #ifndef __CT_LBS_CLIENT_STEP_H__ |
|
20 #define __CT_LBS_CLIENT_STEP_H__ |
|
21 |
|
22 #include <test/testexecutestepbase.h> |
|
23 #include <lbs.h> |
|
24 #include <lbs/test/lbsnetsimtest.h> |
|
25 |
|
26 #include "ctlbsclientserver.h" |
|
27 #include "ctlbscommon.h" |
|
28 |
|
29 //todo: is this a sensible place to put this as it's used by many teststeps? |
|
30 const TTimeIntervalMicroSeconds32 delay10Seconds = 10000000; |
|
31 |
|
32 |
|
33 class CT_LbsClientStep : public CTestStep |
|
34 { |
|
35 |
|
36 public: |
|
37 virtual ~CT_LbsClientStep(); |
|
38 |
|
39 virtual TVerdict doTestStepPreambleL(); |
|
40 virtual TVerdict doTestStepPostambleL(); |
|
41 |
|
42 protected: |
|
43 CT_LbsClientStep(CT_LbsClientServer& aParent); |
|
44 |
|
45 |
|
46 // Carryout a notify position update. |
|
47 // Must have a connect server, and a open positioner |
|
48 // also the pos info array is appened to |
|
49 TInt DoNotifyUpdateL(TPositionInfoBase& aPosInfo); |
|
50 |
|
51 TInt DoLastKnownPosL(TPositionInfoBase& aPosInfo); |
|
52 |
|
53 TInt OpenNetSim(); |
|
54 void SendResetAssistanceData(TLbsAssistanceDataGroup aMask); |
|
55 void CloseNetSim(); |
|
56 |
|
57 CT_LbsClientServer& iParent; |
|
58 |
|
59 RPositionServer iServer; |
|
60 RPositioner iPositioner; |
|
61 |
|
62 /** Net sim required for tests which invoke assistance data via AGPS module. */ |
|
63 RLbsNetSimTest iNetSim; |
|
64 |
|
65 /** Reference position used to setup Net sim and later verification. */ |
|
66 TPosition iRefPos; |
|
67 |
|
68 |
|
69 private: |
|
70 /** |
|
71 Position call types - used by GetLocation() to determine which position update function to call |
|
72 |
|
73 */ |
|
74 enum _TPositionUpdateType |
|
75 { |
|
76 /** EDoNotifyPosUpdate - call NotifyPositionUpdate */ |
|
77 EDoNotifyPosUpdate = 0, |
|
78 /** EDoLastKnownPos - call GetLastKnownPosition */ |
|
79 EDoLastKnownPos = 0x01, |
|
80 }; |
|
81 |
|
82 TInt GetLocationL(TPositionInfoBase& aPosInfo, TUint32 aNotifyCallType); |
|
83 |
|
84 protected: |
|
85 TExpectedApiBehaviour iExpectedApiBehaviour; |
|
86 |
|
87 }; |
|
88 |
|
89 #endif // __CT_LBS_CLIENT_STEP_H__ |