summaryrefslogtreecommitdiffstats
path: root/plugins/contacts/symbian/contactsmodel/tsrc/integration/teststartup/scripts/testcontactsstartupsuite.script
blob: 993f678584a90d44197e79f474b791cc7d4f7a90 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
//
// Copyright (C) 2012 Digia Plc and/or its subsidiary(-ies).
// All rights reserved.
// This component and the accompanying materials are made available
// under the terms of "Eclipse Public License v1.0"
// which accompanies this distribution, and is available
// at the URL "http://www.eclipse.org/legal/epl-v10.html".
//
// Initial Contributors:
// Nokia Corporation - initial contribution.
//
// Contributors:
//
// Description: 
//

LOAD_SUITE TestStartUpSuite -sharedData

START_TESTCASE PIM-APPENG-CNTS-TestStartUpSuite-1192-0001
//! @file
//! @SYMTestCaseID PIM-APPENG-CNTS-TestStartUpSuite-1192-0001
//! @SYMTestType CIT
//! @SYMTestPriority High
//! @SYMPREQ 1192
//! @SYMFssID App-Engines>/<CntModel>/ CP.1
//! @SYMTestStatus Implemented
//! @SYMTestCaseDesc Contacts start-up with valid database and valid default start-up view definitions
//! @SYMTestActions Create a default db if one doesnt exist, launch the contacts server, check the view settings
//! @SYMTestExpectedResults A named remote contact view has been created based on the default view settings stored in central repository

RUN_TEST_STEP 100 TestStartUpSuite TestCntsDbStep              c:\test\data\StartUpData.ini create_default_cnts_db
RUN_TEST_STEP 100 TestStartUpSuite TestCntsDbStep              c:\test\data\StartUpData.ini add_20_contacts_to_default_db
DELAY 6000
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep          c:\test\data\StartUpData.ini launch_cnts_server
DELAY 5000
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep          c:\test\data\StartUpData.ini check_cnts_server_is_ok
RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep   c:\test\data\StartUpData.ini initial_view_settings_in_centralrep_ROM
RUN_TEST_STEP 100 TestStartUpSuite TestCntsDbStep              c:\test\data\StartUpData.ini initial_view_settings_in_centralrep_ROM
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep          c:\test\data\StartUpData.ini terminate_cnts_server
DELAY 5000
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep          c:\test\data\StartUpData.ini check_cnts_server_has_terminated_ok
END_TESTCASE PIM-APPENG-CNTS-TestStartUpSuite-1192-0001




START_TESTCASE PIM-APPENG-CNTS-TestStartUpSuite-1192-0002
//! @file
//! @SYMTestCaseID PIM-APPENG-CNTS-TestStartUpSuite-1192-0002
//! @SYMTestType CIT
//! @SYMTestPriority High
//! @SYMPREQ 1192
//! @SYMFssID App-Engines>/<CntModel>/ CP.1 <App-Engines>/<CntModel>/ CV.12
//! @SYMTestStatus Implemented
//! @SYMTestCaseDesc Contacts start-up with valid database and valid modified start-up view definitions
//! @SYMTestActions Modify the default view settings with the set API, launch the cnts server and check created views
//! @SYMTestExpectedResults Views are created based on the stored modified view setting

RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep   c:\test\data\StartUpData.ini set_4_default_view_settings_in_centralrep
RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep   c:\test\data\StartUpData.ini check_4_default_view_settings_in_centralrep
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep          c:\test\data\StartUpData.ini launch_cnts_server
DELAY 5000
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep          c:\test\data\StartUpData.ini check_cnts_server_is_ok
RUN_TEST_STEP 100 TestStartUpSuite TestCntsDbStep              c:\test\data\StartUpData.ini check_4_default_view_settings_in_centralrep
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep          c:\test\data\StartUpData.ini terminate_cnts_server
DELAY 5000
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep          c:\test\data\StartUpData.ini check_cnts_server_has_terminated_ok
RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep   c:\test\data\StartUpData.ini set_initial_view_settings_in_centralrep
RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep   c:\test\data\StartUpData.ini initial_view_settings_in_centralrep_ROM
END_TESTCASE PIM-APPENG-CNTS-TestStartUpSuite-1192-0002




