|
1 // Copyright (c) 2008-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 // Example CTestStep derived implementation |
|
15 // |
|
16 // |
|
17 |
|
18 /** |
|
19 @file TwoInternalGpsPsyStep.cpp |
|
20 @internalTechnology |
|
21 */ |
|
22 #include "TwoInternalGpsPsyStep.h" |
|
23 #include "Te_defproxySuiteDefs.h" |
|
24 |
|
25 CTwoInternalGpsPsyStep::~CTwoInternalGpsPsyStep() |
|
26 /** |
|
27 * Destructor |
|
28 */ |
|
29 { |
|
30 } |
|
31 |
|
32 CTwoInternalGpsPsyStep::CTwoInternalGpsPsyStep() |
|
33 /** |
|
34 * Constructor |
|
35 */ |
|
36 { |
|
37 SetTestStepName(KTwoInternalGpsPsyStep); |
|
38 } |
|
39 |
|
40 TVerdict CTwoInternalGpsPsyStep::doTestStepPreambleL() |
|
41 /** |
|
42 * @return - TVerdict code |
|
43 * Override of base class virtual |
|
44 */ |
|
45 { |
|
46 CTe_defproxySuiteStepBase::doTestStepPreambleL(); |
|
47 SetTestStepResult(EPass); |
|
48 return TestStepResult(); |
|
49 } |
|
50 |
|
51 |
|
52 TVerdict CTwoInternalGpsPsyStep::doTestStepL() |
|
53 /** |
|
54 * @return - TVerdict code |
|
55 * Override of base class pure virtual |
|
56 * Our implementation only gets called if the base class doTestStepPreambleL() did |
|
57 * not leave. That being the case, the current test result value will be EPass. |
|
58 */ |
|
59 { |
|
60 StandardPrepareL(); |
|
61 TRequestStatus status; |
|
62 TPositionInfo posInfo; |
|
63 TPositionUpdateOptions options; |
|
64 |
|
65 |
|
66 //1. |
|
67 InitPsySettingsL(3, |
|
68 KIntGpsPsy1, 1, |
|
69 KIntGpsPsy2, 1, |
|
70 KNetworkPsy1, 1); |
|
71 |
|
72 //2. |
|
73 SET_TIME |
|
74 PositionRequestWithCheck(posInfo, KErrNone, KIntGpsPsy1); |
|
75 CHECK_TIME(0) |
|
76 |
|
77 |
|
78 //3. |
|
79 InitPsySettingsL(3, |
|
80 KIntGpsPsy1, 1, |
|
81 KIntGpsPsy2, 0, |
|
82 KNetworkPsy1, 0); |
|
83 |
|
84 //4. |
|
85 SET_TIME |
|
86 PositionRequestWithCheck(posInfo, KErrNone, KIntGpsPsy1); |
|
87 CHECK_TIME(0) |
|
88 |
|
89 //5. |
|
90 InitPsySettingsL(3, |
|
91 KIntGpsPsy1, 0, |
|
92 KIntGpsPsy2, 1, |
|
93 KNetworkPsy1, 0); |
|
94 |
|
95 //6. |
|
96 SET_TIME |
|
97 PositionRequestWithCheck(posInfo, KErrNone, KIntGpsPsy2); |
|
98 CHECK_TIME(0) |
|
99 |
|
100 //7. |
|
101 InitPsySettingsL(3, |
|
102 KIntGpsPsy1, 1, |
|
103 KIntGpsPsy2, 1, |
|
104 KNetworkPsy1, 0); |
|
105 |
|
106 //8. |
|
107 SET_TIME |
|
108 PositionRequestWithCheck(posInfo, KErrNone, KIntGpsPsy1); |
|
109 CHECK_TIME(0) |
|
110 |
|
111 //9. |
|
112 InitPsySettingsL(3, |
|
113 KIntGpsPsy1, 0, |
|
114 KIntGpsPsy2, 1, |
|
115 KNetworkPsy1, 1); |
|
116 |
|
117 //10. |
|
118 SET_TIME |
|
119 PositionRequestWithCheck(posInfo, KErrNone, KIntGpsPsy2); |
|
120 CHECK_TIME(0) |
|
121 |
|
122 //Unload default proxy and all PSYs |
|
123 //CLOSE_AND_OPEN_POSITIONER |
|
124 |
|
125 |
|
126 // cleanup |
|
127 StandardCleanup(); |
|
128 return TestStepResult(); |
|
129 } |
|
130 |
|
131 |
|
132 |
|
133 TVerdict CTwoInternalGpsPsyStep::doTestStepPostambleL() |
|
134 /** |
|
135 * @return - TVerdict code |
|
136 * Override of base class virtual |
|
137 */ |
|
138 { |
|
139 CTe_defproxySuiteStepBase::doTestStepPostambleL(); |
|
140 return TestStepResult(); |
|
141 } |