author | Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com> |
Thu, 07 Jan 2010 13:38:45 +0200 | |
changeset 6 | 0173bcd7697c |
parent 2 | 4122176ea935 |
permissions | -rw-r--r-- |
0 | 1 |
// |
2 |
// Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies). |
|
3 |
// All rights reserved. |
|
4 |
// This component and the accompanying materials are made available |
|
2
4122176ea935
Revision: 200948 + Removing redundant base integration tests and fixing build errors
John Imhofe <john.imhofe@nokia.com>
parents:
0
diff
changeset
|
5 |
// under the terms of "Eclipse Public License v1.0" |
0 | 6 |
// which accompanies this distribution, and is available |
7 |
// at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 |
// |
|
9 |
// Initial Contributors: |
|
10 |
// Nokia Corporation - initial contribution. |
|
11 |
// |
|
12 |
// Contributors: |
|
13 |
// |
|
2
4122176ea935
Revision: 200948 + Removing redundant base integration tests and fixing build errors
John Imhofe <john.imhofe@nokia.com>
parents:
0
diff
changeset
|
14 |
// Description: |
0 | 15 |
// |
16 |
//! @file |
|
17 |
//! @SYMTestSuiteName pbase-f32-sfsrv-publicapi-ram |
|
18 |
//! @SYMScriptTestEnvironment This test script requires a basic ROM. |
|
19 |
//! @SYMScriptAuthor Jaanus Randveer, Runno Sgirka |
|
20 |
//! @SYMScriptCreationDate 12/10/2007 |
|
21 |
//! @SYMScriptDescription The test script contains API tests for the following functions of CDir class: |
|
22 |
//! TInt Count() const. |
|
23 |
//! const TEntry &operator[](TInt anIndex) const. |
|
24 |
//! TInt Sort(TUint aEntrySortKey). |
|
25 |
||
26 |
||
27 |
LOAD_SUITE T_SfSrv |
|
28 |
DELAY 5000 |
|
29 |
||
30 |
||
31 |
START_TESTCASE PBASE-F32-Dir-PublicApi-0001 |
|
32 |
//! @SYMTestCaseID PBASE-F32-Dir-PublicApi-0001 |
|
33 |
//! @SYMAPI CDir |
|
34 |
//! @SYMTestCaseDesc Function Count() test, that counts entries in the array of directory entries. |
|
35 |
//! Uses API elements: Count(). |
|
36 |
//! @SYMTestActions 1.Create a RFs session and call it's Connect() function. |
|
37 |
//! 2.Call RFs::GetDir(const TDesC &aName, TUint anEntryAttMask, TUint anEntrySortKey, CDir *&anEntryList), and |
|
38 |
//! <RAM_DRIVE>:\<RELATIVE_PATH>\dir\ (containing 4 files: big_line.txt, Test1.txt, Test2.txt, Test3.txt) as first parameter, |
|
39 |
//! KEntryAttHidden as second parameter, ESortByName as third parameter, CDir pointer as fourth parameter |
|
40 |
//! 3.Call CDir::Count(). |
|
41 |
//! @SYMTestStatus Implemented |
|
42 |
//! @SYMTestPriority Critical |
|
43 |
//! @SYMTestExpectedResults Function Count() finds 4 entries! |
|
44 |
//! @SYMTestType CIT |
|
45 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
46 |
CREATE_OBJECT RFs RFs1 |
|
47 |
CREATE_OBJECT CFileMan CFileMan1 |
|
48 |
COMMAND RFs1 new |
|
49 |
COMMAND RFs1 Connect |
|
50 |
COMMAND RFs1 MkDirAll PBASE-F32-Dir-PublicApi-0001-001-MkDirAll_command004 |
|
51 |
COMMAND CFileMan1 NewL PBASE-F32-Dir-PublicApi-0001-001-NewL_command005 |
|
52 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0001-001-Copy_command006 |
|
53 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0001-001-Copy_command007 |
|
54 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0001-001-Copy_command008 |
|
55 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0001-001-Copy_command009 |
|
56 |
COMMAND CFileMan1 ~ |
|
57 |
COMMAND RFs1 ~ |
|
58 |
END_TEST_BLOCK |
|
59 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
60 |
CREATE_OBJECT RFs RFs1 |
|
61 |
CREATE_OBJECT CDir CDir1 |
|
62 |
COMMAND RFs1 new |
|
63 |
COMMAND RFs1 Connect |
|
64 |
COMMAND RFs1 GetDir PBASE-F32-Dir-PublicApi-0001-002-GetDir_command004 |
|
65 |
COMMAND CDir1 Count PBASE-F32-Dir-PublicApi-0001-002-Count_command005 |
|
66 |
COMMAND CDir1 ~ |
|
67 |
COMMAND RFs1 ~ |
|
68 |
END_TEST_BLOCK |
|
69 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
70 |
CREATE_OBJECT RFs RFs1 |
|
71 |
CREATE_OBJECT CFileMan CFileMan1 |
|
72 |
COMMAND RFs1 new |
|
73 |
COMMAND RFs1 Connect |
|
74 |
COMMAND CFileMan1 NewL PBASE-F32-Dir-PublicApi-0001-003-NewL_command004 |
|
75 |
COMMAND CFileMan1 Delete PBASE-F32-Dir-PublicApi-0001-003-Delete_command005 |
|
76 |
COMMAND RFs1 RmDir PBASE-F32-Dir-PublicApi-0001-003-RmDir_command006 |
|
77 |
COMMAND CFileMan1 ~ |
|
78 |
COMMAND RFs1 ~ |
|
79 |
END_TEST_BLOCK |
|
80 |
END_TESTCASE PBASE-F32-Dir-PublicApi-0001 |
|
81 |
||
82 |
||
83 |
START_TESTCASE PBASE-F32-Dir-PublicApi-0002 |
|
84 |
//! @SYMTestCaseID PBASE-F32-Dir-PublicApi-0002 |
|
85 |
//! @SYMAPI CDir |
|
86 |
//! @SYMTestCaseDesc operator const TEntry &operator[](TInt anIndex) const test, that takes first entry from the array of directory entries. |
|
87 |
//! Uses API elements: operator[](). |
|
88 |
//! @SYMTestActions 1.Create a RFs session and call it's Connect() function. |
|
89 |
//! 2.Call RFs::GetDir(const TDesC &aName, TUint anEntryAttMask, TUint anEntrySortKey, CDir *&anEntryList), and |
|
90 |
//! <RAM_DRIVE>:\<RELATIVE_PATH>\Dir\ (containing 4 files: big_line.txt, Test1.txt, Test2.txt, Test3.txt) as first parameter, |
|
91 |
//! KEntryAttHidden as second parameter, ESortByName as third parameter, CDir pointer as fourth parameter |
|
92 |
//! 3.Create new TEntry object. |
|
93 |
//! 4.Call CDir::operator[]() and pass 0 as parameter. |
|
94 |
//! @SYMTestStatus Implemented |
|
95 |
//! @SYMTestPriority Critical |
|
96 |
//! @SYMTestExpectedResults First element is big_line.txt . |
|
97 |
//! @SYMTestType CIT |
|
98 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
99 |
CREATE_OBJECT RFs RFs1 |
|
100 |
CREATE_OBJECT CFileMan CFileMan1 |
|
101 |
COMMAND RFs1 new |
|
102 |
COMMAND RFs1 Connect |
|
103 |
COMMAND RFs1 MkDirAll PBASE-F32-Dir-PublicApi-0002-001-MkDirAll_command004 |
|
104 |
COMMAND CFileMan1 NewL PBASE-F32-Dir-PublicApi-0002-001-NewL_command005 |
|
105 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0002-001-Copy_command006 |
|
106 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0002-001-Copy_command007 |
|
107 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0002-001-Copy_command008 |
|
108 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0002-001-Copy_command009 |
|
109 |
COMMAND CFileMan1 ~ |
|
110 |
COMMAND RFs1 ~ |
|
111 |
END_TEST_BLOCK |
|
112 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
113 |
CREATE_OBJECT RFs RFs1 |
|
114 |
CREATE_OBJECT TEntry TEntry1 |
|
115 |
CREATE_OBJECT CDir CDir1 |
|
116 |
COMMAND RFs1 new |
|
117 |
COMMAND RFs1 Connect |
|
118 |
COMMAND RFs1 GetDir PBASE-F32-Dir-PublicApi-0002-002-GetDir_command005 |
|
119 |
COMMAND TEntry1 new |
|
120 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0002-002-index_command007 |
|
121 |
COMMAND CDir1 ~ |
|
122 |
COMMAND TEntry1 ~ |
|
123 |
COMMAND RFs1 ~ |
|
124 |
END_TEST_BLOCK |
|
125 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
126 |
CREATE_OBJECT RFs RFs1 |
|
127 |
CREATE_OBJECT CFileMan CFileMan1 |
|
128 |
COMMAND RFs1 new |
|
129 |
COMMAND RFs1 Connect |
|
130 |
COMMAND CFileMan1 NewL PBASE-F32-Dir-PublicApi-0002-003-NewL_command004 |
|
131 |
COMMAND CFileMan1 Delete PBASE-F32-Dir-PublicApi-0002-003-Delete_command005 |
|
132 |
COMMAND RFs1 RmDir PBASE-F32-Dir-PublicApi-0002-003-RmDir_command006 |
|
133 |
COMMAND CFileMan1 ~ |
|
134 |
COMMAND RFs1 ~ |
|
135 |
END_TEST_BLOCK |
|
136 |
END_TESTCASE PBASE-F32-Dir-PublicApi-0002 |
|
137 |
||
138 |
||
139 |
START_TESTCASE PBASE-F32-Dir-PublicApi-0003 |
|
140 |
//! @SYMTestCaseID PBASE-F32-Dir-PublicApi-0003 |
|
141 |
//! @SYMAPI CDir |
|
142 |
//! @SYMTestCaseDesc Function Sort(TUint aEntrySortKey) test, that sorts the array of directory entries by name ascendingly. |
|
143 |
//! Uses API elements: Sort(), operator[](). |
|
144 |
//! @SYMTestActions 1.Create a RFs session and call it's Connect() function. |
|
145 |
//! 2.Call RFs::GetDir(const TDesC &aName, TUint anEntryAttMask, TUint anEntrySortKey, CDir *&anEntryList), and |
|
146 |
//! <RAM_DRIVE>:\<RELATIVE_PATH>\Dir\ (containing 4 files: big_line.txt, Test1.txt, Test2.txt, Test3.txt) as first parameter, |
|
147 |
//! KEntryAttHidden as second parameter, ESortNone as third parameter, CDir pointer as fourth parameter. |
|
148 |
//! 3.Create new TEntry object. |
|
149 |
//! 4.Call CDir::Sort() and ESortByName | EAscending as parameter. |
|
150 |
//! 5.Call operator[]() to verify the sorting result. |
|
151 |
//! @SYMTestStatus Implemented |
|
152 |
//! @SYMTestPriority Critical |
|
153 |
//! @SYMTestExpectedResults Returns KErrNone. |
|
154 |
//! @SYMTestType CIT |
|
155 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
156 |
CREATE_OBJECT RFs RFs1 |
|
157 |
CREATE_OBJECT CFileMan CFileMan1 |
|
158 |
COMMAND RFs1 new |
|
159 |
COMMAND RFs1 Connect |
|
160 |
COMMAND RFs1 MkDirAll PBASE-F32-Dir-PublicApi-0003-001-MkDirAll_command004 |
|
161 |
COMMAND CFileMan1 NewL PBASE-F32-Dir-PublicApi-0003-001-NewL_command005 |
|
162 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0003-001-Copy_command006 |
|
163 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0003-001-Copy_command007 |
|
164 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0003-001-Copy_command008 |
|
165 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0003-001-Copy_command009 |
|
166 |
COMMAND CFileMan1 ~ |
|
167 |
COMMAND RFs1 ~ |
|
168 |
END_TEST_BLOCK |
|
169 |
START_TEST_BLOCK 2000 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
170 |
CREATE_OBJECT RFs RFs1 |
|
171 |
CREATE_OBJECT TEntry TEntry1 |
|
172 |
CREATE_OBJECT CDir CDir1 |
|
173 |
COMMAND RFs1 new |
|
174 |
COMMAND RFs1 Connect |
|
175 |
COMMAND RFs1 GetDir PBASE-F32-Dir-PublicApi-0003-002-GetDir_command005 |
|
176 |
COMMAND TEntry1 new |
|
177 |
COMMAND CDir1 Sort PBASE-F32-Dir-PublicApi-0003-002-Sort_command007 |
|
178 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0003-002-index_command008 |
|
179 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0003-002-index_command009 |
|
180 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0003-002-index_command010 |
|
181 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0003-002-index_command011 |
|
182 |
COMMAND CDir1 ~ |
|
183 |
COMMAND TEntry1 ~ |
|
184 |
COMMAND RFs1 ~ |
|
185 |
END_TEST_BLOCK |
|
186 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
187 |
CREATE_OBJECT RFs RFs1 |
|
188 |
CREATE_OBJECT CFileMan CFileMan1 |
|
189 |
COMMAND RFs1 new |
|
190 |
COMMAND RFs1 Connect |
|
191 |
COMMAND CFileMan1 NewL PBASE-F32-Dir-PublicApi-0003-003-NewL_command004 |
|
192 |
COMMAND CFileMan1 Delete PBASE-F32-Dir-PublicApi-0003-003-Delete_command005 |
|
193 |
COMMAND RFs1 RmDir PBASE-F32-Dir-PublicApi-0003-003-RmDir_command006 |
|
194 |
COMMAND CFileMan1 ~ |
|
195 |
COMMAND RFs1 ~ |
|
196 |
END_TEST_BLOCK |
|
197 |
END_TESTCASE PBASE-F32-Dir-PublicApi-0003 |
|
198 |
||
199 |
||
200 |
START_TESTCASE PBASE-F32-Dir-PublicApi-0004 |
|
201 |
//! @SYMTestCaseID PBASE-F32-Dir-PublicApi-0004 |
|
202 |
//! @SYMAPI CDir |
|
203 |
//! @SYMTestCaseDesc Function Sort(TUint aEntrySortKey) test, that sorts the array of directory entries by extension descendingly. |
|
204 |
//! Uses API elements: Sort(), operator[](). |
|
205 |
//! @SYMTestActions 1.Create a RFs session and call it's Connect() function. |
|
206 |
//! 2.Call RFs::GetDir(const TDesC &aName, TUint anEntryAttMask, TUint anEntrySortKey, CDir *&anEntryList), and |
|
207 |
//! <RAM_DRIVE>:\<RELATIVE_PATH>\Dir\ (containing 4 files: big_line.txt, Test1.txt, Test2.txt, Test3.txt) as first parameter, |
|
208 |
//! KEntryAttHidden as second parameter, ESortNone as third parameter, CDir pointer as fourth parameter. |
|
209 |
//! 3.Create new TEntry object. |
|
210 |
//! 4.Call CDir::Sort() and ESortByExt | EDescending as parameter. |
|
211 |
//! 5.Call operator[]() to verify the sorting result. |
|
212 |
//! @SYMTestStatus Implemented |
|
213 |
//! @SYMTestPriority Critical |
|
214 |
//! @SYMTestExpectedResults Returns KErrNone. |
|
215 |
//! @SYMTestType CIT |
|
216 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
217 |
CREATE_OBJECT RFs RFs1 |
|
218 |
CREATE_OBJECT CFileMan CFileMan1 |
|
219 |
COMMAND RFs1 new |
|
220 |
COMMAND RFs1 Connect |
|
221 |
COMMAND RFs1 MkDirAll PBASE-F32-Dir-PublicApi-0004-001-MkDirAll_command004 |
|
222 |
COMMAND CFileMan1 NewL PBASE-F32-Dir-PublicApi-0004-001-NewL_command005 |
|
223 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0004-001-Copy_command006 |
|
224 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0004-001-Copy_command007 |
|
225 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0004-001-Copy_command008 |
|
226 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0004-001-Copy_command009 |
|
227 |
COMMAND CFileMan1 ~ |
|
228 |
COMMAND RFs1 ~ |
|
229 |
END_TEST_BLOCK |
|
230 |
START_TEST_BLOCK 2000 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
231 |
CREATE_OBJECT RFs RFs1 |
|
232 |
CREATE_OBJECT TEntry TEntry1 |
|
233 |
CREATE_OBJECT CDir CDir1 |
|
234 |
COMMAND RFs1 new |
|
235 |
COMMAND RFs1 Connect |
|
236 |
COMMAND RFs1 GetDir PBASE-F32-Dir-PublicApi-0004-002-GetDir_command005 |
|
237 |
COMMAND TEntry1 new |
|
238 |
COMMAND CDir1 Sort PBASE-F32-Dir-PublicApi-0004-002-Sort_command007 |
|
239 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0004-002-index_command008 |
|
240 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0004-002-index_command009 |
|
241 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0004-002-index_command010 |
|
242 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0004-002-index_command011 |
|
243 |
COMMAND CDir1 ~ |
|
244 |
COMMAND TEntry1 ~ |
|
245 |
COMMAND RFs1 ~ |
|
246 |
END_TEST_BLOCK |
|
247 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
248 |
CREATE_OBJECT RFs RFs1 |
|
249 |
CREATE_OBJECT CFileMan CFileMan1 |
|
250 |
COMMAND RFs1 new |
|
251 |
COMMAND RFs1 Connect |
|
252 |
COMMAND CFileMan1 NewL PBASE-F32-Dir-PublicApi-0004-003-NewL_command004 |
|
253 |
COMMAND CFileMan1 Delete PBASE-F32-Dir-PublicApi-0004-003-Delete_command005 |
|
254 |
COMMAND RFs1 RmDir PBASE-F32-Dir-PublicApi-0004-003-RmDir_command006 |
|
255 |
COMMAND CFileMan1 ~ |
|
256 |
COMMAND RFs1 ~ |
|
257 |
END_TEST_BLOCK |
|
258 |
END_TESTCASE PBASE-F32-Dir-PublicApi-0004 |
|
259 |
||
260 |
||
261 |
START_TESTCASE PBASE-F32-Dir-PublicApi-0005 |
|
262 |
//! @SYMTestCaseID PBASE-F32-Dir-PublicApi-0005 |
|
263 |
//! @SYMAPI CDir |
|
264 |
//! @SYMTestCaseDesc Function Sort(TUint aEntrySortKey) test, that sorts the array of directory entries by UID. |
|
265 |
//! Uses API elements: Sort(), operator[](). |
|
266 |
//! @SYMTestActions 1.Create a RFs session and call it's Connect() function. |
|
267 |
//! 2.Call RFs::GetDir(const TDesC &aName, TUint anEntryAttMask, TUint anEntrySortKey, CDir *&anEntryList), and |
|
268 |
//! <RAM_DRIVE>:\<RELATIVE_PATH>\Dir\ (containing 4 files: big_line.txt, Test1.txt, Test2.txt, Test3.txt) as first parameter, |
|
269 |
//! KEntryAttHidden as second parameter, ESortNone as third parameter, CDir pointer as fourth parameter. |
|
270 |
//! 3.Create new TEntry object. |
|
271 |
//! 4.Call CDir::Sort() and ESortByUid as parameter. |
|
272 |
//! 5.Call operator[]() to verify the sorting result. |
|
273 |
//! @SYMTestStatus Implemented |
|
274 |
//! @SYMTestPriority Critical |
|
275 |
//! @SYMTestExpectedResults Returns KErrNone. |
|
276 |
//! @SYMTestType CIT |
|
277 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
278 |
CREATE_OBJECT RFs RFs1 |
|
279 |
CREATE_OBJECT CFileMan CFileMan1 |
|
280 |
COMMAND RFs1 new |
|
281 |
COMMAND RFs1 Connect |
|
282 |
COMMAND RFs1 MkDirAll PBASE-F32-Dir-PublicApi-0005-001-MkDirAll_command004 |
|
283 |
COMMAND CFileMan1 NewL PBASE-F32-Dir-PublicApi-0005-001-NewL_command005 |
|
284 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0005-001-Copy_command006 |
|
285 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0005-001-Copy_command007 |
|
286 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0005-001-Copy_command008 |
|
287 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0005-001-Copy_command009 |
|
288 |
COMMAND CFileMan1 ~ |
|
289 |
COMMAND RFs1 ~ |
|
290 |
END_TEST_BLOCK |
|
291 |
START_TEST_BLOCK 2000 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
292 |
CREATE_OBJECT RFs RFs1 |
|
293 |
CREATE_OBJECT TEntry TEntry1 |
|
294 |
CREATE_OBJECT CDir CDir1 |
|
295 |
COMMAND RFs1 new |
|
296 |
COMMAND RFs1 Connect |
|
297 |
COMMAND RFs1 GetDir PBASE-F32-Dir-PublicApi-0005-002-GetDir_command005 |
|
298 |
COMMAND TEntry1 new |
|
299 |
COMMAND CDir1 Sort PBASE-F32-Dir-PublicApi-0005-002-Sort_command007 |
|
300 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0005-002-index_command008 |
|
301 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0005-002-index_command009 |
|
302 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0005-002-index_command010 |
|
303 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0005-002-index_command011 |
|
304 |
COMMAND CDir1 ~ |
|
305 |
COMMAND TEntry1 ~ |
|
306 |
COMMAND RFs1 ~ |
|
307 |
END_TEST_BLOCK |
|
308 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
309 |
CREATE_OBJECT RFs RFs1 |
|
310 |
CREATE_OBJECT CFileMan CFileMan1 |
|
311 |
COMMAND RFs1 new |
|
312 |
COMMAND RFs1 Connect |
|
313 |
COMMAND CFileMan1 NewL PBASE-F32-Dir-PublicApi-0005-003-NewL_command004 |
|
314 |
COMMAND CFileMan1 Delete PBASE-F32-Dir-PublicApi-0005-003-Delete_command005 |
|
315 |
COMMAND RFs1 RmDir PBASE-F32-Dir-PublicApi-0005-003-RmDir_command006 |
|
316 |
COMMAND CFileMan1 ~ |
|
317 |
COMMAND RFs1 ~ |
|
318 |
END_TEST_BLOCK |
|
319 |
END_TESTCASE PBASE-F32-Dir-PublicApi-0005 |
|
320 |
||
321 |
||
322 |
START_TESTCASE PBASE-F32-Dir-PublicApi-0006 |
|
323 |
//! @SYMTestCaseID PBASE-F32-Dir-PublicApi-0006 |
|
324 |
//! @SYMAPI CDir |
|
325 |
//! @SYMTestCaseDesc Function Sort(TUint aEntrySortKey) test, that sorts the array of directory entries by file date, placing directories |
|
326 |
//! first descendingly. |
|
327 |
//! Uses API elements: Sort(), operator[](). |
|
328 |
//! @SYMTestActions 1.Create a RFs session and call it's Connect() function. |
|
329 |
//! 2.Make three directories, passing names BBDir, CCDir and AADir as parameters. |
|
330 |
//! 3.Call RFs::SetModified(const TDesC &aName, const TTime &aTime) to set directories' and files' modified date. |
|
331 |
//! 4.Call RFs::GetDir(const TDesC &aName, TUint anEntryAttMask, TUint anEntrySortKey, CDir *&anEntryList), and |
|
332 |
//! <RAM_DRIVE>:\<RELATIVE_PATH>\Dir\ (containing 4 files and 3 folders: big_line.txt, Test1.txt, Test2.txt, Test3.txt, AADir, BBDir, |
|
333 |
//! CCDir) as first parameter, KEntryAttMaskSupported as second parameter,EDirsLast as third parameter, |
|
334 |
//! CDir pointer as fourth parameter. |
|
335 |
//! 5.Create new TEntry object. |
|
336 |
//! 6.Call CDir::Sort() and EDirsFirst | EDirDescending | ESortByDate as parameter. |
|
337 |
//! 7.Call operator[]() to verify the sorting result. |
|
338 |
//! 8.Remove previously created directories. |
|
339 |
//! @SYMTestStatus Implemented |
|
340 |
//! @SYMTestPriority Critical |
|
341 |
//! @SYMTestExpectedResults Returns KErrNone. |
|
342 |
//! @SYMTestType CIT |
|
343 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
344 |
CREATE_OBJECT RFs RFs1 |
|
345 |
CREATE_OBJECT CFileMan CFileMan1 |
|
346 |
COMMAND RFs1 new |
|
347 |
COMMAND RFs1 Connect |
|
348 |
COMMAND RFs1 MkDirAll PBASE-F32-Dir-PublicApi-0006-001-MkDirAll_command004 |
|
349 |
COMMAND CFileMan1 NewL PBASE-F32-Dir-PublicApi-0006-001-NewL_command005 |
|
350 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0006-001-Copy_command006 |
|
351 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0006-001-Copy_command007 |
|
352 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0006-001-Copy_command008 |
|
353 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0006-001-Copy_command009 |
|
354 |
COMMAND CFileMan1 ~ |
|
355 |
COMMAND RFs1 ~ |
|
356 |
END_TEST_BLOCK |
|
357 |
START_TEST_BLOCK 2000 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
358 |
CREATE_OBJECT RFs RFs1 |
|
359 |
CREATE_OBJECT TEntry TEntry1 |
|
360 |
CREATE_OBJECT CDir CDir1 |
|
361 |
COMMAND RFs1 new |
|
362 |
COMMAND RFs1 Connect |
|
363 |
COMMAND RFs1 MkDirAll PBASE-F32-Dir-PublicApi-0006-002-MkDirAll_command005 |
|
364 |
COMMAND RFs1 MkDirAll PBASE-F32-Dir-PublicApi-0006-002-MkDirAll_command006 |
|
365 |
COMMAND RFs1 MkDirAll PBASE-F32-Dir-PublicApi-0006-002-MkDirAll_command007 |
|
366 |
COMMAND RFs1 SetModified PBASE-F32-Dir-PublicApi-0006-002-SetModified_command008 |
|
367 |
COMMAND RFs1 SetModified PBASE-F32-Dir-PublicApi-0006-002-SetModified_command009 |
|
368 |
COMMAND RFs1 SetModified PBASE-F32-Dir-PublicApi-0006-002-SetModified_command010 |
|
369 |
COMMAND RFs1 SetModified PBASE-F32-Dir-PublicApi-0006-002-SetModified_command011 |
|
370 |
COMMAND RFs1 GetDir PBASE-F32-Dir-PublicApi-0006-002-GetDir_command012 |
|
371 |
COMMAND TEntry1 new |
|
372 |
COMMAND CDir1 Sort PBASE-F32-Dir-PublicApi-0006-002-Sort_command014 |
|
373 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0006-002-index_command015 |
|
374 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0006-002-index_command016 |
|
375 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0006-002-index_command017 |
|
376 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0006-002-index_command018 |
|
377 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0006-002-index_command019 |
|
378 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0006-002-index_command020 |
|
379 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0006-002-index_command021 |
|
380 |
COMMAND RFs1 RmDir PBASE-F32-Dir-PublicApi-0006-002-RmDir_command022 |
|
381 |
COMMAND RFs1 RmDir PBASE-F32-Dir-PublicApi-0006-002-RmDir_command023 |
|
382 |
COMMAND RFs1 RmDir PBASE-F32-Dir-PublicApi-0006-002-RmDir_command024 |
|
383 |
COMMAND CDir1 ~ |
|
384 |
COMMAND TEntry1 ~ |
|
385 |
COMMAND RFs1 ~ |
|
386 |
END_TEST_BLOCK |
|
387 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
388 |
CREATE_OBJECT RFs RFs1 |
|
389 |
CREATE_OBJECT CFileMan CFileMan1 |
|
390 |
COMMAND RFs1 new |
|
391 |
COMMAND RFs1 Connect |
|
392 |
COMMAND CFileMan1 NewL PBASE-F32-Dir-PublicApi-0006-003-NewL_command004 |
|
393 |
COMMAND CFileMan1 Delete PBASE-F32-Dir-PublicApi-0006-003-Delete_command005 |
|
394 |
COMMAND RFs1 RmDir PBASE-F32-Dir-PublicApi-0006-003-RmDir_command006 |
|
395 |
COMMAND CFileMan1 ~ |
|
396 |
COMMAND RFs1 ~ |
|
397 |
END_TEST_BLOCK |
|
398 |
END_TESTCASE PBASE-F32-Dir-PublicApi-0006 |
|
399 |
||
400 |
||
401 |
START_TESTCASE PBASE-F32-Dir-PublicApi-0007 |
|
402 |
//! @SYMTestCaseID PBASE-F32-Dir-PublicApi-0007 |
|
403 |
//! @SYMAPI CDir |
|
404 |
//! @SYMTestCaseDesc Function Sort(TUint aEntrySortKey) test, that sorts the array of directory entries by size, placing directories last. |
|
405 |
//! Uses API elements: Sort(), operator[](). |
|
406 |
//! @SYMTestActions 1.Create a RFs session and call it's Connect() function. |
|
407 |
//! 2.Make three directories, passing names BBDir, CCDir and AADir as parameters. |
|
408 |
//! 3.Call RFs::GetDir(const TDesC &aName, TUint anEntryAttMask, TUint anEntrySortKey, CDir *&anEntryList), and |
|
409 |
//! <RAM_DRIVE>:\<RELATIVE_PATH>\Dir\ (containing 4 files and 3 folders: big_line.txt, Test1.txt, Test2.txt, Test3.txt, AADir, BBDir, |
|
410 |
//! CCDir) as first parameter, KEntryAttMaskSupported as second parameter, ESortNone as third parameter, CDir pointer |
|
411 |
//! as fourth parameter. |
|
412 |
//! 4.Create new TEntry object. |
|
413 |
//! 5.Call CDir::Sort() and EDirsLast | ESortBySize as parameter. |
|
414 |
//! 6.Call operator[]() to verify the sorting result. |
|
415 |
//! 7.Remove previously created directories. |
|
416 |
//! @SYMTestStatus Implemented |
|
417 |
//! @SYMTestPriority Critical |
|
418 |
//! @SYMTestExpectedResults Returns KErrNone. |
|
419 |
//! @SYMTestType CIT |
|
420 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
421 |
CREATE_OBJECT RFs RFs1 |
|
422 |
CREATE_OBJECT CFileMan CFileMan1 |
|
423 |
COMMAND RFs1 new |
|
424 |
COMMAND RFs1 Connect |
|
425 |
COMMAND RFs1 MkDirAll PBASE-F32-Dir-PublicApi-0007-001-MkDirAll_command004 |
|
426 |
COMMAND CFileMan1 NewL PBASE-F32-Dir-PublicApi-0007-001-NewL_command005 |
|
427 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0007-001-Copy_command006 |
|
428 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0007-001-Copy_command007 |
|
429 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0007-001-Copy_command008 |
|
430 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0007-001-Copy_command009 |
|
431 |
COMMAND CFileMan1 ~ |
|
432 |
COMMAND RFs1 ~ |
|
433 |
END_TEST_BLOCK |
|
434 |
START_TEST_BLOCK 2000 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
435 |
CREATE_OBJECT RFs RFs1 |
|
436 |
CREATE_OBJECT TEntry TEntry1 |
|
437 |
CREATE_OBJECT CDir CDir1 |
|
438 |
COMMAND RFs1 new |
|
439 |
COMMAND RFs1 Connect |
|
440 |
COMMAND RFs1 MkDirAll PBASE-F32-Dir-PublicApi-0007-002-MkDirAll_command005 |
|
441 |
COMMAND RFs1 MkDirAll PBASE-F32-Dir-PublicApi-0007-002-MkDirAll_command006 |
|
442 |
COMMAND RFs1 MkDirAll PBASE-F32-Dir-PublicApi-0007-002-MkDirAll_command007 |
|
443 |
COMMAND RFs1 GetDir PBASE-F32-Dir-PublicApi-0007-002-GetDir_command008 |
|
444 |
COMMAND TEntry1 new |
|
445 |
COMMAND CDir1 Sort PBASE-F32-Dir-PublicApi-0007-002-Sort_command010 |
|
446 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0007-002-index_command011 |
|
447 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0007-002-index_command012 |
|
448 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0007-002-index_command013 |
|
449 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0007-002-index_command014 |
|
450 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0007-002-index_command015 |
|
451 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0007-002-index_command016 |
|
452 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0007-002-index_command017 |
|
453 |
COMMAND RFs1 RmDir PBASE-F32-Dir-PublicApi-0007-002-RmDir_command018 |
|
454 |
COMMAND RFs1 RmDir PBASE-F32-Dir-PublicApi-0007-002-RmDir_command019 |
|
455 |
COMMAND RFs1 RmDir PBASE-F32-Dir-PublicApi-0007-002-RmDir_command020 |
|
456 |
COMMAND CDir1 ~ |
|
457 |
COMMAND TEntry1 ~ |
|
458 |
COMMAND RFs1 ~ |
|
459 |
END_TEST_BLOCK |
|
460 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
461 |
CREATE_OBJECT RFs RFs1 |
|
462 |
CREATE_OBJECT CFileMan CFileMan1 |
|
463 |
COMMAND RFs1 new |
|
464 |
COMMAND RFs1 Connect |
|
465 |
COMMAND CFileMan1 NewL PBASE-F32-Dir-PublicApi-0007-003-NewL_command004 |
|
466 |
COMMAND CFileMan1 Delete PBASE-F32-Dir-PublicApi-0007-003-Delete_command005 |
|
467 |
COMMAND RFs1 RmDir PBASE-F32-Dir-PublicApi-0007-003-RmDir_command006 |
|
468 |
COMMAND CFileMan1 ~ |
|
469 |
COMMAND RFs1 ~ |
|
470 |
END_TEST_BLOCK |
|
471 |
END_TESTCASE PBASE-F32-Dir-PublicApi-0007 |
|
472 |
||
473 |
||
474 |
START_TESTCASE PBASE-F32-Dir-PublicApi-0008 |
|
475 |
//! @SYMTestCaseID PBASE-F32-Dir-PublicApi-0008 |
|
476 |
//! @SYMAPI CDir |
|
477 |
//! @SYMTestCaseDesc Function Sort(TUint aEntrySortKey) test, that sorts the array of directory entries by placing directories in the order |
|
478 |
//! they occur. |
|
479 |
//! Uses API elements: Sort(), operator[](). |
|
480 |
//! @SYMTestActions 1.Create a RFs session and call it's Connect() function. |
|
481 |
//! 2.Make three directories, passing names BBDir, CCDir and AADir as parameters. |
|
482 |
//! 3.Call RFs::GetDir(const TDesC &aName, TUint anEntryAttMask, TUint anEntrySortKey, CDir *&anEntryList, CDir |
|
483 |
//! *&aDirList), and <RAM_DRIVE>:\<RELATIVE_PATH>\Dir\ (containing 3 folders: AADir, BBDir, CCDir) as first parameter, KEntryAttMaskSupported |
|
484 |
//! as second parameter, ESortNone as third parameter, CDir pointer as fourth and fifth parameter. |
|
485 |
//! 4.Create new TEntry object. |
|
486 |
//! 5.Call CDir::Sort() and EDirsAnyOrder as parameter. |
|
487 |
//! 6.Remove previously created directories. |
|
488 |
//! @SYMTestStatus Implemented |
|
489 |
//! @SYMTestPriority Critical |
|
490 |
//! @SYMTestExpectedResults Returns KErrNone. |
|
491 |
//! @SYMTestType CIT |
|
492 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
493 |
CREATE_OBJECT RFs RFs1 |
|
494 |
COMMAND RFs1 new |
|
495 |
COMMAND RFs1 Connect |
|
496 |
COMMAND RFs1 MkDirAll PBASE-F32-Dir-PublicApi-0008-001-MkDirAll_command003 |
|
497 |
COMMAND RFs1 ~ |
|
498 |
END_TEST_BLOCK |
|
499 |
START_TEST_BLOCK 2000 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
500 |
CREATE_OBJECT RFs RFs1 |
|
501 |
CREATE_OBJECT TEntry TEntry1 |
|
502 |
CREATE_OBJECT CDir CDir1 |
|
503 |
CREATE_OBJECT CDir CDir2 |
|
504 |
COMMAND RFs1 new |
|
505 |
COMMAND RFs1 Connect |
|
506 |
COMMAND RFs1 MkDirAll PBASE-F32-Dir-PublicApi-0008-002-MkDirAll_command006 |
|
507 |
COMMAND RFs1 MkDirAll PBASE-F32-Dir-PublicApi-0008-002-MkDirAll_command007 |
|
508 |
COMMAND RFs1 MkDirAll PBASE-F32-Dir-PublicApi-0008-002-MkDirAll_command008 |
|
509 |
COMMAND RFs1 GetDir PBASE-F32-Dir-PublicApi-0008-002-GetDir_command009 |
|
510 |
COMMAND TEntry1 new |
|
511 |
COMMAND CDir2 Sort PBASE-F32-Dir-PublicApi-0008-002-Sort_command011 |
|
512 |
COMMAND RFs1 RmDir PBASE-F32-Dir-PublicApi-0008-002-RmDir_command012 |
|
513 |
COMMAND RFs1 RmDir PBASE-F32-Dir-PublicApi-0008-002-RmDir_command013 |
|
514 |
COMMAND RFs1 RmDir PBASE-F32-Dir-PublicApi-0008-002-RmDir_command014 |
|
515 |
COMMAND CDir2 ~ |
|
516 |
COMMAND CDir1 ~ |
|
517 |
COMMAND TEntry1 ~ |
|
518 |
COMMAND RFs1 ~ |
|
519 |
END_TEST_BLOCK |
|
520 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
521 |
CREATE_OBJECT RFs RFs1 |
|
522 |
COMMAND RFs1 new |
|
523 |
COMMAND RFs1 Connect |
|
524 |
COMMAND RFs1 RmDir PBASE-F32-Dir-PublicApi-0008-003-RmDir_command003 |
|
525 |
COMMAND RFs1 ~ |
|
526 |
END_TEST_BLOCK |
|
527 |
END_TESTCASE PBASE-F32-Dir-PublicApi-0008 |
|
528 |
||
529 |
||
530 |
START_TESTCASE PBASE-F32-Dir-PublicApi-0009 |
|
531 |
//! @SYMTestCaseID PBASE-F32-Dir-PublicApi-0009 |
|
532 |
//! @SYMAPI CDir |
|
533 |
//! @SYMTestCaseDesc Test that checks that CDir entrylist is initialized correctly. Can be also used |
|
534 |
//! as RFs::GetDir(const TDesC &aName, TUint anEntryAttMask, TUint anEntrySortKey, CDir *&anEntryList, CDir *&aDirList) |
|
535 |
//! optional test. |
|
536 |
//! Uses API elements: operator[](). |
|
537 |
//! @SYMTestActions 1.Create a RFs session and call it's Connect() function. |
|
538 |
//! 2.Call RFs::TInt GetDir(const TDesC &aName, TUint anEntryAttMask, TUint anEntrySortKey, CDir *&anEntryList, |
|
539 |
//! CDir *&aDirList), and <RAM_DRIVE>:\<RELATIVE_PATH>\Dir\ (containing 4 files: big_line.txt, Test1.txt, Test2.txt, Test3.txt) as first |
|
540 |
//! parameter, KEntryAttHidden as second parameter, ESortByName | EAscending as third parameter, first CDir pointer as |
|
541 |
//! fourth parameter, second CDir pointer as fifth parameter. |
|
542 |
//! 3.Create new TEntry object. |
|
543 |
//! 4. Call CDir::Sort() and ESortByName | EAscending as parameter on the anEntryList. |
|
544 |
//! 5. Call operator[]() on the first CDir object to verify the sorting result. |
|
545 |
//! @SYMTestStatus Implemented |
|
546 |
//! @SYMTestPriority Critical |
|
547 |
//! @SYMTestExpectedResults Returns KErrNone. |
|
548 |
//! @SYMTestType CIT |
|
549 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
550 |
CREATE_OBJECT RFs RFs1 |
|
551 |
CREATE_OBJECT CFileMan CFileMan1 |
|
552 |
COMMAND RFs1 new |
|
553 |
COMMAND RFs1 Connect |
|
554 |
COMMAND RFs1 MkDirAll PBASE-F32-Dir-PublicApi-0009-001-MkDirAll_command004 |
|
555 |
COMMAND CFileMan1 NewL PBASE-F32-Dir-PublicApi-0009-001-NewL_command005 |
|
556 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0009-001-Copy_command006 |
|
557 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0009-001-Copy_command007 |
|
558 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0009-001-Copy_command008 |
|
559 |
COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0009-001-Copy_command009 |
|
560 |
COMMAND CFileMan1 ~ |
|
561 |
COMMAND RFs1 ~ |
|
562 |
END_TEST_BLOCK |
|
563 |
START_TEST_BLOCK 2000 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
564 |
CREATE_OBJECT RFs RFs1 |
|
565 |
CREATE_OBJECT TEntry TEntry1 |
|
566 |
CREATE_OBJECT CDir CDir1 |
|
567 |
CREATE_OBJECT CDir CDir2 |
|
568 |
COMMAND RFs1 new |
|
569 |
COMMAND RFs1 Connect |
|
570 |
COMMAND RFs1 GetDir PBASE-F32-Dir-PublicApi-0009-002-GetDir_command006 |
|
571 |
COMMAND TEntry1 new |
|
572 |
COMMAND CDir1 Sort PBASE-F32-Dir-PublicApi-0009-002-Sort_command008 |
|
573 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0009-002-index_command009 |
|
574 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0009-002-index_command010 |
|
575 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0009-002-index_command011 |
|
576 |
COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0009-002-index_command012 |
|
577 |
COMMAND CDir2 ~ |
|
578 |
COMMAND CDir1 ~ |
|
579 |
COMMAND TEntry1 ~ |
|
580 |
COMMAND RFs1 ~ |
|
581 |
END_TEST_BLOCK |
|
582 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
583 |
CREATE_OBJECT RFs RFs1 |
|
584 |
CREATE_OBJECT CFileMan CFileMan1 |
|
585 |
COMMAND RFs1 new |
|
586 |
COMMAND RFs1 Connect |
|
587 |
COMMAND CFileMan1 NewL PBASE-F32-Dir-PublicApi-0009-003-NewL_command004 |
|
588 |
COMMAND CFileMan1 Delete PBASE-F32-Dir-PublicApi-0009-003-Delete_command005 |
|
589 |
COMMAND RFs1 RmDir PBASE-F32-Dir-PublicApi-0009-003-RmDir_command006 |
|
590 |
COMMAND CFileMan1 ~ |
|
591 |
COMMAND RFs1 ~ |
|
592 |
END_TEST_BLOCK |
|
593 |
END_TESTCASE PBASE-F32-Dir-PublicApi-0009 |
|
594 |
||
595 |
||
596 |
START_TESTCASE PBASE-F32-Dir-PublicApi-0010 |
|
597 |
//! @SYMTestCaseID PBASE-F32-Dir-PublicApi-0010 |
|
598 |
//! @SYMAPI CDir |
|
599 |
//! @SYMTestCaseDesc Function Sort(TUint aEntrySortKey) test, that sorts the array of directory entries by placing directories in the order |
|
600 |
//! they occur. |
|
601 |
//! Uses API elements: Sort(), operator[](). |
|
602 |
//! @SYMTestActions 1.Create a RFs session and call it's Connect() function. |
|
603 |
//! 2.Make three directories, passing names BBDir, CCDir and AADir as parameters. |
|
604 |
//! 3.Call RFs::GetDir(const TDesC &aName, TUint anEntryAttMask, TUint anEntrySortKey, CDir *&anEntryList, CDir |
|
605 |
//! *&aDirList), and <RAM_DRIVE>:\<RELATIVE_PATH>\Dir\ (containing 3 folders: AADir, BBDir, CCDir) as first parameter, KEntryAttMaskSupported |
|
606 |
//! as second parameter, ESortNone as third parameter, CDir pointer as fourth and fifth parameter. |
|
607 |
//! 4.Create new TEntry object. |
|
608 |
//! 5.Call CDir::Sort() and EDirDescending|EDirsFirst as parameter. |
|
609 |
//! 6.Call operator[]() on the second CDir object to verify the sorting result. |
|
610 |
//! 7.Remove previously created directories. |
|
611 |
//! @SYMTestStatus Implemented |
|
612 |
//! @SYMTestPriority Critical |
|
613 |
//! @SYMTestExpectedResults Returns KErrNone. |
|
614 |
//! @SYMTestType CIT |
|
615 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
616 |
CREATE_OBJECT RFs RFs1 |
|
617 |
COMMAND RFs1 new |
|
618 |
COMMAND RFs1 Connect |
|
619 |
COMMAND RFs1 MkDirAll PBASE-F32-Dir-PublicApi-0010-001-MkDirAll_command003 |
|
620 |
COMMAND RFs1 ~ |
|
621 |
END_TEST_BLOCK |
|
622 |
START_TEST_BLOCK 2000 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
623 |
CREATE_OBJECT RFs RFs1 |
|
624 |
CREATE_OBJECT TEntry TEntry1 |
|
625 |
CREATE_OBJECT CDir CDir1 |
|
626 |
CREATE_OBJECT CDir CDir2 |
|
627 |
COMMAND RFs1 new |
|
628 |
COMMAND RFs1 Connect |
|
629 |
COMMAND RFs1 MkDirAll PBASE-F32-Dir-PublicApi-0010-002-MkDirAll_command006 |
|
630 |
COMMAND RFs1 MkDirAll PBASE-F32-Dir-PublicApi-0010-002-MkDirAll_command007 |
|
631 |
COMMAND RFs1 MkDirAll PBASE-F32-Dir-PublicApi-0010-002-MkDirAll_command008 |
|
632 |
COMMAND RFs1 GetDir PBASE-F32-Dir-PublicApi-0010-002-GetDir_command009 |
|
633 |
COMMAND TEntry1 new |
|
634 |
COMMAND CDir2 Sort PBASE-F32-Dir-PublicApi-0010-002-Sort_command011 |
|
635 |
COMMAND CDir2 [] PBASE-F32-Dir-PublicApi-0010-002-index_command012 |
|
636 |
COMMAND CDir2 [] PBASE-F32-Dir-PublicApi-0010-002-index_command013 |
|
637 |
COMMAND CDir2 [] PBASE-F32-Dir-PublicApi-0010-002-index_command014 |
|
638 |
COMMAND RFs1 RmDir PBASE-F32-Dir-PublicApi-0010-002-RmDir_command015 |
|
639 |
COMMAND RFs1 RmDir PBASE-F32-Dir-PublicApi-0010-002-RmDir_command016 |
|
640 |
COMMAND RFs1 RmDir PBASE-F32-Dir-PublicApi-0010-002-RmDir_command017 |
|
641 |
COMMAND CDir2 ~ |
|
642 |
COMMAND CDir1 ~ |
|
643 |
COMMAND TEntry1 ~ |
|
644 |
COMMAND RFs1 ~ |
|
645 |
END_TEST_BLOCK |
|
646 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
647 |
CREATE_OBJECT RFs RFs1 |
|
648 |
COMMAND RFs1 new |
|
649 |
COMMAND RFs1 Connect |
|
650 |
COMMAND RFs1 RmDir PBASE-F32-Dir-PublicApi-0010-003-RmDir_command003 |
|
651 |
COMMAND RFs1 ~ |
|
652 |
END_TEST_BLOCK |
|
653 |
END_TESTCASE PBASE-F32-Dir-PublicApi-0010 |
|
654 |
||
655 |
||
656 |
||
657 |
||
658 |
////////////////////////////////////////////////////////////////////// |
|
659 |
////////////////////////////////////////////////////////////////////// |
|
660 |
////// ////// |
|
661 |
////// /////////////////////////////////// ////// |
|
662 |
////// /// /// ////// |
|
663 |
////// /// NEGATIVE TESTS /// ////// |
|
664 |
////// /// /// ////// |
|
665 |
////// /////////////////////////////////// ////// |
|
666 |
////// ////// |
|
667 |
////////////////////////////////////////////////////////////////////// |
|
668 |
////////////////////////////////////////////////////////////////////// |
|
669 |
||
670 |
||
671 |
//////// |
|
672 |
//COUNT |
|
673 |
//////// |
|
674 |
||
675 |
//////////// |
|
676 |
//OPERATOR[] |
|
677 |
//////////// |
|
678 |
||
679 |
//! START_TESTCASE PBASE-F32-Dir-PublicApi-0101 |
|
680 |
//! @SYMTestCaseID PBASE-F32-Dir-PublicApi-0101 |
|
681 |
//! @SYMAPI CDir |
|
682 |
//! @SYMTestCaseDesc operator const TEntry &operator[](TInt anIndex) const negative test that tries to take 50th entry from the array of |
|
683 |
//! directory entries. |
|
684 |
//! Uses API elements: operator[](). |
|
685 |
//! @SYMTestActions 1.Create a RFs session and call it's Connect() function. |
|
686 |
//! 2.Call RFs::GetDir(const TDesC &aName, TUint anEntryAttMask, TUint anEntrySortKey, CDir *&anEntryList), and |
|
687 |
//! <RAM_DRIVE>:\<RELATIVE_PATH>\Dir\ (containing 1 file: Test1.txt) as first parameter, KEntryAttHidden as second parameter, ESortByName as |
|
688 |
//! third parameter, CDir pointer as fourth parameter. |
|
689 |
//! 3.Create new TEntry object. |
|
690 |
//! 4.Call CDir::operator[]() and pass 50 as parameter. |
|
691 |
//! @SYMTestStatus Implemented |
|
692 |
//! @SYMTestPriority Critical |
|
693 |
//! @SYMTestExpectedResults E32USER-CBase = 21 panic |
|
694 |
//! @SYMTestType CIT |
|
695 |
//! START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
696 |
//! CREATE_OBJECT RFs RFs1 |
|
697 |
//! CREATE_OBJECT CFileMan CFileMan1 |
|
698 |
//! COMMAND RFs1 new |
|
699 |
//! COMMAND RFs1 Connect |
|
700 |
//! COMMAND RFs1 MkDirAll PBASE-F32-Dir-PublicApi-0101-001-MkDirAll_command004 |
|
701 |
//! COMMAND CFileMan1 NewL PBASE-F32-Dir-PublicApi-0101-001-NewL_command005 |
|
702 |
//! COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0101-001-Copy_command006 |
|
703 |
//! COMMAND CFileMan1 ~ |
|
704 |
//! COMMAND RFs1 ~ |
|
705 |
//! END_TEST_BLOCK |
|
706 |
//! START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
707 |
//! CREATE_OBJECT RFs RFs1 |
|
708 |
//! CREATE_OBJECT TEntry TEntry1 |
|
709 |
//! CREATE_OBJECT CDir CDir1 |
|
710 |
//! COMMAND RFs1 new |
|
711 |
//! COMMAND RFs1 Connect |
|
712 |
//! COMMAND RFs1 GetDir PBASE-F32-Dir-PublicApi-0101-002-GetDir_command005 |
|
713 |
//! COMMAND TEntry1 new |
|
714 |
//! COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0101-002-index_command007 |
|
715 |
//! COMMAND CDir1 ~ |
|
716 |
//! COMMAND TEntry1 ~ |
|
717 |
//! COMMAND RFs1 ~ |
|
718 |
//! END_TEST_BLOCK !PanicCode=21 !PanicString=E32USER-CBase |
|
719 |
//! START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
720 |
//! CREATE_OBJECT RFs RFs1 |
|
721 |
//! CREATE_OBJECT CFileMan CFileMan1 |
|
722 |
//! COMMAND RFs1 new |
|
723 |
//! COMMAND RFs1 Connect |
|
724 |
//! COMMAND CFileMan1 NewL PBASE-F32-Dir-PublicApi-0101-003-NewL_command004 |
|
725 |
//! COMMAND CFileMan1 Delete PBASE-F32-Dir-PublicApi-0101-003-Delete_command005 |
|
726 |
//! COMMAND RFs1 RmDir PBASE-F32-Dir-PublicApi-0101-003-RmDir_command006 |
|
727 |
//! COMMAND CFileMan1 ~ |
|
728 |
//! COMMAND RFs1 ~ |
|
729 |
//! END_TEST_BLOCK |
|
730 |
//! END_TESTCASE PBASE-F32-Dir-PublicApi-0101 |
|
731 |
||
732 |
||
733 |
//! START_TESTCASE PBASE-F32-Dir-PublicApi-0102 |
|
734 |
//! @SYMTestCaseID PBASE-F32-Dir-PublicApi-0102 |
|
735 |
//! @SYMAPI CDir |
|
736 |
//! @SYMTestCaseDesc operator const TEntry &operator[](TInt anIndex) const negative test, that tries to take entry with index -1 from the |
|
737 |
//! array of directory entries. |
|
738 |
//! Uses API elements: operator[](). |
|
739 |
//! @SYMTestActions 1.Create a RFs session and call it's Connect() function. |
|
740 |
//! 2.Call RFs::GetDir(const TDesC &aName, TUint anEntryAttMask, TUint anEntrySortKey, CDir *&anEntryList), and |
|
741 |
//! <RAM_DRIVE>:\<RELATIVE_PATH>\Dir\ (containing 1 file: Test1.txt) as first parameter, KEntryAttHidden as second parameter, ESortByName as |
|
742 |
//! third parameter, CDir pointer as fourth parameter. |
|
743 |
//! 3.Create new TEntry object. |
|
744 |
//! 4.Call CDir::operator[]() and pass -1 as parameter. |
|
745 |
//! @SYMTestStatus Implemented |
|
746 |
//! @SYMTestPriority Critical |
|
747 |
//! @SYMTestExpectedResults E32USER-CBase = 21 panic |
|
748 |
//! @SYMTestType CIT |
|
749 |
//! START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
750 |
//! CREATE_OBJECT RFs RFs1 |
|
751 |
//! CREATE_OBJECT CFileMan CFileMan1 |
|
752 |
//! COMMAND RFs1 new |
|
753 |
//! COMMAND RFs1 Connect |
|
754 |
//! COMMAND RFs1 MkDirAll PBASE-F32-Dir-PublicApi-0102-001-MkDirAll_command004 |
|
755 |
//! COMMAND CFileMan1 NewL PBASE-F32-Dir-PublicApi-0102-001-NewL_command005 |
|
756 |
//! COMMAND CFileMan1 Copy PBASE-F32-Dir-PublicApi-0102-001-Copy_command006 |
|
757 |
//! COMMAND CFileMan1 ~ |
|
758 |
//! COMMAND RFs1 ~ |
|
759 |
//! END_TEST_BLOCK |
|
760 |
//! START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
761 |
//! CREATE_OBJECT RFs RFs1 |
|
762 |
//! CREATE_OBJECT TEntry TEntry1 |
|
763 |
//! CREATE_OBJECT CDir CDir1 |
|
764 |
//! COMMAND RFs1 new |
|
765 |
//! COMMAND RFs1 Connect |
|
766 |
//! COMMAND RFs1 GetDir PBASE-F32-Dir-PublicApi-0102-002-GetDir_command005 |
|
767 |
//! COMMAND TEntry1 new |
|
768 |
//! COMMAND CDir1 [] PBASE-F32-Dir-PublicApi-0102-002-index_command007 |
|
769 |
//! COMMAND CDir1 ~ |
|
770 |
//! COMMAND TEntry1 ~ |
|
771 |
//! COMMAND RFs1 ~ |
|
772 |
//! END_TEST_BLOCK !PanicCode=21 !PanicString=E32USER-CBase |
|
773 |
//! START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-Dir-PublicApi.ini |
|
774 |
//! CREATE_OBJECT RFs RFs1 |
|
775 |
//! CREATE_OBJECT CFileMan CFileMan1 |
|
776 |
//! COMMAND RFs1 new |
|
777 |
//! COMMAND RFs1 Connect |
|
778 |
//! COMMAND CFileMan1 NewL PBASE-F32-Dir-PublicApi-0102-003-NewL_command004 |
|
779 |
//! COMMAND CFileMan1 Delete PBASE-F32-Dir-PublicApi-0102-003-Delete_command005 |
|
780 |
//! COMMAND RFs1 RmDir PBASE-F32-Dir-PublicApi-0102-003-RmDir_command006 |
|
781 |
//! COMMAND CFileMan1 ~ |
|
782 |
//! COMMAND RFs1 ~ |
|
783 |
//! END_TEST_BLOCK |
|
784 |
//! END_TESTCASE PBASE-F32-Dir-PublicApi-0102 |