START_TESTCASE PIM-APPENG-CNTS-1192-0003
//! @file
//! @SYMTestCaseID PIM-APPENG-CNTS-1192-0003
//! @SYMTestType CIT
//! @SYMTestPriority High
//! @SYMPREQ 1192
//! @SYMFssID App-Engines>/<CntModel>/ CP.1 <App-Engines>/<CntModel>/ CV.12
//! @SYMTestStatus Implemented
//! @SYMTestCaseDesc Contacts start-up with valid database and valid modified start-up view definitions
//! @SYMTestActions Modify the default view settings with the set API, restart the contacts server, delete the
//                  default view settings with the Set API, check the created views
//! @SYMTestExpectedResults A view is created and remains valid untill the contacts server is re-started in which case
//!                         it wont use the deleted default settings

RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep   c:\test\data\StartUpData.ini set_initial_view_settings_in_centralrep
RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep   c:\test\data\StartUpData.ini initial_view_settings_in_centralrep_ROM
RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep   c:\test\data\StartUpData.ini delete_default_view
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep          c:\test\data\StartUpData.ini launch_cnts_server
DELAY 5000
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep          c:\test\data\StartUpData.ini check_cnts_server_is_ok
RUN_TEST_STEP 100 TestStartUpSuite TestCntsDbStep              c:\test\data\StartUpData.ini check_empty_view_defs
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep          c:\test\data\StartUpData.ini terminate_cnts_server
DELAY 5000
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep          c:\test\data\StartUpData.ini check_cnts_server_has_terminated_ok
DELAY 1000
RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep   c:\test\data\StartUpData.ini set_initial_view_settings_in_centralrep
RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep   c:\test\data\StartUpData.ini initial_view_settings_in_centralrep_ROM
RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep   c:\test\data\StartUpData.ini Append_View_Setting_To_View_Setting_List
RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep   c:\test\data\StartUpData.ini check_appended_view_Setting
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep          c:\test\data\StartUpData.ini launch_cnts_server
DELAY 5000
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep          c:\test\data\StartUpData.ini check_cnts_server_is_ok
RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep   c:\test\data\StartUpData.ini delete_named_view_setting
RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep   c:\test\data\StartUpData.ini initial_view_settings_in_centralrep_ROM
RUN_TEST_STEP 100 TestStartUpSuite TestCntsDbStep              c:\test\data\StartUpData.ini check_appended_view_Setting
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep          c:\test\data\StartUpData.ini terminate_cnts_server
DELAY 5000
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep          c:\test\data\StartUpData.ini check_cnts_server_has_terminated_ok
RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep   c:\test\data\StartUpData.ini set_initial_view_settings_in_centralrep
RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep   c:\test\data\StartUpData.ini initial_view_settings_in_centralrep_ROM
END_TESTCASE PIM-APPENG-CNTS-1192-0003




START_TESTCASE PIM-APPENG-CNTS-1192-0005
//! @file
//! @SYMTestCaseID PIM-APPENG-CNTS-1192-0005
//! @SYMTestType CIT
//! @SYMTestPriority High
//! @SYMPREQ 1192
//! @SYMFssID <App-Engines>/<CntModel>/ CP.1 <App-Engines>/<CntModel>/ CV.12
//! @SYMTestStatus Implemented
//! @SYMTestCaseDesc Contacts start-up with valid database and invalid view setting stored by set API
//! @SYMTestActions Store a number of invalid view settings with the Set API, then start contacts server
//! @SYMTestExpectedResults Contacts server starts up, no views created

//Set invalid preferance
RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep             c:\test\data\StartUpData.ini set_invalid_preferance
RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep             c:\test\data\StartUpData.ini check_invalid_preferance
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep                    c:\test\data\StartUpData.ini launch_cnts_server
DELAY 5000
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep                    c:\test\data\StartUpData.ini check_cnts_server_is_ok
RUN_TEST_STEP 100 TestStartUpSuite TestCntsDbStep                        c:\test\data\StartUpData.ini check_empty_view_defs
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep                    c:\test\data\StartUpData.ini terminate_cnts_server
DELAY 5000
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep                    c:\test\data\StartUpData.ini check_cnts_server_has_terminated_ok

//Store invalid view type
RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep             c:\test\data\StartUpData.ini set_invalid_view_type
RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep             c:\test\data\StartUpData.ini check_invalid_view_type
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep                    c:\test\data\StartUpData.ini launch_cnts_server
DELAY 5000
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep                    c:\test\data\StartUpData.ini check_cnts_server_is_ok
RUN_TEST_STEP 100 TestStartUpSuite TestCntsDbStep                        c:\test\data\StartUpData.ini check_empty_view_defs
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep                    c:\test\data\StartUpData.ini terminate_cnts_server
DELAY 5000
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep                    c:\test\data\StartUpData.ini check_cnts_server_has_terminated_ok

//Store invalid plugin name
RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep             c:\test\data\StartUpData.ini store_invalid_plugin_name
RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep             c:\test\data\StartUpData.ini check_invalid_plugin_name
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep                    c:\test\data\StartUpData.ini launch_cnts_server
DELAY 5000
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep                    c:\test\data\StartUpData.ini check_cnts_server_is_ok
RUN_TEST_STEP 100 TestStartUpSuite TestCntsDbStep                        c:\test\data\StartUpData.ini check_empty_view_defs
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep                    c:\test\data\StartUpData.ini terminate_cnts_server
DELAY 5000
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep                    c:\test\data\StartUpData.ini check_cnts_server_has_terminated_ok

//Store invalid sort orders 
RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep             c:\test\data\StartUpData.ini store_invalid_sort_orders
RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep             c:\test\data\StartUpData.ini check_invalid_sort_orders
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep                    c:\test\data\StartUpData.ini launch_cnts_server
DELAY 5000
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep                    c:\test\data\StartUpData.ini check_cnts_server_is_ok
RUN_TEST_STEP 100 TestStartUpSuite TestCntsDbStep                        c:\test\data\StartUpData.ini check_invalid_sort_orders
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep                    c:\test\data\StartUpData.ini terminate_cnts_server
DELAY 5000
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep                    c:\test\data\StartUpData.ini check_cnts_server_has_terminated_ok

//Store initial valid view settings
RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep             c:\test\data\StartUpData.ini set_initial_view_settings_in_centralrep
RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep             c:\test\data\StartUpData.ini initial_view_settings_in_centralrep_ROM
END_TESTCASE PIM-APPENG-CNTS-1192-0005




START_TESTCASE PIM-APPENG-CNTS-1192-0006
//! @file
//! @SYMTestCaseID PIM-APPENG-CNTS-1192-0006
//! @SYMTestType CIT
//! @SYMTestPriority High
//! @SYMPREQ 1192
//! @SYMFssID App-Engines>/<CntModel>/ CP.1
//! @SYMTestStatus Implemented
//! @SYMTestCaseDesc Contacts start-up with no default database and valid default start-up view definitions
//! @SYMTestActions Replace then Delete the database when server is up and running, terminate server and then re-start with no database
//! @SYMTestExpectedResults The first database replace and delete will be allowed, when the contacts server startup again with
//!                         no database no remote views have been created. Attempting to open the db confirms no db available.

//Store a valid view definition
RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep   c:\test\data\StartUpData.ini set_initial_view_settings_in_centralrep
RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep   c:\test\data\StartUpData.ini initial_view_settings_in_centralrep_ROM
DELAY 5000
//launch the contacts server with a valid database then check that the database
// can be replaced and then deleted while held open by the contacts server
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep          c:\test\data\StartUpData.ini launch_cnts_server
DELAY 5000
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep          c:\test\data\StartUpData.ini check_cnts_server_is_ok
RUN_TEST_STEP 100 TestStartUpSuite TestCntsDbStep              c:\test\data\StartUpData.ini initial_view_settings_in_centralrep_ROM
RUN_TEST_STEP 100 TestStartUpSuite TestCntsDbStep              c:\test\data\StartUpData.ini replace_default_cnts_db
RUN_TEST_STEP 100 TestStartUpSuite TestCntsDbStep              c:\test\data\StartUpData.ini add_20_contacts_to_default_db
RUN_TEST_STEP 100 TestStartUpSuite TestCntsDbStep              c:\test\data\StartUpData.ini check_empty_view_defs
DELAY 5000
RUN_TEST_STEP 100 TestStartUpSuite TestCntsDbStep              c:\test\data\StartUpData.ini delete_default_cnts_db
RUN_TEST_STEP 100 TestStartUpSuite TestCntsDbStep              c:\test\data\StartUpData.ini check_empty_view_defs
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep          c:\test\data\StartUpData.ini terminate_cnts_server
DELAY 5000
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep          c:\test\data\StartUpData.ini check_cnts_server_has_terminated_ok

//Launch the contacts server with no database but valid view definitions
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep          c:\test\data\StartUpData.ini launch_cnts_server
DELAY 5000
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep          c:\test\data\StartUpData.ini check_cnts_server_is_ok
RUN_TEST_STEP_RESULT 106 100 TestStartUpSuite TestCntsDbStep   c:\test\data\StartUpData.ini open_default_cnts_db
RUN_TEST_STEP 100 TestStartUpSuite TestCntsDbStep              c:\test\data\StartUpData.ini check_empty_view_defs
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep          c:\test\data\StartUpData.ini terminate_cnts_server
DELAY 5000
RUN_TEST_STEP 100 TestStartUpSuite TestStartUpExeStep          c:\test\data\StartUpData.ini check_cnts_server_has_terminated_ok
END_TESTCASE PIM-APPENG-CNTS-1192-0006



START_TESTCASE PIM-APPENG-CNTS-1192-0007
//! @file
//! @SYMTestCaseID PIM-APPENG-CNTS-1192-0007
//! @SYMTestType CIT
//! @SYMTestPriority High
//! @SYMPREQ 1192
//! @SYMFssID <App-Engines>/<CntModel>/ CV.12
//! @SYMTestStatus Implemented
//! @SYMTestCaseDesc Out of Memory Test for CContactDatabase::SetDefaultViewsL()
//! @SYMTestActions Set the default views inside an OOM loop
//! @SYMTestExpectedResults Successful storage fo view definitions under OOM conditions

RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep   c:\test\data\StartUpData.ini OOM_Test_SetDefaultView
END_TESTCASE PIM-APPENG-CNTS-1192-0007




START_TESTCASE PIM-APPENG-CNTS-1192-0008
//! @file
//! @SYMTestCaseID PIM-APPENG-CNTS-1192-0008
//! @SYMTestType CIT
//! @SYMTestPriority High
//! @SYMPREQ 1192
//! @SYMFssID <App-Engines>/<CntModel>/ CV.12
//! @SYMTestStatus Implemented
//! @SYMTestCaseDesc Out of Memory Test for CContactDatabase::GetDefaultViewsL()
//! @SYMTestActions Get the default views inside an OOM loop
//! @SYMTestExpectedResults Default views are returned

RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep   c:\test\data\StartUpData.ini OOM_Test_GetDefaultView
//Reset the view definitions
RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep   c:\test\data\StartUpData.ini set_initial_view_settings_in_centralrep
RUN_TEST_STEP 100 TestStartUpSuite TestGetSetViewSettingStep   c:\test\data\StartUpData.ini initial_view_settings_in_centralrep_ROM
END_TESTCASE PIM-APPENG-CNTS-1192-0008