sl@0
|
1 |
//
|
sl@0
|
2 |
// Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
|
sl@0
|
3 |
// All rights reserved.
|
sl@0
|
4 |
// This component and the accompanying materials are made available
|
sl@0
|
5 |
// under the terms of "Eclipse Public License v1.0"
|
sl@0
|
6 |
// which accompanies this distribution, and is available
|
sl@0
|
7 |
// at the URL "http://www.eclipse.org/legal/epl-v10.html".
|
sl@0
|
8 |
//
|
sl@0
|
9 |
// Initial Contributors:
|
sl@0
|
10 |
// Nokia Corporation - initial contribution.
|
sl@0
|
11 |
//
|
sl@0
|
12 |
// Contributors:
|
sl@0
|
13 |
//
|
sl@0
|
14 |
// Description:
|
sl@0
|
15 |
//
|
sl@0
|
16 |
//! @file
|
sl@0
|
17 |
//! @SYMTestSuiteName pbase-f32-sfsrv-publicapi-ram
|
sl@0
|
18 |
//! @SYMScriptTestEnvironment This test script requires a basic ROM.
|
sl@0
|
19 |
//! @SYMScriptAuthor Alvar Udras
|
sl@0
|
20 |
//! @SYMScriptDescription The test script contains API tests for the following functions of RFile class:
|
sl@0
|
21 |
//! TInt Open(RFs &aFs, const TDesC &aName, TUint aFileMode);
|
sl@0
|
22 |
//! void Close();
|
sl@0
|
23 |
//! TInt Create(RFs &aFs, const TDesC &aName, TUint aFileMode);
|
sl@0
|
24 |
//! TInt Replace(RFs &aFs, const TDesC &aName, TUint aFileMode);
|
sl@0
|
25 |
//! TInt Temp(RFs &aFs, const TDesC &aPath, TFileName &aName, TUint aFileMode);
|
sl@0
|
26 |
//! TInt Read(TDes8 &aDes) const;
|
sl@0
|
27 |
//! void Read(TDes8 &aDes, TRequestStatus &aStatus) const;
|
sl@0
|
28 |
//! TInt Read(TDes8 &aDes, TInt aLength) const;
|
sl@0
|
29 |
//! void Read(TDes8 &aDes, TInt aLength, TRequestStatus &aStatus) const;
|
sl@0
|
30 |
//! TInt Read(TInt aPos, TDes8 &aDes) const;
|
sl@0
|
31 |
//! void Read(TInt aPos, TDes8 &aDes, TRequestStatus &aStatus) const;
|
sl@0
|
32 |
//! TInt Read(TInt aPos, TDes8 &aDes, TInt aLength) const;
|
sl@0
|
33 |
//! void Read(TInt aPos, TDes8 &aDes, TInt aLength, TRequestStatus &aStatus) const;
|
sl@0
|
34 |
//! void ReadCancel(TRequestStatus &aStatus) const;
|
sl@0
|
35 |
//! void ReadCancel() const;
|
sl@0
|
36 |
//! TInt Write(const TDesC8 &aDes);
|
sl@0
|
37 |
//! void Write(const TDesC8 &aDes, TRequestStatus &aStatus);
|
sl@0
|
38 |
//! TInt Write(const TDesC8 &aDes, TInt aLength);
|
sl@0
|
39 |
//! void Write(const TDesC8 &aDes, TInt aLength, TRequestStatus &aStatus);
|
sl@0
|
40 |
//! TInt Write(TInt aPos, const TDesC8 &aDes);
|
sl@0
|
41 |
//! void Write(TInt aPos, const TDesC8 &aDes, TRequestStatus &aStatus);
|
sl@0
|
42 |
//! TInt Write(TInt aPos, const TDesC8 &aDes, TInt aLength);
|
sl@0
|
43 |
//! void Write(TInt aPos, const TDesC8 &aDes, TInt aLength, TRequestStatus &aStatus);
|
sl@0
|
44 |
//! TInt Lock(TInt aPos, TInt aLength) const;
|
sl@0
|
45 |
//! TInt UnLock(TInt aPos, TInt aLength) const;
|
sl@0
|
46 |
//! TInt Seek(TSeek aMode, TInt &aPos) const;
|
sl@0
|
47 |
//! TInt Flush();
|
sl@0
|
48 |
//! void Flush(TRequestStatus &aStatus);
|
sl@0
|
49 |
//! TInt Size(TInt &aSize) const;
|
sl@0
|
50 |
//! TInt SetSize(TInt aSize);
|
sl@0
|
51 |
//! TInt Att(TUint &aAttValue) const;
|
sl@0
|
52 |
//! TInt SetAtt(TUint aSetAttMask, TUint aClearAttMask);
|
sl@0
|
53 |
//! TInt Modified(TTime &aTime) const;
|
sl@0
|
54 |
//! TInt SetModified(const TTime &aTime);
|
sl@0
|
55 |
//! TInt Set(const TTime &aTime, TUint aSetAttMask, TUint aClearAttMask);
|
sl@0
|
56 |
//! TInt ChangeMode(TFileMode aNewMode);
|
sl@0
|
57 |
//! TInt Rename(const TDesC &aNewName);
|
sl@0
|
58 |
//! TInt Drive(TInt &aDriveNumber, TDriveInfo &aDriveInfo) const;
|
sl@0
|
59 |
//! TInt Name(TDes &aName) const;
|
sl@0
|
60 |
//! TInt Duplicate(const RFile &aFile, TOwnerType aType=EOwnerProcess);
|
sl@0
|
61 |
//! TInt FullName(TDes &aName) const;
|
sl@0
|
62 |
|
sl@0
|
63 |
LOAD_SUITE T_SfSrv
|
sl@0
|
64 |
DELAY 1000
|
sl@0
|
65 |
|
sl@0
|
66 |
|
sl@0
|
67 |
START_TESTCASE PBASE-F32-File-PublicApi-Install
|
sl@0
|
68 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-Install
|
sl@0
|
69 |
//! @SYMAPI RFile
|
sl@0
|
70 |
//! @SYMTestCaseDesc Setup the Environment to test RFile APIs by creating directories.
|
sl@0
|
71 |
//! @SYMTestActions 1. Rfs::New() to create Rfs Object.
|
sl@0
|
72 |
//! 2. Rfs::MkDirAll() to create directories required.
|
sl@0
|
73 |
//! @SYMTestStatus Implemented
|
sl@0
|
74 |
//! @SYMTestPriority Critical
|
sl@0
|
75 |
//! @SYMTestExpectedResults Directories get created.
|
sl@0
|
76 |
//!
|
sl@0
|
77 |
//! @SYMTestType CIT
|
sl@0
|
78 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
79 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
80 |
COMMAND RFs1 new
|
sl@0
|
81 |
COMMAND RFs1 Connect
|
sl@0
|
82 |
COMMAND RFs1 MkDirAll PBASE-F32-File-PublicApi-Install
|
sl@0
|
83 |
COMMAND RFs1 ~
|
sl@0
|
84 |
END_TEST_BLOCK
|
sl@0
|
85 |
END_TESTCASE PBASE-F32-File-PublicApi-Install
|
sl@0
|
86 |
|
sl@0
|
87 |
|
sl@0
|
88 |
START_TESTCASE PBASE-F32-File-PublicApi-0001
|
sl@0
|
89 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0001
|
sl@0
|
90 |
//! @SYMAPI RFile
|
sl@0
|
91 |
//! @SYMTestCaseDesc Function Open() test. Open a file and close it.
|
sl@0
|
92 |
//! Uses API elements: Open().
|
sl@0
|
93 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
94 |
//! 2. Call Replace passing "{Drives, RAMDriveTestPath}file\tc0001.txt", EFileShareAny | EFileWrite
|
sl@0
|
95 |
//! 3. Write "open test" to file.
|
sl@0
|
96 |
//! 4. Close file.
|
sl@0
|
97 |
//! 5. Open file "{Drives, RAMDriveTestPath}file\tc0001.txt", with EFileRead
|
sl@0
|
98 |
//! 6. Read from file to determine, that the file is opened.
|
sl@0
|
99 |
//! 7. Close file.
|
sl@0
|
100 |
//! 8. Delete file.
|
sl@0
|
101 |
//! 9. Close file system.
|
sl@0
|
102 |
//!
|
sl@0
|
103 |
//! @SYMTestStatus Implemented
|
sl@0
|
104 |
//! @SYMTestPriority Critical
|
sl@0
|
105 |
//! @SYMTestExpectedResults RFile::Open() returns KErrNone. File is opened after Open call.
|
sl@0
|
106 |
//!
|
sl@0
|
107 |
//! @SYMTestType CIT
|
sl@0
|
108 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
109 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
110 |
CREATE_OBJECT RFile file
|
sl@0
|
111 |
COMMAND RFs1 new
|
sl@0
|
112 |
COMMAND RFs1 Connect
|
sl@0
|
113 |
COMMAND file new
|
sl@0
|
114 |
COMMAND file Replace PBASE-F32-File-PublicApi-0001-001-Replace_command005
|
sl@0
|
115 |
COMMAND file Write PBASE-F32-File-PublicApi-0001-001-Write_command006
|
sl@0
|
116 |
COMMAND file Close
|
sl@0
|
117 |
COMMAND file Open PBASE-F32-File-PublicApi-0001-001-Open_command008
|
sl@0
|
118 |
COMMAND file Read PBASE-F32-File-PublicApi-0001-001-Read_command009
|
sl@0
|
119 |
COMMAND file Close
|
sl@0
|
120 |
COMMAND file ~
|
sl@0
|
121 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0001-001-Delete_command013
|
sl@0
|
122 |
COMMAND RFs1 ~
|
sl@0
|
123 |
END_TEST_BLOCK
|
sl@0
|
124 |
END_TESTCASE PBASE-F32-File-PublicApi-0001
|
sl@0
|
125 |
|
sl@0
|
126 |
|
sl@0
|
127 |
//FileModes - EFileRead
|
sl@0
|
128 |
|
sl@0
|
129 |
|
sl@0
|
130 |
START_TESTCASE PBASE-F32-File-PublicApi-4001
|
sl@0
|
131 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-4001
|
sl@0
|
132 |
//! @SYMAPI RFile
|
sl@0
|
133 |
//! @SYMTestCaseDesc Function TFileMode::EFileRead test. open file for reading and try to write to it.
|
sl@0
|
134 |
//! Uses API elements: Open().
|
sl@0
|
135 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
136 |
//! 2. Call Replace passing "{Drives, RAMDriveTestPath}file\tc4001.txt", EFileShareAny | EFileWrite
|
sl@0
|
137 |
//! 3. Close file.
|
sl@0
|
138 |
//! 4. Open file "{Drives, RAMDriveTestPath}file\tc4001.txt", with EFileRead
|
sl@0
|
139 |
//! 5. Write "test" to file.
|
sl@0
|
140 |
//! 6. Close file.
|
sl@0
|
141 |
//! 7. Delete file.
|
sl@0
|
142 |
//! 8. Close file system.
|
sl@0
|
143 |
//!
|
sl@0
|
144 |
//! @SYMTestStatus Implemented
|
sl@0
|
145 |
//! @SYMTestPriority Critical
|
sl@0
|
146 |
//! @SYMTestExpectedResults RFile::Write returns KErrAccessDenied.
|
sl@0
|
147 |
//!
|
sl@0
|
148 |
//! @SYMTestType CIT
|
sl@0
|
149 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
150 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
151 |
CREATE_OBJECT RFile file
|
sl@0
|
152 |
COMMAND RFs1 new
|
sl@0
|
153 |
COMMAND RFs1 Connect
|
sl@0
|
154 |
COMMAND file new
|
sl@0
|
155 |
COMMAND file Replace PBASE-F32-File-PublicApi-4001-001-Replace_command005
|
sl@0
|
156 |
COMMAND file Close
|
sl@0
|
157 |
COMMAND file Open PBASE-F32-File-PublicApi-4001-001-Open_command007
|
sl@0
|
158 |
COMMAND !Error=-21 file Write PBASE-F32-File-PublicApi-4001-001-Write_command008
|
sl@0
|
159 |
COMMAND file Close
|
sl@0
|
160 |
COMMAND file ~
|
sl@0
|
161 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-4001-001-Delete_command012
|
sl@0
|
162 |
COMMAND RFs1 ~
|
sl@0
|
163 |
END_TEST_BLOCK
|
sl@0
|
164 |
END_TESTCASE PBASE-F32-File-PublicApi-4001
|
sl@0
|
165 |
|
sl@0
|
166 |
|
sl@0
|
167 |
//EFileShareExclusive
|
sl@0
|
168 |
|
sl@0
|
169 |
|
sl@0
|
170 |
START_TESTCASE PBASE-F32-File-PublicApi-4002
|
sl@0
|
171 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-4002
|
sl@0
|
172 |
//! @SYMAPI RFile
|
sl@0
|
173 |
//! @SYMTestCaseDesc Function TFileMode::EFileShareExclusive test. Open a file in EFileShareExclusive and try to open the same file through another handle.
|
sl@0
|
174 |
//! Uses API elements: Open().
|
sl@0
|
175 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
176 |
//! 2. Call Replace passing "{Drives, RAMDriveTestPath}file\tc4002.txt", EFileShareAny | EFileWrite.
|
sl@0
|
177 |
//! 3. Close file.
|
sl@0
|
178 |
//! 4. Open file "{Drives, RAMDriveTestPath}file\tc4002.txt", with EFileShareExclusive
|
sl@0
|
179 |
//! 5. Open "{Drives, RAMDriveTestPath}file\tc4002.txt" through new handle called file2, with EFileShareExlusive
|
sl@0
|
180 |
//! 6. Close file.
|
sl@0
|
181 |
//! 7. Delete file.
|
sl@0
|
182 |
//! 8. Close file system.
|
sl@0
|
183 |
//!
|
sl@0
|
184 |
//! @SYMTestStatus Implemented
|
sl@0
|
185 |
//! @SYMTestPriority Critical
|
sl@0
|
186 |
//! @SYMTestExpectedResults RFile::Open returns KErrInUse.
|
sl@0
|
187 |
//!
|
sl@0
|
188 |
//! @SYMTestType CIT
|
sl@0
|
189 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
190 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
191 |
CREATE_OBJECT RFile file
|
sl@0
|
192 |
CREATE_OBJECT RFile file2
|
sl@0
|
193 |
COMMAND RFs1 new
|
sl@0
|
194 |
COMMAND RFs1 Connect
|
sl@0
|
195 |
COMMAND file new
|
sl@0
|
196 |
COMMAND file Replace PBASE-F32-File-PublicApi-4002-001-Replace_command005
|
sl@0
|
197 |
COMMAND file Close
|
sl@0
|
198 |
COMMAND file Open PBASE-F32-File-PublicApi-4002-001-Open_command007
|
sl@0
|
199 |
COMMAND file2 new
|
sl@0
|
200 |
COMMAND !Error=-14 file2 Open PBASE-F32-File-PublicApi-4002-001-Open_command010
|
sl@0
|
201 |
COMMAND file2 Close
|
sl@0
|
202 |
COMMAND file2 ~
|
sl@0
|
203 |
COMMAND file Close
|
sl@0
|
204 |
COMMAND file ~
|
sl@0
|
205 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-4002-001-Delete_command017
|
sl@0
|
206 |
COMMAND RFs1 ~
|
sl@0
|
207 |
END_TEST_BLOCK
|
sl@0
|
208 |
END_TESTCASE PBASE-F32-File-PublicApi-4002
|
sl@0
|
209 |
|
sl@0
|
210 |
|
sl@0
|
211 |
//EFileShareReadersOnly
|
sl@0
|
212 |
|
sl@0
|
213 |
|
sl@0
|
214 |
START_TESTCASE PBASE-F32-File-PublicApi-4003
|
sl@0
|
215 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-4003
|
sl@0
|
216 |
//! @SYMAPI RFile
|
sl@0
|
217 |
//! @SYMTestCaseDesc Function TFileMode::EFileShareReadersOnly test. Open a file in EFileShareReadersOnly and try to write to it through another handle.
|
sl@0
|
218 |
//! Uses API elements: Open().
|
sl@0
|
219 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
220 |
//! 2. Call Replace passing "{Drives, RAMDriveTestPath}file\tc4003.txt", EFileShareAny | EFileWrite
|
sl@0
|
221 |
//! 3. Write "open test" to file.
|
sl@0
|
222 |
//! 4. Close file.
|
sl@0
|
223 |
//! 5. Open file "{Drives, RAMDriveTestPath}file\tc4003.txt", with EFileShareReadersOnly
|
sl@0
|
224 |
//! 6. Open "{Drives, RAMDriveTestPath}file\tc4003.txt" through new handle called file2 EFileRead.
|
sl@0
|
225 |
//! 7. Read from file.
|
sl@0
|
226 |
//! 8. Try to write "will cause error" to file.
|
sl@0
|
227 |
//! 9. Close file.
|
sl@0
|
228 |
//! 10. Delete file.
|
sl@0
|
229 |
//! 11. Close file system.
|
sl@0
|
230 |
//!
|
sl@0
|
231 |
//! @SYMTestStatus Implemented
|
sl@0
|
232 |
//! @SYMTestPriority Critical
|
sl@0
|
233 |
//! @SYMTestExpectedResults RFile::Write returns KErrAccessDenied.
|
sl@0
|
234 |
//!
|
sl@0
|
235 |
//! @SYMTestType CIT
|
sl@0
|
236 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
237 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
238 |
CREATE_OBJECT RFile file
|
sl@0
|
239 |
CREATE_OBJECT RFile file2
|
sl@0
|
240 |
COMMAND RFs1 new
|
sl@0
|
241 |
COMMAND RFs1 Connect
|
sl@0
|
242 |
COMMAND file new
|
sl@0
|
243 |
COMMAND file Replace PBASE-F32-File-PublicApi-4003-001-Replace_command005
|
sl@0
|
244 |
COMMAND file Write PBASE-F32-File-PublicApi-4003-001-Write_command006
|
sl@0
|
245 |
COMMAND file Close
|
sl@0
|
246 |
COMMAND file Open PBASE-F32-File-PublicApi-4003-001-Open_command008
|
sl@0
|
247 |
COMMAND file2 new
|
sl@0
|
248 |
COMMAND file2 Open PBASE-F32-File-PublicApi-4003-001-Open_command011
|
sl@0
|
249 |
COMMAND file2 Read PBASE-F32-File-PublicApi-4003-001-Read_command012
|
sl@0
|
250 |
COMMAND !Error=-21 file2 Write PBASE-F32-File-PublicApi-4003-001-Write_command013
|
sl@0
|
251 |
COMMAND file2 Close
|
sl@0
|
252 |
COMMAND file2 ~
|
sl@0
|
253 |
COMMAND file Close
|
sl@0
|
254 |
COMMAND file ~
|
sl@0
|
255 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-4003-001-Delete_command020
|
sl@0
|
256 |
COMMAND RFs1 ~
|
sl@0
|
257 |
END_TEST_BLOCK
|
sl@0
|
258 |
END_TESTCASE PBASE-F32-File-PublicApi-4003
|
sl@0
|
259 |
|
sl@0
|
260 |
|
sl@0
|
261 |
//EFileShareAny
|
sl@0
|
262 |
|
sl@0
|
263 |
START_TESTCASE PBASE-F32-File-PublicApi-4004
|
sl@0
|
264 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-4004
|
sl@0
|
265 |
//! @SYMAPI RFile
|
sl@0
|
266 |
//! @SYMTestCaseDesc Function TFileMode::EFileShareAny test. Open a file in EFileShareAny and try to write to it through another handle.
|
sl@0
|
267 |
//! Uses API elements: Open().
|
sl@0
|
268 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
269 |
//! 2. Call Replace passing "{Drives, RAMDriveTestPath}file\tc4004.txt", EFileShareAny | EFileWrite
|
sl@0
|
270 |
//! 3. Write "open test" to file.
|
sl@0
|
271 |
//! 4. Close file.
|
sl@0
|
272 |
//! 5. Open file "{Drives, RAMDriveTestPath}file\tc4004.txt", with EFileShareAny.
|
sl@0
|
273 |
//! 6. Open "{Drives, RAMDriveTestPath}file\tc4004.txt" through new handle called file2 EFileShareAny | EFileWrite.
|
sl@0
|
274 |
//! 7. Read from file.
|
sl@0
|
275 |
//! 8. Try to write "open test" to file.
|
sl@0
|
276 |
//! 9. Close file.
|
sl@0
|
277 |
//! 10. Delete file.
|
sl@0
|
278 |
//! 11. Close file system.
|
sl@0
|
279 |
//!
|
sl@0
|
280 |
//! @SYMTestStatus Implemented
|
sl@0
|
281 |
//! @SYMTestPriority Critical
|
sl@0
|
282 |
//! @SYMTestExpectedResults No error is returned or panic raised.
|
sl@0
|
283 |
//!
|
sl@0
|
284 |
//! @SYMTestType CIT
|
sl@0
|
285 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
286 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
287 |
CREATE_OBJECT RFile file
|
sl@0
|
288 |
CREATE_OBJECT RFile file2
|
sl@0
|
289 |
COMMAND RFs1 new
|
sl@0
|
290 |
COMMAND RFs1 Connect
|
sl@0
|
291 |
COMMAND file new
|
sl@0
|
292 |
COMMAND file Replace PBASE-F32-File-PublicApi-4004-001-Replace_command005
|
sl@0
|
293 |
COMMAND file Write PBASE-F32-File-PublicApi-4004-001-Write_command006
|
sl@0
|
294 |
COMMAND file Close
|
sl@0
|
295 |
COMMAND file Open PBASE-F32-File-PublicApi-4004-001-Open_command008
|
sl@0
|
296 |
COMMAND file2 new
|
sl@0
|
297 |
COMMAND file2 Open PBASE-F32-File-PublicApi-4004-001-Open_command011
|
sl@0
|
298 |
COMMAND file2 Read PBASE-F32-File-PublicApi-4004-001-Read_command012
|
sl@0
|
299 |
COMMAND file2 Write PBASE-F32-File-PublicApi-4004-001-Write_command013
|
sl@0
|
300 |
COMMAND file2 Close
|
sl@0
|
301 |
COMMAND file2 ~
|
sl@0
|
302 |
COMMAND file Close
|
sl@0
|
303 |
COMMAND file ~
|
sl@0
|
304 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-4004-001-Delete_command020
|
sl@0
|
305 |
COMMAND RFs1 ~
|
sl@0
|
306 |
END_TEST_BLOCK
|
sl@0
|
307 |
END_TESTCASE PBASE-F32-File-PublicApi-4004
|
sl@0
|
308 |
|
sl@0
|
309 |
//EFileShareReadersOfWriters
|
sl@0
|
310 |
|
sl@0
|
311 |
START_TESTCASE PBASE-F32-File-PublicApi-4005
|
sl@0
|
312 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-4005
|
sl@0
|
313 |
//! @SYMAPI RFile
|
sl@0
|
314 |
//! @SYMTestCaseDesc Function TFileMode::EFileShareReadersOrWriters test. Open a file in EFileShareReadersOrWriters and try to write to it through another handle.
|
sl@0
|
315 |
//! Uses API elements: Open().
|
sl@0
|
316 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
317 |
//! 2. Call Replace passing "{Drives, RAMDriveTestPath}file\tc4005.txt", EFileShareAny | EFileWrite.
|
sl@0
|
318 |
//! 3. Write "open test" to file.
|
sl@0
|
319 |
//! 4. Close file.
|
sl@0
|
320 |
//! 5. Open file "{Drives, RAMDriveTestPath}file\tc4005.txt", with EFileShareReadersOrWriters | EFileRead.
|
sl@0
|
321 |
//! 6. Open "{Drives, RAMDriveTestPath}file\tc4005.txt" through new handle called file2, EFileShareReadersOrWriters | EFileWrite.
|
sl@0
|
322 |
//! 7. Read from file.
|
sl@0
|
323 |
//! 8. Try to write "open test" to file.
|
sl@0
|
324 |
//! 9. Close file.
|
sl@0
|
325 |
//! 10. Delete file.
|
sl@0
|
326 |
//! 11. Close file system.
|
sl@0
|
327 |
//!
|
sl@0
|
328 |
//! @SYMTestStatus Implemented
|
sl@0
|
329 |
//! @SYMTestPriority Critical
|
sl@0
|
330 |
//! @SYMTestExpectedResults No errors returned or panics raised.
|
sl@0
|
331 |
//!
|
sl@0
|
332 |
//! @SYMTestType CIT
|
sl@0
|
333 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
334 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
335 |
CREATE_OBJECT RFile file
|
sl@0
|
336 |
CREATE_OBJECT RFile file2
|
sl@0
|
337 |
COMMAND RFs1 new
|
sl@0
|
338 |
COMMAND RFs1 Connect
|
sl@0
|
339 |
COMMAND file new
|
sl@0
|
340 |
COMMAND file Replace PBASE-F32-File-PublicApi-4005-001-Replace_command005
|
sl@0
|
341 |
COMMAND file Write PBASE-F32-File-PublicApi-4005-001-Write_command006
|
sl@0
|
342 |
COMMAND file Close
|
sl@0
|
343 |
COMMAND file Open PBASE-F32-File-PublicApi-4005-001-Open_command008
|
sl@0
|
344 |
COMMAND file2 new
|
sl@0
|
345 |
COMMAND file2 Open PBASE-F32-File-PublicApi-4005-001-Open_command011
|
sl@0
|
346 |
COMMAND file2 Read PBASE-F32-File-PublicApi-4005-001-Read_command012
|
sl@0
|
347 |
COMMAND file2 Write PBASE-F32-File-PublicApi-4005-001-Write_command013
|
sl@0
|
348 |
COMMAND file2 Close
|
sl@0
|
349 |
COMMAND file2 ~
|
sl@0
|
350 |
COMMAND file Close
|
sl@0
|
351 |
COMMAND file ~
|
sl@0
|
352 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-4005-001-Delete_command020
|
sl@0
|
353 |
COMMAND RFs1 ~
|
sl@0
|
354 |
END_TEST_BLOCK
|
sl@0
|
355 |
END_TESTCASE PBASE-F32-File-PublicApi-4005
|
sl@0
|
356 |
|
sl@0
|
357 |
START_TESTCASE PBASE-F32-File-PublicApi-0003
|
sl@0
|
358 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0003
|
sl@0
|
359 |
//! @SYMAPI RFile
|
sl@0
|
360 |
//! @SYMTestCaseDesc Function Create() test. Create a file.
|
sl@0
|
361 |
//! Uses API elements: Create().
|
sl@0
|
362 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
363 |
//! 2. Call RFile::Create passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0003.txt", EFileShareAny
|
sl@0
|
364 |
//! 3. Open the file.
|
sl@0
|
365 |
//! 4. Write literal "test created this file" to file.
|
sl@0
|
366 |
//! 5. Close RFile.
|
sl@0
|
367 |
//! 6. Delete file.
|
sl@0
|
368 |
//! 7. Close RFs.
|
sl@0
|
369 |
//!
|
sl@0
|
370 |
//! @SYMTestStatus Implemented
|
sl@0
|
371 |
//! @SYMTestPriority Critical
|
sl@0
|
372 |
//! @SYMTestExpectedResults RFile::Create() returns KErrNone. File is created. No panics raised or errors returned
|
sl@0
|
373 |
//!
|
sl@0
|
374 |
//! @SYMTestType CIT
|
sl@0
|
375 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
376 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
377 |
CREATE_OBJECT RFile file
|
sl@0
|
378 |
COMMAND RFs1 new
|
sl@0
|
379 |
COMMAND RFs1 Connect
|
sl@0
|
380 |
COMMAND file new
|
sl@0
|
381 |
COMMAND file Create PBASE-F32-File-PublicApi-0003-001-Create_command005
|
sl@0
|
382 |
COMMAND file Write PBASE-F32-File-PublicApi-0003-001-Write_command006
|
sl@0
|
383 |
COMMAND file Close
|
sl@0
|
384 |
COMMAND file ~
|
sl@0
|
385 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0003-001-Delete_command010
|
sl@0
|
386 |
COMMAND RFs1 ~
|
sl@0
|
387 |
END_TEST_BLOCK
|
sl@0
|
388 |
END_TESTCASE PBASE-F32-File-PublicApi-0003
|
sl@0
|
389 |
|
sl@0
|
390 |
|
sl@0
|
391 |
START_TESTCASE PBASE-F32-File-PublicApi-0004
|
sl@0
|
392 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0004
|
sl@0
|
393 |
//! @SYMAPI RFile
|
sl@0
|
394 |
//! @SYMTestCaseDesc Function Replace() test. Replace a file.
|
sl@0
|
395 |
//! Uses API elements: Replace().
|
sl@0
|
396 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
397 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0004.txt", EFileWrite
|
sl@0
|
398 |
//! 3. Call RFile::Write passing literal "This file is replaced"
|
sl@0
|
399 |
//! 4. Call Flush on file.
|
sl@0
|
400 |
//! 5. Close file.
|
sl@0
|
401 |
//! 6. Open file.
|
sl@0
|
402 |
//! 7. Read the file.
|
sl@0
|
403 |
//! 8. Close RFile.
|
sl@0
|
404 |
//! 9. Delete file.
|
sl@0
|
405 |
//! 10. Close RFs.
|
sl@0
|
406 |
//!
|
sl@0
|
407 |
//! @SYMTestStatus Implemented
|
sl@0
|
408 |
//! @SYMTestPriority Critical
|
sl@0
|
409 |
//! @SYMTestExpectedResults RFile::Replace returns KErrNone. File contains written literal and nothing else.
|
sl@0
|
410 |
//!
|
sl@0
|
411 |
//! @SYMTestType CIT
|
sl@0
|
412 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
413 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
414 |
CREATE_OBJECT RFile file
|
sl@0
|
415 |
COMMAND RFs1 new
|
sl@0
|
416 |
COMMAND RFs1 Connect
|
sl@0
|
417 |
COMMAND file new
|
sl@0
|
418 |
COMMAND file Replace PBASE-F32-File-PublicApi-0004-001-Replace_command005
|
sl@0
|
419 |
COMMAND file Write PBASE-F32-File-PublicApi-0004-001-Write_command006
|
sl@0
|
420 |
COMMAND file Flush
|
sl@0
|
421 |
COMMAND file Close
|
sl@0
|
422 |
COMMAND file Open PBASE-F32-File-PublicApi-0004-001-Open_command009
|
sl@0
|
423 |
COMMAND file Read
|
sl@0
|
424 |
COMMAND file Close
|
sl@0
|
425 |
COMMAND file ~
|
sl@0
|
426 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0004-001-Delete_command013
|
sl@0
|
427 |
COMMAND RFs1 ~
|
sl@0
|
428 |
END_TEST_BLOCK
|
sl@0
|
429 |
END_TESTCASE PBASE-F32-File-PublicApi-0004
|
sl@0
|
430 |
|
sl@0
|
431 |
|
sl@0
|
432 |
START_TESTCASE PBASE-F32-File-PublicApi-0005
|
sl@0
|
433 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0005
|
sl@0
|
434 |
//! @SYMAPI RFile
|
sl@0
|
435 |
//! @SYMTestCaseDesc Function Temp() test. Create a temporary file.
|
sl@0
|
436 |
//! Uses API elements: Temp().
|
sl@0
|
437 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
438 |
//! 2. Call RFile::Temp passing RFs, literal "{Drives, RAMDriveTestPath}file\", TDesc&, EFileWrite
|
sl@0
|
439 |
//! 3. Call RFile::Write passing literal "This is temporary file"
|
sl@0
|
440 |
//! 4. Rename the file to "tc0005.txt".
|
sl@0
|
441 |
//! 5. Close RFile.
|
sl@0
|
442 |
//! 6. Delete temporary file.
|
sl@0
|
443 |
//! 7. Close RFs.
|
sl@0
|
444 |
//!
|
sl@0
|
445 |
//! @SYMTestStatus Implemented
|
sl@0
|
446 |
//! @SYMTestPriority Critical
|
sl@0
|
447 |
//! @SYMTestExpectedResults RFile::Temp() returns KErrNone, temporary file is created.
|
sl@0
|
448 |
//!
|
sl@0
|
449 |
//! @SYMTestType CIT
|
sl@0
|
450 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
451 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
452 |
CREATE_OBJECT RFile file
|
sl@0
|
453 |
COMMAND RFs1 new
|
sl@0
|
454 |
COMMAND RFs1 Connect
|
sl@0
|
455 |
COMMAND file new
|
sl@0
|
456 |
COMMAND file Temp PBASE-F32-File-PublicApi-0005-001-Temp_command005
|
sl@0
|
457 |
COMMAND file Write PBASE-F32-File-PublicApi-0005-001-Write_command006
|
sl@0
|
458 |
COMMAND file Rename PBASE-F32-File-PublicApi-0005-001-Rename_command007
|
sl@0
|
459 |
COMMAND file Close
|
sl@0
|
460 |
COMMAND file ~
|
sl@0
|
461 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0005-001-Delete_command011
|
sl@0
|
462 |
COMMAND RFs1 ~
|
sl@0
|
463 |
END_TEST_BLOCK
|
sl@0
|
464 |
END_TESTCASE PBASE-F32-File-PublicApi-0005
|
sl@0
|
465 |
|
sl@0
|
466 |
|
sl@0
|
467 |
START_TESTCASE PBASE-F32-File-PublicApi-0006
|
sl@0
|
468 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0006
|
sl@0
|
469 |
//! @SYMAPI RFile
|
sl@0
|
470 |
//! @SYMTestCaseDesc Synchronous Read(TDes8 &aDes) test - will open file and read its contents to a buffer.
|
sl@0
|
471 |
//! Uses API elements: Read().
|
sl@0
|
472 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
473 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0006.txt", EFileWrite
|
sl@0
|
474 |
//! 3. Call RFile::Write passing literal "Synchronous read test!".
|
sl@0
|
475 |
//! 4. Set the file position to 0.
|
sl@0
|
476 |
//! 5. Call RFile::Read().
|
sl@0
|
477 |
//! 6. Close RFile.
|
sl@0
|
478 |
//! 7. Delete file.
|
sl@0
|
479 |
//! 8. Close RFs.
|
sl@0
|
480 |
//!
|
sl@0
|
481 |
//! @SYMTestStatus Implemented
|
sl@0
|
482 |
//! @SYMTestPriority Critical
|
sl@0
|
483 |
//! @SYMTestExpectedResults RFile::Read() returns KErrNone. Data is read and verified.
|
sl@0
|
484 |
//!
|
sl@0
|
485 |
//! @SYMTestType CIT
|
sl@0
|
486 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
487 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
488 |
CREATE_OBJECT RFile file
|
sl@0
|
489 |
COMMAND RFs1 new
|
sl@0
|
490 |
COMMAND RFs1 Connect
|
sl@0
|
491 |
COMMAND file new
|
sl@0
|
492 |
COMMAND file Replace PBASE-F32-File-PublicApi-0006-001-Replace_command005
|
sl@0
|
493 |
COMMAND file Write PBASE-F32-File-PublicApi-0006-001-Write_command006
|
sl@0
|
494 |
COMMAND file Seek PBASE-F32-File-PublicApi-0006-001-Seek_command007
|
sl@0
|
495 |
COMMAND file Read PBASE-F32-File-PublicApi-0006-001-Read_command008
|
sl@0
|
496 |
COMMAND file Close
|
sl@0
|
497 |
COMMAND file ~
|
sl@0
|
498 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0006-001-Delete_command012
|
sl@0
|
499 |
COMMAND RFs1 ~
|
sl@0
|
500 |
END_TEST_BLOCK
|
sl@0
|
501 |
END_TESTCASE PBASE-F32-File-PublicApi-0006
|
sl@0
|
502 |
|
sl@0
|
503 |
|
sl@0
|
504 |
START_TESTCASE PBASE-F32-File-PublicApi-0007
|
sl@0
|
505 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0007
|
sl@0
|
506 |
//! @SYMAPI RFile
|
sl@0
|
507 |
//! @SYMTestCaseDesc Asynchronous Read(TDes8& aDes, TRequestStatus &aStatus) test - will open file and read its contents to a buffer.
|
sl@0
|
508 |
//! Uses API elements: Read().
|
sl@0
|
509 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
510 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0007.txt", EFileWrite.
|
sl@0
|
511 |
//! 3. Call RFile::Write passing literal "asynchronous read test"
|
sl@0
|
512 |
//! 4. Reset file position
|
sl@0
|
513 |
//! 5. Call RFile::Read() passing TRequestStatus.
|
sl@0
|
514 |
//! 6. Wait until asynchronous call completes
|
sl@0
|
515 |
//! 7. Close RFile.
|
sl@0
|
516 |
//! 8. Delete file.
|
sl@0
|
517 |
//! 9. Close RFs.
|
sl@0
|
518 |
//!
|
sl@0
|
519 |
//! @SYMTestStatus Implemented
|
sl@0
|
520 |
//! @SYMTestPriority Critical
|
sl@0
|
521 |
//! @SYMTestExpectedResults The asynchronous read call finishes with KErrNone. Data is read and verified.
|
sl@0
|
522 |
//!
|
sl@0
|
523 |
//! @SYMTestType CIT
|
sl@0
|
524 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
525 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
526 |
CREATE_OBJECT RFile file
|
sl@0
|
527 |
COMMAND RFs1 new
|
sl@0
|
528 |
COMMAND RFs1 Connect
|
sl@0
|
529 |
COMMAND file new
|
sl@0
|
530 |
COMMAND file Replace PBASE-F32-File-PublicApi-0007-001-Replace_command005
|
sl@0
|
531 |
COMMAND file Write PBASE-F32-File-PublicApi-0007-001-Write_command006
|
sl@0
|
532 |
COMMAND file Seek PBASE-F32-File-PublicApi-0007-001-Seek_command007
|
sl@0
|
533 |
COMMAND file Read PBASE-F32-File-PublicApi-0007-001-Read_command008
|
sl@0
|
534 |
OUTSTANDING
|
sl@0
|
535 |
COMMAND file Close
|
sl@0
|
536 |
COMMAND file ~
|
sl@0
|
537 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0007-001-Delete_command012
|
sl@0
|
538 |
COMMAND RFs1 ~
|
sl@0
|
539 |
END_TEST_BLOCK
|
sl@0
|
540 |
END_TESTCASE PBASE-F32-File-PublicApi-0007
|
sl@0
|
541 |
|
sl@0
|
542 |
|
sl@0
|
543 |
START_TESTCASE PBASE-F32-File-PublicApi-0008
|
sl@0
|
544 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0008
|
sl@0
|
545 |
//! @SYMAPI RFile
|
sl@0
|
546 |
//! @SYMTestCaseDesc Synchronous Read(TDes8 &aDes, TInt aLength) test - will open file and read fixed length from its contents to a buffer.
|
sl@0
|
547 |
//! Uses API elements: Read().
|
sl@0
|
548 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
549 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0008.txt", EFileWrite
|
sl@0
|
550 |
//! 3. Write "synchronous read with length test" to file
|
sl@0
|
551 |
//! 4. Reset file position.
|
sl@0
|
552 |
//! 5. Call RFile::Read() passing TDesC, 5 for the length
|
sl@0
|
553 |
//! 6. Close RFile.
|
sl@0
|
554 |
//! 7. Delete file.
|
sl@0
|
555 |
//! 8. Close RFs.
|
sl@0
|
556 |
//!
|
sl@0
|
557 |
//! @SYMTestStatus Implemented
|
sl@0
|
558 |
//! @SYMTestPriority Critical
|
sl@0
|
559 |
//! @SYMTestExpectedResults RFile::Read() returns KErrNone. Data is read and verified.
|
sl@0
|
560 |
//!
|
sl@0
|
561 |
//! @SYMTestType CIT
|
sl@0
|
562 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
563 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
564 |
CREATE_OBJECT RFile file
|
sl@0
|
565 |
COMMAND RFs1 new
|
sl@0
|
566 |
COMMAND RFs1 Connect
|
sl@0
|
567 |
COMMAND file new
|
sl@0
|
568 |
COMMAND file Replace PBASE-F32-File-PublicApi-0008-001-Replace_command005
|
sl@0
|
569 |
COMMAND file Write PBASE-F32-File-PublicApi-0008-001-Write_command006
|
sl@0
|
570 |
COMMAND file Seek PBASE-F32-File-PublicApi-0008-001-Seek_command007
|
sl@0
|
571 |
COMMAND file Read PBASE-F32-File-PublicApi-0008-001-Read_command008
|
sl@0
|
572 |
COMMAND file Close
|
sl@0
|
573 |
COMMAND file ~
|
sl@0
|
574 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0008-001-Delete_command012
|
sl@0
|
575 |
COMMAND RFs1 ~
|
sl@0
|
576 |
END_TEST_BLOCK
|
sl@0
|
577 |
END_TESTCASE PBASE-F32-File-PublicApi-0008
|
sl@0
|
578 |
|
sl@0
|
579 |
|
sl@0
|
580 |
START_TESTCASE PBASE-F32-File-PublicApi-0009
|
sl@0
|
581 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0009
|
sl@0
|
582 |
//! @SYMAPI RFile
|
sl@0
|
583 |
//! @SYMTestCaseDesc Asynchronous Read(TDes8 &aDes, TInt aLength, TRequestStatus &aStatus) test - will open file and read fixed length from its contents to a buffer.
|
sl@0
|
584 |
//! Uses API elements: Read().
|
sl@0
|
585 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
586 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0009.txt", EFileWrite.
|
sl@0
|
587 |
//! 3. Call RFile::Write passing literal "Asynchronous read with length test"
|
sl@0
|
588 |
//! 4. Reset file position
|
sl@0
|
589 |
//! 4. Create TRequestStatus variable.
|
sl@0
|
590 |
//! 5. Call RFile::Read() passing TRequestStatus and 5 for length.
|
sl@0
|
591 |
//! 6. Wait until asynchronous call completes
|
sl@0
|
592 |
//! 7. Close RFile.
|
sl@0
|
593 |
//! 8. Delete file.
|
sl@0
|
594 |
//! 9. Close RFs.
|
sl@0
|
595 |
//!
|
sl@0
|
596 |
//! @SYMTestStatus Implemented
|
sl@0
|
597 |
//! @SYMTestPriority Critical
|
sl@0
|
598 |
//! @SYMTestExpectedResults The asynchronous read call finishes with KErrNone. Data is read and verified.
|
sl@0
|
599 |
//!
|
sl@0
|
600 |
//! @SYMTestType CIT
|
sl@0
|
601 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
602 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
603 |
CREATE_OBJECT RFile file
|
sl@0
|
604 |
COMMAND RFs1 new
|
sl@0
|
605 |
COMMAND RFs1 Connect
|
sl@0
|
606 |
COMMAND file new
|
sl@0
|
607 |
COMMAND file Replace PBASE-F32-File-PublicApi-0009-001-Replace_command005
|
sl@0
|
608 |
COMMAND file Write PBASE-F32-File-PublicApi-0009-001-Write_command006
|
sl@0
|
609 |
COMMAND file Seek PBASE-F32-File-PublicApi-0009-001-Seek_command007
|
sl@0
|
610 |
COMMAND file Read PBASE-F32-File-PublicApi-0009-001-Read_command008
|
sl@0
|
611 |
OUTSTANDING
|
sl@0
|
612 |
COMMAND file Close
|
sl@0
|
613 |
COMMAND file ~
|
sl@0
|
614 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0009-001-Delete_command012
|
sl@0
|
615 |
COMMAND RFs1 ~
|
sl@0
|
616 |
END_TEST_BLOCK
|
sl@0
|
617 |
END_TESTCASE PBASE-F32-File-PublicApi-0009
|
sl@0
|
618 |
|
sl@0
|
619 |
|
sl@0
|
620 |
START_TESTCASE PBASE-F32-File-PublicApi-0010
|
sl@0
|
621 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0010
|
sl@0
|
622 |
//! @SYMAPI RFile
|
sl@0
|
623 |
//! @SYMTestCaseDesc Synchronous Read(TInt aPos, TDes8 &aDes) test - will open file and read from given position its contents to a buffer.
|
sl@0
|
624 |
//! Uses API elements: Read().
|
sl@0
|
625 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
626 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0010.txt", EFileWrite
|
sl@0
|
627 |
//! 3. Write "synchronous read with position test" to file
|
sl@0
|
628 |
//! 4. Reset file position.
|
sl@0
|
629 |
//! 5. Call RFile::Read() passing 5 for position.
|
sl@0
|
630 |
//! 6. Close RFile.
|
sl@0
|
631 |
//! 7. Delete file.
|
sl@0
|
632 |
//! 8. Close RFs.
|
sl@0
|
633 |
//!
|
sl@0
|
634 |
//! @SYMTestStatus Implemented
|
sl@0
|
635 |
//! @SYMTestPriority Critical
|
sl@0
|
636 |
//! @SYMTestExpectedResults RFile::Read() returns KErrNone. Data is read and verified.
|
sl@0
|
637 |
//!
|
sl@0
|
638 |
//! @SYMTestType CIT
|
sl@0
|
639 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
640 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
641 |
CREATE_OBJECT RFile file
|
sl@0
|
642 |
COMMAND RFs1 new
|
sl@0
|
643 |
COMMAND RFs1 Connect
|
sl@0
|
644 |
COMMAND file new
|
sl@0
|
645 |
COMMAND file Replace PBASE-F32-File-PublicApi-0010-001-Replace_command005
|
sl@0
|
646 |
COMMAND file Write PBASE-F32-File-PublicApi-0010-001-Write_command006
|
sl@0
|
647 |
COMMAND file Seek PBASE-F32-File-PublicApi-0010-001-Seek_command007
|
sl@0
|
648 |
COMMAND file Read PBASE-F32-File-PublicApi-0010-001-Read_command008
|
sl@0
|
649 |
COMMAND file Close
|
sl@0
|
650 |
COMMAND file ~
|
sl@0
|
651 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0010-001-Delete_command012
|
sl@0
|
652 |
COMMAND RFs1 ~
|
sl@0
|
653 |
END_TEST_BLOCK
|
sl@0
|
654 |
END_TESTCASE PBASE-F32-File-PublicApi-0010
|
sl@0
|
655 |
|
sl@0
|
656 |
|
sl@0
|
657 |
START_TESTCASE PBASE-F32-File-PublicApi-0011
|
sl@0
|
658 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0011
|
sl@0
|
659 |
//! @SYMAPI RFile
|
sl@0
|
660 |
//! @SYMTestCaseDesc Asynchronous Read(TInt aPos, TDes8 &aDes, TRequestStatus &aStatus) test - will open file and read from given position its contents to a buffer.
|
sl@0
|
661 |
//! Uses API elements: Read().
|
sl@0
|
662 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
663 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0011.txt", EFileWrite.
|
sl@0
|
664 |
//! 3. Call RFile::Write passing literal "asynchronous read with position test"
|
sl@0
|
665 |
//! 4. Reset file position
|
sl@0
|
666 |
//! 5. Call RFile::Read() passing TRequestStatus and 5 for position.
|
sl@0
|
667 |
//! 6. Wait until asynchronous call completes
|
sl@0
|
668 |
//! 7. Close RFile.
|
sl@0
|
669 |
//! 8. Delete file.
|
sl@0
|
670 |
//! 9. Close RFs.
|
sl@0
|
671 |
//!
|
sl@0
|
672 |
//! @SYMTestStatus Implemented
|
sl@0
|
673 |
//! @SYMTestPriority Critical
|
sl@0
|
674 |
//! @SYMTestExpectedResults The asynchronous read call finishes with KErrNone. Data is read and verified.
|
sl@0
|
675 |
//!
|
sl@0
|
676 |
//! @SYMTestType CIT
|
sl@0
|
677 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
678 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
679 |
CREATE_OBJECT RFile file
|
sl@0
|
680 |
COMMAND RFs1 new
|
sl@0
|
681 |
COMMAND RFs1 Connect
|
sl@0
|
682 |
COMMAND file new
|
sl@0
|
683 |
COMMAND file Replace PBASE-F32-File-PublicApi-0011-001-Replace_command005
|
sl@0
|
684 |
COMMAND file Write PBASE-F32-File-PublicApi-0011-001-Write_command006
|
sl@0
|
685 |
COMMAND file Seek PBASE-F32-File-PublicApi-0011-001-Seek_command007
|
sl@0
|
686 |
COMMAND file Read PBASE-F32-File-PublicApi-0011-001-Read_command008
|
sl@0
|
687 |
OUTSTANDING
|
sl@0
|
688 |
COMMAND file Close
|
sl@0
|
689 |
COMMAND file ~
|
sl@0
|
690 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0011-001-Delete_command012
|
sl@0
|
691 |
COMMAND RFs1 ~
|
sl@0
|
692 |
END_TEST_BLOCK
|
sl@0
|
693 |
END_TESTCASE PBASE-F32-File-PublicApi-0011
|
sl@0
|
694 |
|
sl@0
|
695 |
|
sl@0
|
696 |
START_TESTCASE PBASE-F32-File-PublicApi-0012
|
sl@0
|
697 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0012
|
sl@0
|
698 |
//! @SYMAPI RFile
|
sl@0
|
699 |
//! @SYMTestCaseDesc Synchronous Read(TInt aPos, TDes8 &aDes, TInt aLength) test - will open file and read from given position fixed length of contents into a buffer.
|
sl@0
|
700 |
//! Uses API elements: Read().
|
sl@0
|
701 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
702 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0012.txt", EFileWrite
|
sl@0
|
703 |
//! 3. Write "synchronous read with length and position test" to file
|
sl@0
|
704 |
//! 4. Reset file position.
|
sl@0
|
705 |
//! 5. Call RFile::Read() passing 5 for length and 5 for position.
|
sl@0
|
706 |
//! 6. Close RFile.
|
sl@0
|
707 |
//! 7. Delete file.
|
sl@0
|
708 |
//! 8. Close RFs.
|
sl@0
|
709 |
//!
|
sl@0
|
710 |
//! @SYMTestStatus Implemented
|
sl@0
|
711 |
//! @SYMTestPriority Critical
|
sl@0
|
712 |
//! @SYMTestExpectedResults RFile::Read() returns KErrNone. Data is read and verified.
|
sl@0
|
713 |
//!
|
sl@0
|
714 |
//! @SYMTestType CIT
|
sl@0
|
715 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
716 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
717 |
CREATE_OBJECT RFile file
|
sl@0
|
718 |
COMMAND RFs1 new
|
sl@0
|
719 |
COMMAND RFs1 Connect
|
sl@0
|
720 |
COMMAND file new
|
sl@0
|
721 |
COMMAND file Replace PBASE-F32-File-PublicApi-0012-001-Replace_command005
|
sl@0
|
722 |
COMMAND file Write PBASE-F32-File-PublicApi-0012-001-Write_command006
|
sl@0
|
723 |
COMMAND file Seek PBASE-F32-File-PublicApi-0012-001-Seek_command007
|
sl@0
|
724 |
COMMAND file Read PBASE-F32-File-PublicApi-0012-001-Read_command008
|
sl@0
|
725 |
COMMAND file Close
|
sl@0
|
726 |
COMMAND file ~
|
sl@0
|
727 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0012-001-Delete_command012
|
sl@0
|
728 |
COMMAND RFs1 ~
|
sl@0
|
729 |
END_TEST_BLOCK
|
sl@0
|
730 |
END_TESTCASE PBASE-F32-File-PublicApi-0012
|
sl@0
|
731 |
|
sl@0
|
732 |
|
sl@0
|
733 |
START_TESTCASE PBASE-F32-File-PublicApi-0013
|
sl@0
|
734 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0013
|
sl@0
|
735 |
//! @SYMAPI RFile
|
sl@0
|
736 |
//! @SYMTestCaseDesc Asynchronous Read(TInt aPos, TDes8 &aDes, TInt aLength, TRequestStatus &aStatus) test - will open file and read from given position fixed length of contents into a buffer.
|
sl@0
|
737 |
//! Uses API elements: Read().
|
sl@0
|
738 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
739 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0013.txt", EFileWrite.
|
sl@0
|
740 |
//! 3. Call RFile::Write passing literal "asynchronous read with length and position test"
|
sl@0
|
741 |
//! 4. Reset file position
|
sl@0
|
742 |
//! 5. Call RFile::Read() passing TRequestStatus, 5 for length and 5 for position.
|
sl@0
|
743 |
//! 6. Wait until asynchronous call completes
|
sl@0
|
744 |
//! 7. Close RFile.
|
sl@0
|
745 |
//! 8. Delete file.
|
sl@0
|
746 |
//! 9. Close RFs.
|
sl@0
|
747 |
//!
|
sl@0
|
748 |
//! @SYMTestStatus Implemented
|
sl@0
|
749 |
//! @SYMTestPriority Critical
|
sl@0
|
750 |
//! @SYMTestExpectedResults The asynchronous read call finishes with KErrNone. Data is read and verified.
|
sl@0
|
751 |
//!
|
sl@0
|
752 |
//! @SYMTestType CIT
|
sl@0
|
753 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
754 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
755 |
CREATE_OBJECT RFile file
|
sl@0
|
756 |
COMMAND RFs1 new
|
sl@0
|
757 |
COMMAND RFs1 Connect
|
sl@0
|
758 |
COMMAND file new
|
sl@0
|
759 |
COMMAND file Replace PBASE-F32-File-PublicApi-0013-001-Replace_command005
|
sl@0
|
760 |
COMMAND file Write PBASE-F32-File-PublicApi-0013-001-Write_command006
|
sl@0
|
761 |
COMMAND file Seek PBASE-F32-File-PublicApi-0013-001-Seek_command007
|
sl@0
|
762 |
COMMAND file Read PBASE-F32-File-PublicApi-0013-001-Read_command008
|
sl@0
|
763 |
OUTSTANDING
|
sl@0
|
764 |
COMMAND file Close
|
sl@0
|
765 |
COMMAND file ~
|
sl@0
|
766 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0013-001-Delete_command011
|
sl@0
|
767 |
COMMAND RFs1 ~
|
sl@0
|
768 |
END_TEST_BLOCK
|
sl@0
|
769 |
END_TESTCASE PBASE-F32-File-PublicApi-0013
|
sl@0
|
770 |
|
sl@0
|
771 |
|
sl@0
|
772 |
START_TESTCASE PBASE-F32-File-PublicApi-0014
|
sl@0
|
773 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0014
|
sl@0
|
774 |
//! @SYMAPI RFile
|
sl@0
|
775 |
//! @SYMTestCaseDesc Function ReadCancel(TRequestStatus aStatus) and EFileReadAsyncAll test.
|
sl@0
|
776 |
//! Uses API elements: ReadCancel().
|
sl@0
|
777 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
778 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0014.txt", EFileWrite.
|
sl@0
|
779 |
//! 3. Write message "short data" to file.
|
sl@0
|
780 |
//! 4. Close file
|
sl@0
|
781 |
//! 5. Open fail again with EFileShareAny | EFileReadAsyncAll.
|
sl@0
|
782 |
//! 6. Call RFile::Read() passing TRequestStatus.
|
sl@0
|
783 |
//! 7. Call ReadCancel passing TRequestStatus.
|
sl@0
|
784 |
//! 8. Close RFile.
|
sl@0
|
785 |
//! 9. Delete file.
|
sl@0
|
786 |
//! 10. Close RFs.
|
sl@0
|
787 |
//!
|
sl@0
|
788 |
//! @SYMTestStatus Implemented
|
sl@0
|
789 |
//! @SYMTestPriority Critical
|
sl@0
|
790 |
//! @SYMTestExpectedResults TRequestStatus returns KErrCancel after ReadCancel.
|
sl@0
|
791 |
//!
|
sl@0
|
792 |
//! @SYMTestType CIT
|
sl@0
|
793 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
794 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
795 |
CREATE_OBJECT RFile file
|
sl@0
|
796 |
COMMAND RFs1 new
|
sl@0
|
797 |
COMMAND RFs1 Connect
|
sl@0
|
798 |
COMMAND file new
|
sl@0
|
799 |
COMMAND file Replace PBASE-F32-File-PublicApi-0014-001-Replace_command005
|
sl@0
|
800 |
COMMAND file Write PBASE-F32-File-PublicApi-0014-001-Write_command006
|
sl@0
|
801 |
COMMAND file Close
|
sl@0
|
802 |
COMMAND file Open PBASE-F32-File-PublicApi-0014-001-Open_command008
|
sl@0
|
803 |
COMMAND file Seek PBASE-F32-File-PublicApi-0014-001-Seek_command009
|
sl@0
|
804 |
COMMAND !AsyncError=-3 file Read PBASE-F32-File-PublicApi-0014-001-Read_command010
|
sl@0
|
805 |
ASYNC_DELAY 5
|
sl@0
|
806 |
COMMAND file ReadCancel
|
sl@0
|
807 |
COMMAND file ReadCancel
|
sl@0
|
808 |
OUTSTANDING
|
sl@0
|
809 |
COMMAND file Close
|
sl@0
|
810 |
COMMAND file ~
|
sl@0
|
811 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0014-001-Delete_command015
|
sl@0
|
812 |
COMMAND RFs1 ~
|
sl@0
|
813 |
END_TEST_BLOCK
|
sl@0
|
814 |
END_TESTCASE PBASE-F32-File-PublicApi-0014
|
sl@0
|
815 |
|
sl@0
|
816 |
|
sl@0
|
817 |
START_TESTCASE PBASE-F32-File-PublicApi-0015
|
sl@0
|
818 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0015
|
sl@0
|
819 |
//! @SYMAPI RFile
|
sl@0
|
820 |
//! @SYMTestCaseDesc Function ReadCancel() test, call two asynchronous reads consequently on the same file.
|
sl@0
|
821 |
//! Uses API elements: ReadCancel().
|
sl@0
|
822 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
823 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0015.txt", EFileWrite.
|
sl@0
|
824 |
//! 3. Write message "short data" to file.
|
sl@0
|
825 |
//! 4. Close file
|
sl@0
|
826 |
//! 5. Open fail again with EFileShareAny | EFileReadAsyncAll.
|
sl@0
|
827 |
//! 6. Call RFile::Read() passing TRequestStatus.
|
sl@0
|
828 |
//! 7. Call RFile::Read() passing TRequestStatus.
|
sl@0
|
829 |
//! 8. Call ReadCancel.
|
sl@0
|
830 |
//! 9. Close RFile.
|
sl@0
|
831 |
//! 10. Delete file.
|
sl@0
|
832 |
//! 11. Close RFs.
|
sl@0
|
833 |
//!
|
sl@0
|
834 |
//! @SYMTestStatus Implemented
|
sl@0
|
835 |
//! @SYMTestPriority Critical
|
sl@0
|
836 |
//! @SYMTestExpectedResults Both TRequestStatuses return KErrCancel after ReadCancel.
|
sl@0
|
837 |
//!
|
sl@0
|
838 |
//! @SYMTestType CIT
|
sl@0
|
839 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
840 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
841 |
CREATE_OBJECT RFile file
|
sl@0
|
842 |
COMMAND RFs1 new
|
sl@0
|
843 |
COMMAND RFs1 Connect
|
sl@0
|
844 |
COMMAND file new
|
sl@0
|
845 |
COMMAND file Replace PBASE-F32-File-PublicApi-0015-001-Replace_command005
|
sl@0
|
846 |
COMMAND file Write PBASE-F32-File-PublicApi-0015-001-Write_command006
|
sl@0
|
847 |
COMMAND file Close
|
sl@0
|
848 |
COMMAND file Open PBASE-F32-File-PublicApi-0015-001-Open_command008
|
sl@0
|
849 |
COMMAND file Seek PBASE-F32-File-PublicApi-0015-001-Seek_command009
|
sl@0
|
850 |
COMMAND !AsyncError=-3 file Read PBASE-F32-File-PublicApi-0015-001-Read_command010
|
sl@0
|
851 |
COMMAND !AsyncError=-3 file Read PBASE-F32-File-PublicApi-0015-001-Read_command011
|
sl@0
|
852 |
ASYNC_DELAY 5
|
sl@0
|
853 |
COMMAND file ReadCancel PBASE-F32-File-PublicApi-0015-001-ReadCancel_command012
|
sl@0
|
854 |
OUTSTANDING
|
sl@0
|
855 |
COMMAND file Close
|
sl@0
|
856 |
COMMAND file ~
|
sl@0
|
857 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0015-001-Delete_command016
|
sl@0
|
858 |
COMMAND RFs1 ~
|
sl@0
|
859 |
END_TEST_BLOCK
|
sl@0
|
860 |
END_TESTCASE PBASE-F32-File-PublicApi-0015
|
sl@0
|
861 |
|
sl@0
|
862 |
|
sl@0
|
863 |
START_TESTCASE PBASE-F32-File-PublicApi-0016
|
sl@0
|
864 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0016
|
sl@0
|
865 |
//! @SYMAPI RFile
|
sl@0
|
866 |
//! @SYMTestCaseDesc Synchronous Write(const TDesC8 &aDes) test - will open file and Write to it from given buffer.
|
sl@0
|
867 |
//! Uses API elements: Write(const TDesC8 &aDes).
|
sl@0
|
868 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
869 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0016.txt", EFileWrite
|
sl@0
|
870 |
//! 3. Call RFile::Write() passing "Write test".
|
sl@0
|
871 |
//! 4. Reset file position
|
sl@0
|
872 |
//! 5. Read from file to verify it's content.
|
sl@0
|
873 |
//! 6. Close RFile.
|
sl@0
|
874 |
//! 7. Delete file.
|
sl@0
|
875 |
//! 8. Close RFs.
|
sl@0
|
876 |
//!
|
sl@0
|
877 |
//! @SYMTestStatus Implemented
|
sl@0
|
878 |
//! @SYMTestPriority Critical
|
sl@0
|
879 |
//! @SYMTestExpectedResults RFile::Write() returns KErrNone. File contains written data.
|
sl@0
|
880 |
//!
|
sl@0
|
881 |
//! @SYMTestType CIT
|
sl@0
|
882 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
883 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
884 |
CREATE_OBJECT RFile file
|
sl@0
|
885 |
COMMAND RFs1 new
|
sl@0
|
886 |
COMMAND RFs1 Connect
|
sl@0
|
887 |
COMMAND file new
|
sl@0
|
888 |
COMMAND file Replace PBASE-F32-File-PublicApi-0016-001-Replace_command005
|
sl@0
|
889 |
COMMAND file Write PBASE-F32-File-PublicApi-0016-001-Write_command006
|
sl@0
|
890 |
COMMAND file Flush
|
sl@0
|
891 |
COMMAND file Close
|
sl@0
|
892 |
COMMAND file Open PBASE-F32-File-PublicApi-0016-001-Open_command009
|
sl@0
|
893 |
COMMAND file Read PBASE-F32-File-PublicApi-0016-001-Read_command010
|
sl@0
|
894 |
COMMAND file Close
|
sl@0
|
895 |
COMMAND file ~
|
sl@0
|
896 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0016-001-Delete_command014
|
sl@0
|
897 |
COMMAND RFs1 ~
|
sl@0
|
898 |
END_TEST_BLOCK
|
sl@0
|
899 |
END_TESTCASE PBASE-F32-File-PublicApi-0016
|
sl@0
|
900 |
|
sl@0
|
901 |
|
sl@0
|
902 |
START_TESTCASE PBASE-F32-File-PublicApi-0017
|
sl@0
|
903 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0017
|
sl@0
|
904 |
//! @SYMAPI RFile
|
sl@0
|
905 |
//! @SYMTestCaseDesc Asynchronous Write(const TDesC8 &aDes, TRequestStatus &aStat) test - will open file and Write to it from given buffer.
|
sl@0
|
906 |
//! Uses API elements: Write(const TDesC8 &aDes, TRequestStatus &aStat).
|
sl@0
|
907 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
908 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0017.txt", EFileWrite.
|
sl@0
|
909 |
//! 3. Call RFile::Write() passing "Asynchronous write test" and TRequestStatus.
|
sl@0
|
910 |
//! 4. Wait for request to complete.
|
sl@0
|
911 |
//! 5. Reset file position
|
sl@0
|
912 |
//! 6. Read from file to verify it's content.
|
sl@0
|
913 |
//! 7. Close RFile.
|
sl@0
|
914 |
//! 8. Delete file.
|
sl@0
|
915 |
//! 9. Close RFs.
|
sl@0
|
916 |
//!
|
sl@0
|
917 |
//! @SYMTestStatus Implemented
|
sl@0
|
918 |
//! @SYMTestPriority Critical
|
sl@0
|
919 |
//! @SYMTestExpectedResults Write completes with KErrNone. File contains written data.
|
sl@0
|
920 |
//!
|
sl@0
|
921 |
//! @SYMTestType CIT
|
sl@0
|
922 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
923 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
924 |
CREATE_OBJECT RFile file
|
sl@0
|
925 |
COMMAND RFs1 new
|
sl@0
|
926 |
COMMAND RFs1 Connect
|
sl@0
|
927 |
COMMAND file new
|
sl@0
|
928 |
COMMAND file Replace PBASE-F32-File-PublicApi-0017-001-Replace_command005
|
sl@0
|
929 |
COMMAND file Write PBASE-F32-File-PublicApi-0017-001-Write_command006
|
sl@0
|
930 |
OUTSTANDING
|
sl@0
|
931 |
COMMAND file Flush
|
sl@0
|
932 |
COMMAND file Close
|
sl@0
|
933 |
COMMAND file Open PBASE-F32-File-PublicApi-0017-001-Open_command009
|
sl@0
|
934 |
COMMAND file Read PBASE-F32-File-PublicApi-0017-001-Read_command010
|
sl@0
|
935 |
COMMAND file Close
|
sl@0
|
936 |
COMMAND file ~
|
sl@0
|
937 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0017-001-Delete_command014
|
sl@0
|
938 |
COMMAND RFs1 ~
|
sl@0
|
939 |
END_TEST_BLOCK
|
sl@0
|
940 |
END_TESTCASE PBASE-F32-File-PublicApi-0017
|
sl@0
|
941 |
|
sl@0
|
942 |
|
sl@0
|
943 |
START_TESTCASE PBASE-F32-File-PublicApi-0018
|
sl@0
|
944 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0018
|
sl@0
|
945 |
//! @SYMAPI RFile
|
sl@0
|
946 |
//! @SYMTestCaseDesc Synchronous Write(const TDesC8 &aDes, TInt aLength) test - will open file and Write to it fixed length bytes from given buffer.
|
sl@0
|
947 |
//! Uses API elements: Write(const TDesC8 &aDes, TInt aLength).
|
sl@0
|
948 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
949 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0018.txt", EFileWrite
|
sl@0
|
950 |
//! 3. Call RFile::Write() passing "Synchronous write test with length", and 5 for length to write.
|
sl@0
|
951 |
//! 4. Reset file position
|
sl@0
|
952 |
//! 5. Read from file to verify it's content.
|
sl@0
|
953 |
//! 6. Close RFile.
|
sl@0
|
954 |
//! 7. Delete file.
|
sl@0
|
955 |
//! 8. Close RFs.
|
sl@0
|
956 |
//!
|
sl@0
|
957 |
//! @SYMTestStatus Implemented
|
sl@0
|
958 |
//! @SYMTestPriority Critical
|
sl@0
|
959 |
//! @SYMTestExpectedResults RFile::Write() returns KErrNone. File contains written data.
|
sl@0
|
960 |
//!
|
sl@0
|
961 |
//! @SYMTestType CIT
|
sl@0
|
962 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
963 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
964 |
CREATE_OBJECT RFile file
|
sl@0
|
965 |
COMMAND RFs1 new
|
sl@0
|
966 |
COMMAND RFs1 Connect
|
sl@0
|
967 |
COMMAND file new
|
sl@0
|
968 |
COMMAND file Replace PBASE-F32-File-PublicApi-0018-001-Replace_command005
|
sl@0
|
969 |
COMMAND file Write PBASE-F32-File-PublicApi-0018-001-Write_command006
|
sl@0
|
970 |
COMMAND file Flush
|
sl@0
|
971 |
COMMAND file Close
|
sl@0
|
972 |
COMMAND file Open PBASE-F32-File-PublicApi-0018-001-Open_command009
|
sl@0
|
973 |
COMMAND file Read PBASE-F32-File-PublicApi-0018-001-Read_command010
|
sl@0
|
974 |
COMMAND file Close
|
sl@0
|
975 |
COMMAND file ~
|
sl@0
|
976 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0018-001-Delete_command014
|
sl@0
|
977 |
COMMAND RFs1 ~
|
sl@0
|
978 |
END_TEST_BLOCK
|
sl@0
|
979 |
END_TESTCASE PBASE-F32-File-PublicApi-0018
|
sl@0
|
980 |
|
sl@0
|
981 |
|
sl@0
|
982 |
START_TESTCASE PBASE-F32-File-PublicApi-0019
|
sl@0
|
983 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0019
|
sl@0
|
984 |
//! @SYMAPI RFile
|
sl@0
|
985 |
//! @SYMTestCaseDesc Asynchronous Write(const TDesC8 &aDes, TInt aLength, TRequestStatus &aStatus) test - will open file and Write to it fixed length bytes from given buffer.
|
sl@0
|
986 |
//! Uses API elements: Write(const TDesC8 &aDes, TInt aLength, TRequestStatus &aStatus).
|
sl@0
|
987 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
988 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0019.txt", EFileWrite.
|
sl@0
|
989 |
//! 3. Call RFile::Write() passing "Asynchronous write test with length", 5 for length and TRequestStatus.
|
sl@0
|
990 |
//! 4. Wait for request to complete.
|
sl@0
|
991 |
//! 5. Reset file position
|
sl@0
|
992 |
//! 6. Read from file to verify it's content.
|
sl@0
|
993 |
//! 7. Close RFile.
|
sl@0
|
994 |
//! 8. Delete file.
|
sl@0
|
995 |
//! 9. Close RFs.
|
sl@0
|
996 |
//!
|
sl@0
|
997 |
//! @SYMTestStatus Implemented
|
sl@0
|
998 |
//! @SYMTestPriority Critical
|
sl@0
|
999 |
//! @SYMTestExpectedResults Write completes with KErrNone. File contains written data.
|
sl@0
|
1000 |
//!
|
sl@0
|
1001 |
//! @SYMTestType CIT
|
sl@0
|
1002 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
1003 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
1004 |
CREATE_OBJECT RFile file
|
sl@0
|
1005 |
COMMAND RFs1 new
|
sl@0
|
1006 |
COMMAND RFs1 Connect
|
sl@0
|
1007 |
COMMAND file new
|
sl@0
|
1008 |
COMMAND file Replace PBASE-F32-File-PublicApi-0019-001-Replace_command005
|
sl@0
|
1009 |
COMMAND file Write PBASE-F32-File-PublicApi-0019-001-Write_command006
|
sl@0
|
1010 |
OUTSTANDING
|
sl@0
|
1011 |
COMMAND file Flush
|
sl@0
|
1012 |
COMMAND file Close
|
sl@0
|
1013 |
COMMAND file Open PBASE-F32-File-PublicApi-0019-001-Open_command009
|
sl@0
|
1014 |
COMMAND file Read PBASE-F32-File-PublicApi-0019-001-Read_command010
|
sl@0
|
1015 |
COMMAND file Close
|
sl@0
|
1016 |
COMMAND file ~
|
sl@0
|
1017 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0019-001-Delete_command014
|
sl@0
|
1018 |
COMMAND RFs1 ~
|
sl@0
|
1019 |
END_TEST_BLOCK
|
sl@0
|
1020 |
END_TESTCASE PBASE-F32-File-PublicApi-0019
|
sl@0
|
1021 |
|
sl@0
|
1022 |
|
sl@0
|
1023 |
START_TESTCASE PBASE-F32-File-PublicApi-0020
|
sl@0
|
1024 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0020
|
sl@0
|
1025 |
//! @SYMAPI RFile
|
sl@0
|
1026 |
//! @SYMTestCaseDesc Synchronous Write(TInt aPos, const TDesC8 &aDes) test - will open file and Write to it from given position.
|
sl@0
|
1027 |
//! Uses API elements: Write(TInt aPos, const TDesC8 &aDes).
|
sl@0
|
1028 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
1029 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0020.txt", EFileWrite
|
sl@0
|
1030 |
//! 4. Call RFile::Write() passing "Synchronous write test with position", and 2 for position to write from.
|
sl@0
|
1031 |
//! 5. Reset file position
|
sl@0
|
1032 |
//! 6. Read from file to verify it's content.
|
sl@0
|
1033 |
//! 7. Close RFile.
|
sl@0
|
1034 |
//! 8. Delete file.
|
sl@0
|
1035 |
//! 9. Close RFs.
|
sl@0
|
1036 |
//!
|
sl@0
|
1037 |
//! @SYMTestStatus Implemented
|
sl@0
|
1038 |
//! @SYMTestPriority Critical
|
sl@0
|
1039 |
//! @SYMTestExpectedResults RFile::Write() returns KErrNone. File contains written data.
|
sl@0
|
1040 |
//!
|
sl@0
|
1041 |
//! @SYMTestType CIT
|
sl@0
|
1042 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
1043 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
1044 |
CREATE_OBJECT RFile file
|
sl@0
|
1045 |
COMMAND RFs1 new
|
sl@0
|
1046 |
COMMAND RFs1 Connect
|
sl@0
|
1047 |
COMMAND file new
|
sl@0
|
1048 |
COMMAND file Replace PBASE-F32-File-PublicApi-0020-001-Replace_command005
|
sl@0
|
1049 |
COMMAND file Write PBASE-F32-File-PublicApi-0020-001-Write_command006
|
sl@0
|
1050 |
COMMAND file Flush
|
sl@0
|
1051 |
COMMAND file Write PBASE-F32-File-PublicApi-0020-001-Write_command008
|
sl@0
|
1052 |
COMMAND file Flush
|
sl@0
|
1053 |
COMMAND file Close
|
sl@0
|
1054 |
COMMAND file Open PBASE-F32-File-PublicApi-0020-001-Open_command011
|
sl@0
|
1055 |
COMMAND file Read PBASE-F32-File-PublicApi-0020-001-Read_command012
|
sl@0
|
1056 |
COMMAND file Close
|
sl@0
|
1057 |
COMMAND file ~
|
sl@0
|
1058 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0020-001-Delete_command016
|
sl@0
|
1059 |
COMMAND RFs1 ~
|
sl@0
|
1060 |
END_TEST_BLOCK
|
sl@0
|
1061 |
END_TESTCASE PBASE-F32-File-PublicApi-0020
|
sl@0
|
1062 |
|
sl@0
|
1063 |
|
sl@0
|
1064 |
START_TESTCASE PBASE-F32-File-PublicApi-0021
|
sl@0
|
1065 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0021
|
sl@0
|
1066 |
//! @SYMAPI RFile
|
sl@0
|
1067 |
//! @SYMTestCaseDesc Asynchronous Write(TInt aPos, const TDesC8 &aDes, TRequestStatus &aStatus) test - will open file and Write to it from given position.
|
sl@0
|
1068 |
//! Uses API elements: Write(TInt aPos, const TDesC8 &aDes, TRequestStatus &aStatus).
|
sl@0
|
1069 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
1070 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0021.txt", EFileWrite.
|
sl@0
|
1071 |
//! 3. Call RFile::Write() passing "Asynchronous write test with position", 2 for position and TRequestStatus.
|
sl@0
|
1072 |
//! 4. Wait for request to complete.
|
sl@0
|
1073 |
//! 5. Reset file position
|
sl@0
|
1074 |
//! 6. Read from file to verify it's content.
|
sl@0
|
1075 |
//! 7. Close RFile.
|
sl@0
|
1076 |
//! 8. Delete file.
|
sl@0
|
1077 |
//! 9. Close RFs.
|
sl@0
|
1078 |
//!
|
sl@0
|
1079 |
//! @SYMTestStatus Implemented
|
sl@0
|
1080 |
//! @SYMTestPriority Critical
|
sl@0
|
1081 |
//! @SYMTestExpectedResults TRequestStatus equals KErrNone after writing. File contains written data.
|
sl@0
|
1082 |
//!
|
sl@0
|
1083 |
//! @SYMTestType CIT
|
sl@0
|
1084 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
1085 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
1086 |
CREATE_OBJECT RFile file
|
sl@0
|
1087 |
COMMAND RFs1 new
|
sl@0
|
1088 |
COMMAND RFs1 Connect
|
sl@0
|
1089 |
COMMAND file new
|
sl@0
|
1090 |
COMMAND file Replace PBASE-F32-File-PublicApi-0021-001-Replace_command005
|
sl@0
|
1091 |
COMMAND file Write PBASE-F32-File-PublicApi-0021-001-Write_command006
|
sl@0
|
1092 |
COMMAND file Flush
|
sl@0
|
1093 |
COMMAND file Write PBASE-F32-File-PublicApi-0021-001-Write_command008
|
sl@0
|
1094 |
OUTSTANDING
|
sl@0
|
1095 |
COMMAND file Flush
|
sl@0
|
1096 |
COMMAND file Close
|
sl@0
|
1097 |
COMMAND file Open PBASE-F32-File-PublicApi-0021-001-Open_command011
|
sl@0
|
1098 |
COMMAND file Read PBASE-F32-File-PublicApi-0021-001-Read_command012
|
sl@0
|
1099 |
COMMAND file Close
|
sl@0
|
1100 |
COMMAND file ~
|
sl@0
|
1101 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0021-001-Delete_command016
|
sl@0
|
1102 |
COMMAND RFs1 ~
|
sl@0
|
1103 |
END_TEST_BLOCK
|
sl@0
|
1104 |
END_TESTCASE PBASE-F32-File-PublicApi-0021
|
sl@0
|
1105 |
|
sl@0
|
1106 |
|
sl@0
|
1107 |
START_TESTCASE PBASE-F32-File-PublicApi-0022
|
sl@0
|
1108 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0022
|
sl@0
|
1109 |
//! @SYMAPI RFile
|
sl@0
|
1110 |
//! @SYMTestCaseDesc Synchronous Write(TInt aPos, const TDesC8 &aDes, TInt aLength) test - will open file and Write to it from given position and fixed length of bytes.
|
sl@0
|
1111 |
//! Uses API elements: Write(TInt aPos, const TDesC8 &aDes, TInt aLength).
|
sl@0
|
1112 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
1113 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0022.txt", EFileWrite
|
sl@0
|
1114 |
//! 3. Call RFile::Write() passing "Synchronous write test with position, length", 2 for position and 4 for length to write from.
|
sl@0
|
1115 |
//! 4. Reset file position
|
sl@0
|
1116 |
//! 5. Read from file to verify it's content.
|
sl@0
|
1117 |
//! 6. Close RFile.
|
sl@0
|
1118 |
//! 7. Delete file.
|
sl@0
|
1119 |
//! 8. Close RFs.
|
sl@0
|
1120 |
//!
|
sl@0
|
1121 |
//! @SYMTestStatus Implemented
|
sl@0
|
1122 |
//! @SYMTestPriority Critical
|
sl@0
|
1123 |
//! @SYMTestExpectedResults RFile::Write() returns KErrNone. File contains written data.
|
sl@0
|
1124 |
//!
|
sl@0
|
1125 |
//! @SYMTestType CIT
|
sl@0
|
1126 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
1127 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
1128 |
CREATE_OBJECT RFile file
|
sl@0
|
1129 |
COMMAND RFs1 new
|
sl@0
|
1130 |
COMMAND RFs1 Connect
|
sl@0
|
1131 |
COMMAND file new
|
sl@0
|
1132 |
COMMAND file Replace PBASE-F32-File-PublicApi-0022-001-Replace_command005
|
sl@0
|
1133 |
COMMAND file Write PBASE-F32-File-PublicApi-0022-001-Write_command006
|
sl@0
|
1134 |
COMMAND file Flush
|
sl@0
|
1135 |
COMMAND file Write PBASE-F32-File-PublicApi-0022-001-Write_command008
|
sl@0
|
1136 |
COMMAND file Flush
|
sl@0
|
1137 |
COMMAND file Close
|
sl@0
|
1138 |
COMMAND file Open PBASE-F32-File-PublicApi-0022-001-Open_command011
|
sl@0
|
1139 |
COMMAND file Read PBASE-F32-File-PublicApi-0022-001-Read_command012
|
sl@0
|
1140 |
COMMAND file Close
|
sl@0
|
1141 |
COMMAND file ~
|
sl@0
|
1142 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0022-001-Delete_command016
|
sl@0
|
1143 |
COMMAND RFs1 ~
|
sl@0
|
1144 |
END_TEST_BLOCK
|
sl@0
|
1145 |
END_TESTCASE PBASE-F32-File-PublicApi-0022
|
sl@0
|
1146 |
|
sl@0
|
1147 |
|
sl@0
|
1148 |
START_TESTCASE PBASE-F32-File-PublicApi-0023
|
sl@0
|
1149 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0023
|
sl@0
|
1150 |
//! @SYMAPI RFile
|
sl@0
|
1151 |
//! @SYMTestCaseDesc Asynchronous Write(TInt aPos, const TDesC8 &aDes, TInt aLength, TRequestStatus &aStatus) test - will open file and Write to it from given position and fixed length of bytes.
|
sl@0
|
1152 |
//! Uses API elements: Write(TInt aPos, const TDesC8 &aDes, TInt aLength, TRequestStatus &aStatus).
|
sl@0
|
1153 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
1154 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0023.txt", EFileWrite.
|
sl@0
|
1155 |
//! 3. Call RFile::Write() passing "Asynchronous write test with position, length",2 for position, 4 for length and TRequestStatus.
|
sl@0
|
1156 |
//! 4. Wait for request to complete.
|
sl@0
|
1157 |
//! 5. Reset file position
|
sl@0
|
1158 |
//! 6. Read from file to verify it's content.
|
sl@0
|
1159 |
//! 7. Close RFile.
|
sl@0
|
1160 |
//! 8. Delete file.
|
sl@0
|
1161 |
//! 9. Close RFs.
|
sl@0
|
1162 |
//!
|
sl@0
|
1163 |
//! @SYMTestStatus Implemented
|
sl@0
|
1164 |
//! @SYMTestPriority Critical
|
sl@0
|
1165 |
//! @SYMTestExpectedResults TRequestStatus equals KErrNone after writing. File contains written data.
|
sl@0
|
1166 |
//!
|
sl@0
|
1167 |
//! @SYMTestType CIT
|
sl@0
|
1168 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
1169 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
1170 |
CREATE_OBJECT RFile file
|
sl@0
|
1171 |
COMMAND RFs1 new
|
sl@0
|
1172 |
COMMAND RFs1 Connect
|
sl@0
|
1173 |
COMMAND file new
|
sl@0
|
1174 |
COMMAND file Replace PBASE-F32-File-PublicApi-0023-001-Replace_command005
|
sl@0
|
1175 |
COMMAND file Write PBASE-F32-File-PublicApi-0023-001-Write_command006
|
sl@0
|
1176 |
COMMAND file Flush
|
sl@0
|
1177 |
COMMAND file Write PBASE-F32-File-PublicApi-0023-001-Write_command008
|
sl@0
|
1178 |
OUTSTANDING
|
sl@0
|
1179 |
COMMAND file Flush
|
sl@0
|
1180 |
COMMAND file Close
|
sl@0
|
1181 |
COMMAND file Open PBASE-F32-File-PublicApi-0023-001-Open_command011
|
sl@0
|
1182 |
COMMAND file Read PBASE-F32-File-PublicApi-0023-001-Read_command012
|
sl@0
|
1183 |
COMMAND file Close
|
sl@0
|
1184 |
COMMAND file ~
|
sl@0
|
1185 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0023-001-Delete_command016
|
sl@0
|
1186 |
COMMAND RFs1 ~
|
sl@0
|
1187 |
END_TEST_BLOCK
|
sl@0
|
1188 |
END_TESTCASE PBASE-F32-File-PublicApi-0023
|
sl@0
|
1189 |
|
sl@0
|
1190 |
|
sl@0
|
1191 |
START_TESTCASE PBASE-F32-File-PublicApi-0024
|
sl@0
|
1192 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0024
|
sl@0
|
1193 |
//! @SYMAPI RFile
|
sl@0
|
1194 |
//! @SYMTestCaseDesc Function Lock(), UnLock test - open a file and lock it, then try to read from it from another RFs.
|
sl@0
|
1195 |
//! Uses API elements: Lock(), Unlock(), Read().
|
sl@0
|
1196 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
1197 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0024.txt", EFileWrite, open file as fileOne.
|
sl@0
|
1198 |
//! 3. Write "Lock test" to file.
|
sl@0
|
1199 |
//! 4. Lock the file by Calling Lock() with pos=0 and length=3.
|
sl@0
|
1200 |
//! 5. open "{Drives, RAMDriveTestPath}file\tc0024.txt" as fileTwo.
|
sl@0
|
1201 |
//! 6. read from the fileTwo.
|
sl@0
|
1202 |
//! 7. read from fileOne.
|
sl@0
|
1203 |
//! 8. unlock fileOne by RFile::Unlock(), with pos=0 and length=3.
|
sl@0
|
1204 |
//! 9. read from fileTwo.
|
sl@0
|
1205 |
//! 10. Close fileOne.
|
sl@0
|
1206 |
//! 11. Close fileTwo.
|
sl@0
|
1207 |
//! 12. Delete file.
|
sl@0
|
1208 |
//! 13. Close first RFs.
|
sl@0
|
1209 |
//!
|
sl@0
|
1210 |
//! @SYMTestStatus Implemented
|
sl@0
|
1211 |
//! @SYMTestPriority Critical
|
sl@0
|
1212 |
//! @SYMTestExpectedResults When fileOne is locked reading of fileTwo returns KErrLocked, Lock() returns KErrNone, UnLock returns KErrNone.
|
sl@0
|
1213 |
//! After fileOne is unlocked Reading of fileTwo returns KErrNone.
|
sl@0
|
1214 |
//!
|
sl@0
|
1215 |
//! @SYMTestType CIT
|
sl@0
|
1216 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
1217 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
1218 |
CREATE_OBJECT RFile file
|
sl@0
|
1219 |
CREATE_OBJECT RFile file2
|
sl@0
|
1220 |
COMMAND RFs1 new
|
sl@0
|
1221 |
COMMAND RFs1 Connect
|
sl@0
|
1222 |
COMMAND file new
|
sl@0
|
1223 |
COMMAND file Replace PBASE-F32-File-PublicApi-0024-001-Replace_command005
|
sl@0
|
1224 |
COMMAND file2 new
|
sl@0
|
1225 |
COMMAND file2 Open PBASE-F32-File-PublicApi-0024-001-Open_command008
|
sl@0
|
1226 |
COMMAND file Write PBASE-F32-File-PublicApi-0024-001-Write_command010
|
sl@0
|
1227 |
COMMAND file Lock PBASE-F32-File-PublicApi-0024-001-Lock_command011
|
sl@0
|
1228 |
COMMAND !Error=-22 file2 Read
|
sl@0
|
1229 |
COMMAND file Read
|
sl@0
|
1230 |
COMMAND file UnLock PBASE-F32-File-PublicApi-0024-001-UnLock_command016
|
sl@0
|
1231 |
COMMAND file2 Read
|
sl@0
|
1232 |
COMMAND file2 Close
|
sl@0
|
1233 |
COMMAND file2 ~
|
sl@0
|
1234 |
COMMAND file Close
|
sl@0
|
1235 |
COMMAND file ~
|
sl@0
|
1236 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0024-001-Delete_command025
|
sl@0
|
1237 |
COMMAND RFs1 ~
|
sl@0
|
1238 |
END_TEST_BLOCK
|
sl@0
|
1239 |
END_TESTCASE PBASE-F32-File-PublicApi-0024
|
sl@0
|
1240 |
|
sl@0
|
1241 |
|
sl@0
|
1242 |
START_TESTCASE PBASE-F32-File-PublicApi-0025
|
sl@0
|
1243 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0025
|
sl@0
|
1244 |
//! @SYMAPI RFile
|
sl@0
|
1245 |
//! @SYMTestCaseDesc Function Seek() test - open a file and and get it's current position.
|
sl@0
|
1246 |
//! Uses API elements: Seek(), Read().
|
sl@0
|
1247 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
1248 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0025.txt", EFileWrite.
|
sl@0
|
1249 |
//! 3. Write "Should seek to pos here" to file.
|
sl@0
|
1250 |
//! 3. Call RFile::Seek passing ESeekStart, 19
|
sl@0
|
1251 |
//! 4. Call RFile::Read;
|
sl@0
|
1252 |
//! 5. Close file.
|
sl@0
|
1253 |
//! 6. Delete file.
|
sl@0
|
1254 |
//! 7. Close RFs.
|
sl@0
|
1255 |
//!
|
sl@0
|
1256 |
//! @SYMTestStatus Implemented
|
sl@0
|
1257 |
//! @SYMTestPriority Critical
|
sl@0
|
1258 |
//! @SYMTestExpectedResults Seek() returns KErrNone, buffer contents equals string literal "here".
|
sl@0
|
1259 |
//!
|
sl@0
|
1260 |
//! @SYMTestType CIT
|
sl@0
|
1261 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
1262 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
1263 |
CREATE_OBJECT RFile file
|
sl@0
|
1264 |
COMMAND RFs1 new
|
sl@0
|
1265 |
COMMAND RFs1 Connect
|
sl@0
|
1266 |
COMMAND file new
|
sl@0
|
1267 |
COMMAND file Replace PBASE-F32-File-PublicApi-0025-001-Replace_command005
|
sl@0
|
1268 |
COMMAND file Write PBASE-F32-File-PublicApi-0025-001-Write_command006
|
sl@0
|
1269 |
COMMAND file Seek PBASE-F32-File-PublicApi-0025-001-Seek_command007
|
sl@0
|
1270 |
COMMAND file Read PBASE-F32-File-PublicApi-0025-001-Read_command008
|
sl@0
|
1271 |
COMMAND file Close
|
sl@0
|
1272 |
COMMAND file ~
|
sl@0
|
1273 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0025-001-Delete_command012
|
sl@0
|
1274 |
COMMAND RFs1 ~
|
sl@0
|
1275 |
END_TEST_BLOCK
|
sl@0
|
1276 |
END_TESTCASE PBASE-F32-File-PublicApi-0025
|
sl@0
|
1277 |
|
sl@0
|
1278 |
|
sl@0
|
1279 |
START_TESTCASE PBASE-F32-File-PublicApi-0125
|
sl@0
|
1280 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0125
|
sl@0
|
1281 |
//! @SYMAPI RFile
|
sl@0
|
1282 |
//! @SYMTestCaseDesc Function Seek() test - test TSeek::ESeekCurrent.
|
sl@0
|
1283 |
//! Uses API elements: Seek(), Read().
|
sl@0
|
1284 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
1285 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0125.txt", EFileWrite.
|
sl@0
|
1286 |
//! 3. Write "Should seek to pos here" to file.
|
sl@0
|
1287 |
//! 3. Call RFile::Seek passing ESeekStart, 0
|
sl@0
|
1288 |
//! 4. Call RFile::Read passing 7 for length.
|
sl@0
|
1289 |
//! 5. Call RFile::Seek passing ESeekCurrent, 5.
|
sl@0
|
1290 |
//! 6. Call RFile::Read().
|
sl@0
|
1291 |
//! 7. Close file.
|
sl@0
|
1292 |
//! 8. Delete file.
|
sl@0
|
1293 |
//! 9. Close RFs.
|
sl@0
|
1294 |
//!
|
sl@0
|
1295 |
//! @SYMTestStatus Implemented
|
sl@0
|
1296 |
//! @SYMTestPriority Critical
|
sl@0
|
1297 |
//! @SYMTestExpectedResults Seek() returns KErrNone, step 6 returns "to pos here".
|
sl@0
|
1298 |
//!
|
sl@0
|
1299 |
//! @SYMTestType CIT
|
sl@0
|
1300 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
1301 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
1302 |
CREATE_OBJECT RFile file
|
sl@0
|
1303 |
COMMAND RFs1 new
|
sl@0
|
1304 |
COMMAND RFs1 Connect
|
sl@0
|
1305 |
COMMAND file new
|
sl@0
|
1306 |
COMMAND file Replace PBASE-F32-File-PublicApi-0125-001-Replace_command005
|
sl@0
|
1307 |
COMMAND file Write PBASE-F32-File-PublicApi-0125-001-Write_command006
|
sl@0
|
1308 |
COMMAND file Seek PBASE-F32-File-PublicApi-0125-001-Seek_command007
|
sl@0
|
1309 |
COMMAND file Read PBASE-F32-File-PublicApi-0125-001-Read_command008
|
sl@0
|
1310 |
COMMAND file Seek PBASE-F32-File-PublicApi-0125-001-Seek_command009
|
sl@0
|
1311 |
COMMAND file Read PBASE-F32-File-PublicApi-0125-001-Read_command010
|
sl@0
|
1312 |
COMMAND file Close
|
sl@0
|
1313 |
COMMAND file ~
|
sl@0
|
1314 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0125-001-Delete_command014
|
sl@0
|
1315 |
COMMAND RFs1 ~
|
sl@0
|
1316 |
END_TEST_BLOCK
|
sl@0
|
1317 |
END_TESTCASE PBASE-F32-File-PublicApi-0125
|
sl@0
|
1318 |
|
sl@0
|
1319 |
START_TESTCASE PBASE-F32-File-PublicApi-0026
|
sl@0
|
1320 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0026
|
sl@0
|
1321 |
//! @SYMAPI RFile
|
sl@0
|
1322 |
//! @SYMTestCaseDesc Function Flush() test - open file, write to it and then flush.
|
sl@0
|
1323 |
//! Uses API elements: Open(), Flush(), Write().
|
sl@0
|
1324 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
1325 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0026.txt", EFileWrite.
|
sl@0
|
1326 |
//! 5. Call RFile::Write() passing "This data should be flushed".
|
sl@0
|
1327 |
//! 4. Call RFile::Flush();
|
sl@0
|
1328 |
//! 5. Close file.
|
sl@0
|
1329 |
//! 6. Close RFs.
|
sl@0
|
1330 |
//!
|
sl@0
|
1331 |
//! @SYMTestStatus Implemented
|
sl@0
|
1332 |
//! @SYMTestPriority Critical
|
sl@0
|
1333 |
//! @SYMTestExpectedResults RFile::Flush() returns KErrNone. File contains written data.
|
sl@0
|
1334 |
//!
|
sl@0
|
1335 |
//! @SYMTestType CIT
|
sl@0
|
1336 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
1337 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
1338 |
CREATE_OBJECT RFile file
|
sl@0
|
1339 |
COMMAND RFs1 new
|
sl@0
|
1340 |
COMMAND RFs1 Connect
|
sl@0
|
1341 |
COMMAND file new
|
sl@0
|
1342 |
COMMAND file Replace PBASE-F32-File-PublicApi-0026-001-Replace_command005
|
sl@0
|
1343 |
COMMAND file Write PBASE-F32-File-PublicApi-0026-001-Write_command006
|
sl@0
|
1344 |
COMMAND file Flush
|
sl@0
|
1345 |
COMMAND file Seek PBASE-F32-File-PublicApi-0026-001-Seek_command008
|
sl@0
|
1346 |
COMMAND file Read PBASE-F32-File-PublicApi-0026-001-Read_command009
|
sl@0
|
1347 |
COMMAND file Close
|
sl@0
|
1348 |
COMMAND file ~
|
sl@0
|
1349 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0026-001-Delete_command011
|
sl@0
|
1350 |
COMMAND RFs1 ~
|
sl@0
|
1351 |
END_TEST_BLOCK
|
sl@0
|
1352 |
END_TESTCASE PBASE-F32-File-PublicApi-0026
|
sl@0
|
1353 |
|
sl@0
|
1354 |
|
sl@0
|
1355 |
START_TESTCASE PBASE-F32-File-PublicApi-0027
|
sl@0
|
1356 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0027
|
sl@0
|
1357 |
//! @SYMAPI RFile
|
sl@0
|
1358 |
//! @SYMTestCaseDesc Asynchronous Flush() test - open file, write to it and then flush.
|
sl@0
|
1359 |
//! Uses API elements: Open(), Flush(), Write().
|
sl@0
|
1360 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
1361 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0027.txt", EFileWrite.
|
sl@0
|
1362 |
//! 3. Call RFile::Write() passing literal "This data should be flushed".
|
sl@0
|
1363 |
//! 4. Call RFile::Flush() passing TRequestStatus.
|
sl@0
|
1364 |
//! 5. Wait for request to complete.
|
sl@0
|
1365 |
//! 6. Close RFile.
|
sl@0
|
1366 |
//! 7. Delete file.
|
sl@0
|
1367 |
//! 8. Close RFs.
|
sl@0
|
1368 |
//!
|
sl@0
|
1369 |
//! @SYMTestStatus Implemented
|
sl@0
|
1370 |
//! @SYMTestPriority Critical
|
sl@0
|
1371 |
//! @SYMTestExpectedResults TRequestStatus returns KErrNone. File contains written data.
|
sl@0
|
1372 |
//!
|
sl@0
|
1373 |
//! @SYMTestType CIT
|
sl@0
|
1374 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
1375 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
1376 |
CREATE_OBJECT RFile file
|
sl@0
|
1377 |
COMMAND RFs1 new
|
sl@0
|
1378 |
COMMAND RFs1 Connect
|
sl@0
|
1379 |
COMMAND file new
|
sl@0
|
1380 |
COMMAND file Replace PBASE-F32-File-PublicApi-0027-001-Replace_command005
|
sl@0
|
1381 |
COMMAND file Write PBASE-F32-File-PublicApi-0027-001-Write_command006
|
sl@0
|
1382 |
COMMAND file Flush PBASE-F32-File-PublicApi-0027-001-Flush_command007
|
sl@0
|
1383 |
OUTSTANDING
|
sl@0
|
1384 |
COMMAND file Seek PBASE-F32-File-PublicApi-0027-001-Seek_command008
|
sl@0
|
1385 |
COMMAND file Read PBASE-F32-File-PublicApi-0027-001-Read_command009
|
sl@0
|
1386 |
COMMAND file Close
|
sl@0
|
1387 |
COMMAND file ~
|
sl@0
|
1388 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0027-001-Delete_command011
|
sl@0
|
1389 |
COMMAND RFs1 ~
|
sl@0
|
1390 |
END_TEST_BLOCK
|
sl@0
|
1391 |
END_TESTCASE PBASE-F32-File-PublicApi-0027
|
sl@0
|
1392 |
|
sl@0
|
1393 |
|
sl@0
|
1394 |
START_TESTCASE PBASE-F32-File-PublicApi-0028
|
sl@0
|
1395 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0028
|
sl@0
|
1396 |
//! @SYMAPI RFile
|
sl@0
|
1397 |
//! @SYMTestCaseDesc Function SetSize, Size() test - open file and set it's size, then get it.
|
sl@0
|
1398 |
//! Uses API elements: Open(), Flush(), Write().
|
sl@0
|
1399 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
1400 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0028.txt", EFileWrite.
|
sl@0
|
1401 |
//! 3. Write literal "Size test this text should be truncated" to file.
|
sl@0
|
1402 |
//! 4. Call RFile::SetSize() passing it 10 for size.
|
sl@0
|
1403 |
//! 5. Call RFile::Size.
|
sl@0
|
1404 |
//! 6. Close RFile.
|
sl@0
|
1405 |
//! 7. Delete file.
|
sl@0
|
1406 |
//! 8. Close RFs.
|
sl@0
|
1407 |
//!
|
sl@0
|
1408 |
//! @SYMTestStatus Implemented
|
sl@0
|
1409 |
//! @SYMTestPriority Critical
|
sl@0
|
1410 |
//! @SYMTestExpectedResults RFile::Size, RFile::SetSize returns KErrNone(). aSize equals with the size of file.
|
sl@0
|
1411 |
//!
|
sl@0
|
1412 |
//! @SYMTestType CIT
|
sl@0
|
1413 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
1414 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
1415 |
CREATE_OBJECT RFile file
|
sl@0
|
1416 |
COMMAND RFs1 new
|
sl@0
|
1417 |
COMMAND RFs1 Connect
|
sl@0
|
1418 |
COMMAND file new
|
sl@0
|
1419 |
COMMAND file Replace PBASE-F32-File-PublicApi-0028-001-Replace_command005
|
sl@0
|
1420 |
COMMAND file Write PBASE-F32-File-PublicApi-0028-001-Write_command006
|
sl@0
|
1421 |
COMMAND file SetSize PBASE-F32-File-PublicApi-0028-001-SetSize_command007
|
sl@0
|
1422 |
COMMAND file Size PBASE-F32-File-PublicApi-0028-001-Size_command008
|
sl@0
|
1423 |
COMMAND file Close
|
sl@0
|
1424 |
COMMAND file ~
|
sl@0
|
1425 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0028-001-Delete_command012
|
sl@0
|
1426 |
COMMAND RFs1 ~
|
sl@0
|
1427 |
END_TEST_BLOCK
|
sl@0
|
1428 |
END_TESTCASE PBASE-F32-File-PublicApi-0028
|
sl@0
|
1429 |
|
sl@0
|
1430 |
|
sl@0
|
1431 |
START_TESTCASE PBASE-F32-File-PublicApi-0029
|
sl@0
|
1432 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0029
|
sl@0
|
1433 |
//! @SYMAPI RFile
|
sl@0
|
1434 |
//! @SYMTestCaseDesc Function Att(), SetAtt test - open file and get it's attributes.
|
sl@0
|
1435 |
//! Uses API elements: Open(), Att().
|
sl@0
|
1436 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
1437 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0029.txt", EFileWrite.
|
sl@0
|
1438 |
//! 3. Write "SetAtt test" to file.
|
sl@0
|
1439 |
//! 4. Call RFile::SetAtt, passing KEntryAttNormal, KEntryAttReadOnly
|
sl@0
|
1440 |
//! 5. Flush data to file.
|
sl@0
|
1441 |
//! 6. Close file.
|
sl@0
|
1442 |
//! 7. Open file.
|
sl@0
|
1443 |
//! 8. Call RFile::Att().
|
sl@0
|
1444 |
//! 9. Close RFile.
|
sl@0
|
1445 |
//! 10. Delete file.
|
sl@0
|
1446 |
//! 11. Close RFs.
|
sl@0
|
1447 |
//!
|
sl@0
|
1448 |
//! @SYMTestStatus Implemented
|
sl@0
|
1449 |
//! @SYMTestPriority Critical
|
sl@0
|
1450 |
//! @SYMTestExpectedResults RFile::Att(), RFile::SetAtt returns KErrNone, aAttValue & KEntryAttNormal equals KEntryAttNormal.
|
sl@0
|
1451 |
//!
|
sl@0
|
1452 |
//! @SYMTestType CIT
|
sl@0
|
1453 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
1454 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
1455 |
CREATE_OBJECT RFile file
|
sl@0
|
1456 |
COMMAND RFs1 new
|
sl@0
|
1457 |
COMMAND RFs1 Connect
|
sl@0
|
1458 |
COMMAND file new
|
sl@0
|
1459 |
COMMAND file Replace PBASE-F32-File-PublicApi-0029-001-Replace_command005
|
sl@0
|
1460 |
COMMAND file Write PBASE-F32-File-PublicApi-0029-001-Write_command006
|
sl@0
|
1461 |
COMMAND file SetAtt PBASE-F32-File-PublicApi-0029-001-SetAtt_command007
|
sl@0
|
1462 |
COMMAND file Flush
|
sl@0
|
1463 |
COMMAND file Close
|
sl@0
|
1464 |
COMMAND file Open PBASE-F32-File-PublicApi-0029-001-Open_command010
|
sl@0
|
1465 |
COMMAND file Att PBASE-F32-File-PublicApi-0029-001-Att_command011
|
sl@0
|
1466 |
COMMAND file Close
|
sl@0
|
1467 |
COMMAND file ~
|
sl@0
|
1468 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0029-001-Delete_command015
|
sl@0
|
1469 |
COMMAND RFs1 ~
|
sl@0
|
1470 |
END_TEST_BLOCK
|
sl@0
|
1471 |
END_TESTCASE PBASE-F32-File-PublicApi-0029
|
sl@0
|
1472 |
|
sl@0
|
1473 |
|
sl@0
|
1474 |
START_TESTCASE PBASE-F32-File-PublicApi-0030
|
sl@0
|
1475 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0030
|
sl@0
|
1476 |
//! @SYMAPI RFile
|
sl@0
|
1477 |
//! @SYMTestCaseDesc Function Modified(), SetModified test - open file and get/set it's modification time.
|
sl@0
|
1478 |
//! Uses API elements: Open(), Modified(), SetModified().
|
sl@0
|
1479 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
1480 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0030.txt", EFileWrite.
|
sl@0
|
1481 |
//! 3. Call RFile::SetModified, passing 20070118:
|
sl@0
|
1482 |
//! 4. Close the file.
|
sl@0
|
1483 |
//! 5. Open the file.
|
sl@0
|
1484 |
//! 6. Call RFile::Modified().
|
sl@0
|
1485 |
//! 7. Close RFile.
|
sl@0
|
1486 |
//! 8. Delete file.
|
sl@0
|
1487 |
//! 9. Close RFs.
|
sl@0
|
1488 |
//!
|
sl@0
|
1489 |
//! @SYMTestStatus Implemented
|
sl@0
|
1490 |
//! @SYMTestPriority Critical
|
sl@0
|
1491 |
//! @SYMTestExpectedResults RFile::Modified(), RFile::SetModified returns KErrNone. Modified returns same date as was set with SetModified.
|
sl@0
|
1492 |
//!
|
sl@0
|
1493 |
//! @SYMTestType CIT
|
sl@0
|
1494 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
1495 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
1496 |
CREATE_OBJECT RFile file
|
sl@0
|
1497 |
COMMAND RFs1 new
|
sl@0
|
1498 |
COMMAND RFs1 Connect
|
sl@0
|
1499 |
COMMAND file new
|
sl@0
|
1500 |
COMMAND file Replace PBASE-F32-File-PublicApi-0030-001-Replace_command005
|
sl@0
|
1501 |
COMMAND file SetModified PBASE-F32-File-PublicApi-0030-001-SetModified_command006
|
sl@0
|
1502 |
COMMAND file Close
|
sl@0
|
1503 |
COMMAND file Open PBASE-F32-File-PublicApi-0030-001-Open_command008
|
sl@0
|
1504 |
COMMAND file Modified PBASE-F32-File-PublicApi-0030-001-Modified_command009
|
sl@0
|
1505 |
COMMAND file Close
|
sl@0
|
1506 |
COMMAND file ~
|
sl@0
|
1507 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0030-001-Delete_command012
|
sl@0
|
1508 |
COMMAND RFs1 ~
|
sl@0
|
1509 |
END_TEST_BLOCK
|
sl@0
|
1510 |
END_TESTCASE PBASE-F32-File-PublicApi-0030
|
sl@0
|
1511 |
|
sl@0
|
1512 |
|
sl@0
|
1513 |
START_TESTCASE PBASE-F32-File-PublicApi-0031
|
sl@0
|
1514 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0031
|
sl@0
|
1515 |
//! @SYMAPI RFile
|
sl@0
|
1516 |
//! @SYMTestCaseDesc Function Set() test - open file and set it's modification time and attributes.
|
sl@0
|
1517 |
//! Uses API elements: Open(), Set(), Modified(), Att().
|
sl@0
|
1518 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
1519 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0031.txt", EFileShareAny.
|
sl@0
|
1520 |
//! 3. Call RFile::Set() passing it 20070118:, KEntryAttArchive, KEntryAttReadOnly.
|
sl@0
|
1521 |
//! 4. Call RFile::Modified() to validate modification date.
|
sl@0
|
1522 |
//! 5. Call RFile::Att() to validate attributes.
|
sl@0
|
1523 |
//! 6. Close RFile.
|
sl@0
|
1524 |
//! 7. Delete file.
|
sl@0
|
1525 |
//! 8. Close RFs.
|
sl@0
|
1526 |
//!
|
sl@0
|
1527 |
//! @SYMTestStatus Implemented
|
sl@0
|
1528 |
//! @SYMTestPriority Critical
|
sl@0
|
1529 |
//! @SYMTestExpectedResults RFile::Set() returns KErrNone. Data and attributes are validated.
|
sl@0
|
1530 |
//!
|
sl@0
|
1531 |
//! @SYMTestType CIT
|
sl@0
|
1532 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
1533 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
1534 |
CREATE_OBJECT RFile file
|
sl@0
|
1535 |
COMMAND RFs1 new
|
sl@0
|
1536 |
COMMAND RFs1 Connect
|
sl@0
|
1537 |
COMMAND file new
|
sl@0
|
1538 |
COMMAND file Replace PBASE-F32-File-PublicApi-0031-001-Replace_command005
|
sl@0
|
1539 |
COMMAND file Set PBASE-F32-File-PublicApi-0031-001-Set_command006
|
sl@0
|
1540 |
COMMAND file Att PBASE-F32-File-PublicApi-0031-001-Att_command007
|
sl@0
|
1541 |
COMMAND file Modified PBASE-F32-File-PublicApi-0031-001-Modified_command008
|
sl@0
|
1542 |
COMMAND file Close
|
sl@0
|
1543 |
COMMAND file ~
|
sl@0
|
1544 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0031-001-Delete_command012
|
sl@0
|
1545 |
COMMAND RFs1 ~
|
sl@0
|
1546 |
END_TEST_BLOCK
|
sl@0
|
1547 |
END_TESTCASE PBASE-F32-File-PublicApi-0031
|
sl@0
|
1548 |
|
sl@0
|
1549 |
|
sl@0
|
1550 |
START_TESTCASE PBASE-F32-File-PublicApi-0032
|
sl@0
|
1551 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0032
|
sl@0
|
1552 |
//! @SYMAPI RFile
|
sl@0
|
1553 |
//! @SYMTestCaseDesc Function ChangeMode() test - open file and change it's access mode.
|
sl@0
|
1554 |
//! Uses API elements: Open(), SetModified().
|
sl@0
|
1555 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
1556 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0032.txt".
|
sl@0
|
1557 |
//! 3. Close file.
|
sl@0
|
1558 |
//! 4. open the file in EFileShareExclusive mode.
|
sl@0
|
1559 |
//! 5. Call RFile::ChangeMode() passing it EFileShareReadersOnly.
|
sl@0
|
1560 |
//! 6. Close RFile.
|
sl@0
|
1561 |
//! 7. Delete file.
|
sl@0
|
1562 |
//! 8. Close RFs.
|
sl@0
|
1563 |
//!
|
sl@0
|
1564 |
//! @SYMTestStatus Implemented
|
sl@0
|
1565 |
//! @SYMTestPriority Critical
|
sl@0
|
1566 |
//! @SYMTestExpectedResults RFile::ChangeMode() returns KErrNone. Filemode is EFileSareReadersOnly.
|
sl@0
|
1567 |
//!
|
sl@0
|
1568 |
//! @SYMTestType CIT
|
sl@0
|
1569 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
1570 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
1571 |
CREATE_OBJECT RFile file
|
sl@0
|
1572 |
COMMAND RFs1 new
|
sl@0
|
1573 |
COMMAND RFs1 Connect
|
sl@0
|
1574 |
COMMAND file new
|
sl@0
|
1575 |
COMMAND file Replace PBASE-F32-File-PublicApi-0032-001-Replace_command005
|
sl@0
|
1576 |
COMMAND file Close
|
sl@0
|
1577 |
COMMAND file Open PBASE-F32-File-PublicApi-0032-001-Open_command007
|
sl@0
|
1578 |
COMMAND file ChangeMode PBASE-F32-File-PublicApi-0032-001-ChangeMode_command008
|
sl@0
|
1579 |
COMMAND file Close
|
sl@0
|
1580 |
COMMAND file ~
|
sl@0
|
1581 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0032-001-Delete_command012
|
sl@0
|
1582 |
COMMAND RFs1 ~
|
sl@0
|
1583 |
END_TEST_BLOCK
|
sl@0
|
1584 |
END_TESTCASE PBASE-F32-File-PublicApi-0032
|
sl@0
|
1585 |
|
sl@0
|
1586 |
|
sl@0
|
1587 |
START_TESTCASE PBASE-F32-File-PublicApi-0033
|
sl@0
|
1588 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0033
|
sl@0
|
1589 |
//! @SYMAPI RFile
|
sl@0
|
1590 |
//! @SYMTestCaseDesc Function Rename() test - open file and rename it.
|
sl@0
|
1591 |
//! Uses API elements: Open(), RFile::Rename().
|
sl@0
|
1592 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
1593 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0033.txt", EFileShareExclusive | EFileWrite.
|
sl@0
|
1594 |
//! 3. Call RFile::Rename() passing it string literal "test_renamed.txt".
|
sl@0
|
1595 |
//! 4. Call RFile::Name.
|
sl@0
|
1596 |
//! 5. rename the file back to tc0033.txt
|
sl@0
|
1597 |
//! 6. Delete file.
|
sl@0
|
1598 |
//! 7. Close resources.
|
sl@0
|
1599 |
//!
|
sl@0
|
1600 |
//! @SYMTestStatus Implemented
|
sl@0
|
1601 |
//! @SYMTestPriority Critical
|
sl@0
|
1602 |
//! @SYMTestExpectedResults RFile::Rename() returns KErrNone. File is renamed.
|
sl@0
|
1603 |
//!
|
sl@0
|
1604 |
//! @SYMTestType CIT
|
sl@0
|
1605 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
1606 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
1607 |
CREATE_OBJECT RFile file
|
sl@0
|
1608 |
COMMAND RFs1 new
|
sl@0
|
1609 |
COMMAND RFs1 Connect
|
sl@0
|
1610 |
COMMAND file new
|
sl@0
|
1611 |
COMMAND file Replace PBASE-F32-File-PublicApi-0033-001-Replace_command005
|
sl@0
|
1612 |
COMMAND file Rename PBASE-F32-File-PublicApi-0033-001-Rename_command006
|
sl@0
|
1613 |
COMMAND file Name
|
sl@0
|
1614 |
COMMAND file Rename PBASE-F32-File-PublicApi-0033-001-Rename_command008
|
sl@0
|
1615 |
COMMAND file Close
|
sl@0
|
1616 |
COMMAND file ~
|
sl@0
|
1617 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0033-001-Delete_command012
|
sl@0
|
1618 |
COMMAND RFs1 ~
|
sl@0
|
1619 |
END_TEST_BLOCK
|
sl@0
|
1620 |
END_TESTCASE PBASE-F32-File-PublicApi-0033
|
sl@0
|
1621 |
|
sl@0
|
1622 |
|
sl@0
|
1623 |
START_TESTCASE PBASE-F32-File-PublicApi-0034
|
sl@0
|
1624 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0034
|
sl@0
|
1625 |
//! @SYMAPI RFile
|
sl@0
|
1626 |
//! @SYMTestCaseDesc Function Drive() test - open file and get it's drive info.
|
sl@0
|
1627 |
//! Uses API elements: RFile::Drive().
|
sl@0
|
1628 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
1629 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0034.txt", EFileShareAny.
|
sl@0
|
1630 |
//! 3. Call RFile::Drive().
|
sl@0
|
1631 |
//! 4. Close RFile.
|
sl@0
|
1632 |
//! 5. Delete file.
|
sl@0
|
1633 |
//! 6. Close RFs.
|
sl@0
|
1634 |
//!
|
sl@0
|
1635 |
//! @SYMTestStatus Implemented
|
sl@0
|
1636 |
//! @SYMTestPriority Critical
|
sl@0
|
1637 |
//! @SYMTestExpectedResults RFile::Drive() returns KErrNone.
|
sl@0
|
1638 |
//!
|
sl@0
|
1639 |
//! @SYMTestType CIT
|
sl@0
|
1640 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
1641 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
1642 |
CREATE_OBJECT RFile file
|
sl@0
|
1643 |
COMMAND RFs1 new
|
sl@0
|
1644 |
COMMAND RFs1 Connect
|
sl@0
|
1645 |
COMMAND file new
|
sl@0
|
1646 |
COMMAND file Replace PBASE-F32-File-PublicApi-0034-001-Replace_command005
|
sl@0
|
1647 |
COMMAND file Drive PBASE-F32-File-PublicApi-0034-001-Drive_command006
|
sl@0
|
1648 |
COMMAND file Close
|
sl@0
|
1649 |
COMMAND file ~
|
sl@0
|
1650 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0034-001-Delete_command010
|
sl@0
|
1651 |
COMMAND RFs1 ~
|
sl@0
|
1652 |
END_TEST_BLOCK
|
sl@0
|
1653 |
END_TESTCASE PBASE-F32-File-PublicApi-0034
|
sl@0
|
1654 |
|
sl@0
|
1655 |
|
sl@0
|
1656 |
START_TESTCASE PBASE-F32-File-PublicApi-0039
|
sl@0
|
1657 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0039
|
sl@0
|
1658 |
//! @SYMAPI RFile
|
sl@0
|
1659 |
//! @SYMTestCaseDesc Function Name() test. Open a file and get it's name.
|
sl@0
|
1660 |
//! Uses API elements: Name().
|
sl@0
|
1661 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
1662 |
//! 2. Open file "{Drives, RAMDriveTestPath}file\tc0039.txt" as file1
|
sl@0
|
1663 |
//! 3. Call RFile::Name().
|
sl@0
|
1664 |
//! 4. Close file system.
|
sl@0
|
1665 |
//! 5. Delete file.
|
sl@0
|
1666 |
//! 6. Close file.
|
sl@0
|
1667 |
//!
|
sl@0
|
1668 |
//! @SYMTestStatus Implemented
|
sl@0
|
1669 |
//! @SYMTestPriority Critical
|
sl@0
|
1670 |
//! @SYMTestExpectedResults RFile::Name() returns KErrNone. File name is verified.
|
sl@0
|
1671 |
//!
|
sl@0
|
1672 |
//! @SYMTestType CIT
|
sl@0
|
1673 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
1674 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
1675 |
CREATE_OBJECT RFile file
|
sl@0
|
1676 |
COMMAND RFs1 new
|
sl@0
|
1677 |
COMMAND RFs1 Connect
|
sl@0
|
1678 |
COMMAND file new
|
sl@0
|
1679 |
COMMAND file Replace PBASE-F32-File-PublicApi-0039-001-Replace_command005
|
sl@0
|
1680 |
COMMAND file Name PBASE-F32-File-PublicApi-0039-001-Name_command006
|
sl@0
|
1681 |
COMMAND file Close
|
sl@0
|
1682 |
COMMAND file ~
|
sl@0
|
1683 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0039-001-Delete_command010
|
sl@0
|
1684 |
COMMAND RFs1 ~
|
sl@0
|
1685 |
END_TEST_BLOCK
|
sl@0
|
1686 |
END_TESTCASE PBASE-F32-File-PublicApi-0039
|
sl@0
|
1687 |
|
sl@0
|
1688 |
|
sl@0
|
1689 |
START_TESTCASE PBASE-F32-File-PublicApi-0040
|
sl@0
|
1690 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0040
|
sl@0
|
1691 |
//! @SYMAPI RFile
|
sl@0
|
1692 |
//! @SYMTestCaseDesc Function Duplicate() test. Duplicate a file and compare it size to original.
|
sl@0
|
1693 |
//! Uses API elements: Duplicate().
|
sl@0
|
1694 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
1695 |
//! 2. Replace file "{Drives, RAMDriveTestPath}file\tc0040.txt" as file1, with EFileWrite permission
|
sl@0
|
1696 |
//! 3. Write "Duplicate Test" to file
|
sl@0
|
1697 |
//! 4. Create file2 by calling RFile::Duplicate(), passing reference to file1.
|
sl@0
|
1698 |
//! 5. Read from file2 to verify that file1 has been duplicated.
|
sl@0
|
1699 |
//! 6. Close file1.
|
sl@0
|
1700 |
//! 7. Close file2.
|
sl@0
|
1701 |
//! 8. Delete file1
|
sl@0
|
1702 |
//! 9. Close fs session.
|
sl@0
|
1703 |
//!
|
sl@0
|
1704 |
//! @SYMTestStatus Implemented
|
sl@0
|
1705 |
//! @SYMTestPriority Critical
|
sl@0
|
1706 |
//! @SYMTestExpectedResults RFile::Duplicate() returns KErrNone. The content of file1 and file2 is equal.
|
sl@0
|
1707 |
//!
|
sl@0
|
1708 |
//! @SYMTestType CIT
|
sl@0
|
1709 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
1710 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
1711 |
CREATE_OBJECT RFile file
|
sl@0
|
1712 |
CREATE_OBJECT RFile file2
|
sl@0
|
1713 |
COMMAND RFs1 new
|
sl@0
|
1714 |
COMMAND RFs1 Connect
|
sl@0
|
1715 |
COMMAND file new
|
sl@0
|
1716 |
COMMAND file Replace PBASE-F32-File-PublicApi-0040-001-Replace_command005
|
sl@0
|
1717 |
COMMAND file Write PBASE-F32-File-PublicApi-0040-001-Write_command006
|
sl@0
|
1718 |
COMMAND file Seek PBASE-F32-File-PublicApi-0040-001-Seek_command007
|
sl@0
|
1719 |
COMMAND file2 new
|
sl@0
|
1720 |
COMMAND file2 Duplicate PBASE-F32-File-PublicApi-0040-001-Duplicate_command010
|
sl@0
|
1721 |
COMMAND file2 Read PBASE-F32-File-PublicApi-0040-001-Read_command011
|
sl@0
|
1722 |
COMMAND file2 Close
|
sl@0
|
1723 |
COMMAND file2 ~
|
sl@0
|
1724 |
COMMAND file Close
|
sl@0
|
1725 |
COMMAND file ~
|
sl@0
|
1726 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0040-001-Delete_command017
|
sl@0
|
1727 |
COMMAND RFs1 ~
|
sl@0
|
1728 |
END_TEST_BLOCK
|
sl@0
|
1729 |
END_TESTCASE PBASE-F32-File-PublicApi-0040
|
sl@0
|
1730 |
|
sl@0
|
1731 |
|
sl@0
|
1732 |
START_TESTCASE PBASE-F32-File-PublicApi-1040
|
sl@0
|
1733 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-1040
|
sl@0
|
1734 |
//! @SYMAPI RFile
|
sl@0
|
1735 |
//! @SYMTestCaseDesc Function Duplicate() with aType = EOwnerThread test. Duplicate file and compare it size to original.
|
sl@0
|
1736 |
//! Uses API elements: Duplicate().
|
sl@0
|
1737 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
1738 |
//! 2. Replace file "{Drives, RAMDriveTestPath}file\tc1040.txt" as file1, with EFileWrite permission
|
sl@0
|
1739 |
//! 3. Write "Duplicate Test" to file
|
sl@0
|
1740 |
//! 4. Create file2 by calling RFile::Duplicate(), passing reference to file1.
|
sl@0
|
1741 |
//! 5. Read from file2 to verify that file1 has been duplicated.
|
sl@0
|
1742 |
//! 6. Close file1.
|
sl@0
|
1743 |
//! 7. Close file2.
|
sl@0
|
1744 |
//! 8. Delete file1.
|
sl@0
|
1745 |
//! 9. Close fs session.
|
sl@0
|
1746 |
//!
|
sl@0
|
1747 |
//! @SYMTestStatus Implemented
|
sl@0
|
1748 |
//! @SYMTestPriority Critical
|
sl@0
|
1749 |
//! @SYMTestExpectedResults RFile::Duplicate() returns KErrNone. The content of file1 and file2 is equal.
|
sl@0
|
1750 |
//!
|
sl@0
|
1751 |
//! @SYMTestType CIT
|
sl@0
|
1752 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
1753 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
1754 |
CREATE_OBJECT RFile file
|
sl@0
|
1755 |
CREATE_OBJECT RFile file2
|
sl@0
|
1756 |
COMMAND RFs1 new
|
sl@0
|
1757 |
COMMAND RFs1 Connect
|
sl@0
|
1758 |
COMMAND file new
|
sl@0
|
1759 |
COMMAND file Replace PBASE-F32-File-PublicApi-1040-001-Replace_command005
|
sl@0
|
1760 |
COMMAND file Write PBASE-F32-File-PublicApi-1040-001-Write_command006
|
sl@0
|
1761 |
COMMAND file Seek PBASE-F32-File-PublicApi-1040-001-Seek_command007
|
sl@0
|
1762 |
COMMAND file2 new
|
sl@0
|
1763 |
COMMAND file2 Duplicate PBASE-F32-File-PublicApi-1040-001-Duplicate_command010
|
sl@0
|
1764 |
COMMAND file2 Read PBASE-F32-File-PublicApi-1040-001-Read_command011
|
sl@0
|
1765 |
COMMAND file2 Close
|
sl@0
|
1766 |
COMMAND file2 ~
|
sl@0
|
1767 |
COMMAND file Close
|
sl@0
|
1768 |
COMMAND file ~
|
sl@0
|
1769 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-1040-001-Delete_command017
|
sl@0
|
1770 |
COMMAND RFs1 ~
|
sl@0
|
1771 |
END_TEST_BLOCK
|
sl@0
|
1772 |
END_TESTCASE PBASE-F32-File-PublicApi-1040
|
sl@0
|
1773 |
|
sl@0
|
1774 |
|
sl@0
|
1775 |
START_TESTCASE PBASE-F32-File-PublicApi-0041
|
sl@0
|
1776 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0041
|
sl@0
|
1777 |
//! @SYMAPI RFile
|
sl@0
|
1778 |
//! @SYMTestCaseDesc Function FullName() test. Open a file and get it's full name.
|
sl@0
|
1779 |
//! Uses API elements: FullName().
|
sl@0
|
1780 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
1781 |
//! 2. Replace file "{Drives, RAMDriveTestPath}file\tc0041.txt"
|
sl@0
|
1782 |
//! 3. Call FullName.
|
sl@0
|
1783 |
//! 4. Close file.
|
sl@0
|
1784 |
//! 5. Delete file.
|
sl@0
|
1785 |
//! 6. Close fs session.
|
sl@0
|
1786 |
//!
|
sl@0
|
1787 |
//!
|
sl@0
|
1788 |
//! @SYMTestStatus Implemented
|
sl@0
|
1789 |
//! @SYMTestPriority Critical
|
sl@0
|
1790 |
//! @SYMTestExpectedResults RFile::FullName returns KErrNone. Descriptor retrieved from FullName is equal to the path and name of the file.
|
sl@0
|
1791 |
//!
|
sl@0
|
1792 |
//! @SYMTestType CIT
|
sl@0
|
1793 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
1794 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
1795 |
CREATE_OBJECT RFile file
|
sl@0
|
1796 |
COMMAND RFs1 new
|
sl@0
|
1797 |
COMMAND RFs1 Connect
|
sl@0
|
1798 |
COMMAND file new
|
sl@0
|
1799 |
COMMAND file Replace PBASE-F32-File-PublicApi-0041-001-Replace_command005
|
sl@0
|
1800 |
COMMAND file FullName PBASE-F32-File-PublicApi-0041-001-FullName_command006
|
sl@0
|
1801 |
COMMAND file Close
|
sl@0
|
1802 |
COMMAND file ~
|
sl@0
|
1803 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0041-001-Delete_command010
|
sl@0
|
1804 |
COMMAND RFs1 ~
|
sl@0
|
1805 |
END_TEST_BLOCK
|
sl@0
|
1806 |
END_TESTCASE PBASE-F32-File-PublicApi-0041
|
sl@0
|
1807 |
|
sl@0
|
1808 |
|
sl@0
|
1809 |
//////////////////////////////////////////////////////////////////////
|
sl@0
|
1810 |
//////////////////////////////////////////////////////////////////////
|
sl@0
|
1811 |
////// //////
|
sl@0
|
1812 |
////// /////////////////////////////////// //////
|
sl@0
|
1813 |
////// /// /// //////
|
sl@0
|
1814 |
////// /// NEGATIVE TESTS /// //////
|
sl@0
|
1815 |
////// /// /// //////
|
sl@0
|
1816 |
////// /////////////////////////////////// //////
|
sl@0
|
1817 |
////// //////
|
sl@0
|
1818 |
//////////////////////////////////////////////////////////////////////
|
sl@0
|
1819 |
//////////////////////////////////////////////////////////////////////
|
sl@0
|
1820 |
|
sl@0
|
1821 |
|
sl@0
|
1822 |
START_TESTCASE PBASE-F32-File-PublicApi-0101
|
sl@0
|
1823 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0101
|
sl@0
|
1824 |
//! @SYMAPI RFile
|
sl@0
|
1825 |
//! @SYMTestCaseDesc Function Open() neg. test. Call open with invalid path.
|
sl@0
|
1826 |
//! Uses API elements: Open().
|
sl@0
|
1827 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
1828 |
//! 2. Open file "{Drives, RAMDriveTestPath}file\base\chickenfarm\chicken.txt"
|
sl@0
|
1829 |
//! 3. Close fs.
|
sl@0
|
1830 |
//!
|
sl@0
|
1831 |
//! @SYMTestStatus Implemented
|
sl@0
|
1832 |
//! @SYMTestPriority Critical
|
sl@0
|
1833 |
//! @SYMTestExpectedResults open returns KErrPathNotFound! on step 2.
|
sl@0
|
1834 |
//!
|
sl@0
|
1835 |
//! @SYMTestType CIT
|
sl@0
|
1836 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
1837 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
1838 |
CREATE_OBJECT RFile file
|
sl@0
|
1839 |
COMMAND RFs1 new
|
sl@0
|
1840 |
COMMAND RFs1 Connect
|
sl@0
|
1841 |
COMMAND file new
|
sl@0
|
1842 |
COMMAND !Error=-12 file Open PBASE-F32-File-PublicApi-0101-001-Open_command005
|
sl@0
|
1843 |
COMMAND file ~
|
sl@0
|
1844 |
COMMAND RFs1 ~
|
sl@0
|
1845 |
END_TEST_BLOCK
|
sl@0
|
1846 |
END_TESTCASE PBASE-F32-File-PublicApi-0101
|
sl@0
|
1847 |
|
sl@0
|
1848 |
|
sl@0
|
1849 |
|
sl@0
|
1850 |
|
sl@0
|
1851 |
START_TESTCASE PBASE-F32-File-PublicApi-0103
|
sl@0
|
1852 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0103
|
sl@0
|
1853 |
//! @SYMAPI RFile
|
sl@0
|
1854 |
//! @SYMTestCaseDesc Function Open() neg. test. Call open with invalid filemodes.
|
sl@0
|
1855 |
//! Uses API elements: Open().
|
sl@0
|
1856 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
1857 |
//! 2. Create file "{Drives, RAMDriveTestPath}file\tc0103.txt".
|
sl@0
|
1858 |
//! 3. Close file.
|
sl@0
|
1859 |
//! 4. Open file "{Drives, RAMDriveTestPath}file\tc0103.txt" with EFileShareReadersOnly | EFileWrite.
|
sl@0
|
1860 |
//! 5. Delete file.
|
sl@0
|
1861 |
//! 6. Close fs.
|
sl@0
|
1862 |
//!
|
sl@0
|
1863 |
//! @SYMTestStatus Implemented
|
sl@0
|
1864 |
//! @SYMTestPriority Critical
|
sl@0
|
1865 |
//! @SYMTestExpectedResults Open returns KErrArgument on step 2.
|
sl@0
|
1866 |
//!
|
sl@0
|
1867 |
//! @SYMTestType CIT
|
sl@0
|
1868 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
1869 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
1870 |
CREATE_OBJECT RFile file
|
sl@0
|
1871 |
COMMAND RFs1 new
|
sl@0
|
1872 |
COMMAND RFs1 Connect
|
sl@0
|
1873 |
COMMAND file new
|
sl@0
|
1874 |
COMMAND file Replace PBASE-F32-File-PublicApi-0103-001-Replace_command005
|
sl@0
|
1875 |
COMMAND file Close
|
sl@0
|
1876 |
COMMAND !Error=-6 file Open PBASE-F32-File-PublicApi-0103-001-Open_command007
|
sl@0
|
1877 |
COMMAND file ~
|
sl@0
|
1878 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0103-001-Delete_command010
|
sl@0
|
1879 |
COMMAND RFs1 ~
|
sl@0
|
1880 |
END_TEST_BLOCK
|
sl@0
|
1881 |
END_TESTCASE PBASE-F32-File-PublicApi-0103
|
sl@0
|
1882 |
|
sl@0
|
1883 |
|
sl@0
|
1884 |
//
|
sl@0
|
1885 |
// Create
|
sl@0
|
1886 |
//
|
sl@0
|
1887 |
|
sl@0
|
1888 |
|
sl@0
|
1889 |
START_TESTCASE PBASE-F32-File-PublicApi-0201
|
sl@0
|
1890 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0201
|
sl@0
|
1891 |
//! @SYMAPI RFile
|
sl@0
|
1892 |
//! @SYMTestCaseDesc Function Create() neg. test. Try to Create a file in nonexistant folder.
|
sl@0
|
1893 |
//! Uses API elements: Create().
|
sl@0
|
1894 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
1895 |
//! 2. Call RFile::Create passing RFs, literal "{Drives, RAMDriveTestPath}file\base\chickenfarm\chicken.txt", EFileShareAny
|
sl@0
|
1896 |
//! 3. Close RFs.
|
sl@0
|
1897 |
//!
|
sl@0
|
1898 |
//! @SYMTestStatus Implemented
|
sl@0
|
1899 |
//! @SYMTestPriority Critical
|
sl@0
|
1900 |
//! @SYMTestExpectedResults RFile::Create() returns KErrPathNotFound on step 2.
|
sl@0
|
1901 |
//!
|
sl@0
|
1902 |
//! @SYMTestType CIT
|
sl@0
|
1903 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
1904 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
1905 |
CREATE_OBJECT RFile file
|
sl@0
|
1906 |
COMMAND RFs1 new
|
sl@0
|
1907 |
COMMAND RFs1 Connect
|
sl@0
|
1908 |
COMMAND file new
|
sl@0
|
1909 |
COMMAND !Error=-12 file Create PBASE-F32-File-PublicApi-0201-001-Create_command005
|
sl@0
|
1910 |
COMMAND file ~
|
sl@0
|
1911 |
COMMAND RFs1 ~
|
sl@0
|
1912 |
END_TEST_BLOCK
|
sl@0
|
1913 |
END_TESTCASE PBASE-F32-File-PublicApi-0201
|
sl@0
|
1914 |
|
sl@0
|
1915 |
|
sl@0
|
1916 |
START_TESTCASE PBASE-F32-File-PublicApi-0202
|
sl@0
|
1917 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0202
|
sl@0
|
1918 |
//! @SYMAPI RFile
|
sl@0
|
1919 |
//! @SYMTestCaseDesc Function Create() neg. test. Try to Create a file which already exists.
|
sl@0
|
1920 |
//! Uses API elements: Create().
|
sl@0
|
1921 |
//! @SYMTestActions 1. Create RFs handle.
|
sl@0
|
1922 |
//! 2. Create a File, by calling RFile::Replace with "{Drives, RAMDriveTestPath}file\tc0202.txt", EFileWrite.
|
sl@0
|
1923 |
//! 3. Close file.
|
sl@0
|
1924 |
//! 4. Call RFile::Create passing "{Drives, RAMDriveTestPath}file\tc0202.txt", EFileWrite.
|
sl@0
|
1925 |
//! 5. Delete file.
|
sl@0
|
1926 |
//! 6. Close fs.
|
sl@0
|
1927 |
//!
|
sl@0
|
1928 |
//! @SYMTestStatus Implemented
|
sl@0
|
1929 |
//! @SYMTestPriority Critical
|
sl@0
|
1930 |
//! @SYMTestExpectedResults KErrAlreadyExists on step 3
|
sl@0
|
1931 |
//!
|
sl@0
|
1932 |
//! @SYMTestType CIT
|
sl@0
|
1933 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
1934 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
1935 |
CREATE_OBJECT RFile file
|
sl@0
|
1936 |
COMMAND RFs1 new
|
sl@0
|
1937 |
COMMAND RFs1 Connect
|
sl@0
|
1938 |
COMMAND file new
|
sl@0
|
1939 |
COMMAND file Replace PBASE-F32-File-PublicApi-0202-001-Replace_command005
|
sl@0
|
1940 |
COMMAND file Close
|
sl@0
|
1941 |
COMMAND !Error=-11 file Create PBASE-F32-File-PublicApi-0202-001-Create_command007
|
sl@0
|
1942 |
COMMAND file ~
|
sl@0
|
1943 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0202-001-Delete_command010
|
sl@0
|
1944 |
COMMAND RFs1 ~
|
sl@0
|
1945 |
END_TEST_BLOCK
|
sl@0
|
1946 |
END_TESTCASE PBASE-F32-File-PublicApi-0202
|
sl@0
|
1947 |
|
sl@0
|
1948 |
|
sl@0
|
1949 |
START_TESTCASE PBASE-F32-File-PublicApi-0203
|
sl@0
|
1950 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0203
|
sl@0
|
1951 |
//! @SYMAPI RFile
|
sl@0
|
1952 |
//! @SYMTestCaseDesc Function Create() neg. test. Try to Create a file with bizarre filemodes.
|
sl@0
|
1953 |
//! Uses API elements: Create().
|
sl@0
|
1954 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
1955 |
//! 2. Replace file "{Drives, RAMDriveTestPath}file\tc0203.txt"
|
sl@0
|
1956 |
//! 3. Delete file "{Drives, RAMDriveTestPath}file\tc0203.txt"
|
sl@0
|
1957 |
//! 2. Create file "{Drives, RAMDriveTestPath}file\tc0203.txt" with EFileShareReadersOnly | EFileWrite
|
sl@0
|
1958 |
//! 3. Close session.
|
sl@0
|
1959 |
//!
|
sl@0
|
1960 |
//! @SYMTestStatus Implemented
|
sl@0
|
1961 |
//! @SYMTestPriority Critical
|
sl@0
|
1962 |
//! @SYMTestExpectedResults Create returns KErrArgument on step 2.
|
sl@0
|
1963 |
//!
|
sl@0
|
1964 |
//! @SYMTestType CIT
|
sl@0
|
1965 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
1966 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
1967 |
CREATE_OBJECT RFile file
|
sl@0
|
1968 |
COMMAND RFs1 new
|
sl@0
|
1969 |
COMMAND RFs1 Connect
|
sl@0
|
1970 |
COMMAND file new
|
sl@0
|
1971 |
COMMAND file Replace PBASE-F32-File-PublicApi-0203-001-Replace_command001
|
sl@0
|
1972 |
COMMAND file Close
|
sl@0
|
1973 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0203-001-Delete_command002
|
sl@0
|
1974 |
COMMAND !Error=-6 file Create PBASE-F32-File-PublicApi-0203-001-Create_command005
|
sl@0
|
1975 |
COMMAND file ~
|
sl@0
|
1976 |
COMMAND RFs1 ~
|
sl@0
|
1977 |
END_TEST_BLOCK
|
sl@0
|
1978 |
END_TESTCASE PBASE-F32-File-PublicApi-0203
|
sl@0
|
1979 |
|
sl@0
|
1980 |
|
sl@0
|
1981 |
//
|
sl@0
|
1982 |
// Replace
|
sl@0
|
1983 |
//
|
sl@0
|
1984 |
|
sl@0
|
1985 |
|
sl@0
|
1986 |
START_TESTCASE PBASE-F32-File-PublicApi-0301
|
sl@0
|
1987 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0301
|
sl@0
|
1988 |
//! @SYMAPI RFile
|
sl@0
|
1989 |
//! @SYMTestCaseDesc Function Replace() neg. test. Replace a file with nonexistant path.
|
sl@0
|
1990 |
//! Uses API elements: Replace().
|
sl@0
|
1991 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
1992 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\base\chickenfarm\chicken.txt", EFileWrite
|
sl@0
|
1993 |
//! 3. Close RFs.
|
sl@0
|
1994 |
//!
|
sl@0
|
1995 |
//! @SYMTestStatus Implemented
|
sl@0
|
1996 |
//! @SYMTestPriority Critical
|
sl@0
|
1997 |
//! @SYMTestExpectedResults RFile::Replace() returns KErrPathNotFound on step 2.
|
sl@0
|
1998 |
//!
|
sl@0
|
1999 |
//! @SYMTestType CIT
|
sl@0
|
2000 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2001 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2002 |
CREATE_OBJECT RFile file
|
sl@0
|
2003 |
COMMAND RFs1 new
|
sl@0
|
2004 |
COMMAND RFs1 Connect
|
sl@0
|
2005 |
COMMAND file new
|
sl@0
|
2006 |
COMMAND !Error=-12 file Replace PBASE-F32-File-PublicApi-0301-001-Replace_command005
|
sl@0
|
2007 |
COMMAND file ~
|
sl@0
|
2008 |
COMMAND RFs1 ~
|
sl@0
|
2009 |
END_TEST_BLOCK
|
sl@0
|
2010 |
END_TESTCASE PBASE-F32-File-PublicApi-0301
|
sl@0
|
2011 |
|
sl@0
|
2012 |
|
sl@0
|
2013 |
START_TESTCASE PBASE-F32-File-PublicApi-0303
|
sl@0
|
2014 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0303
|
sl@0
|
2015 |
//! @SYMAPI RFile
|
sl@0
|
2016 |
//! @SYMTestCaseDesc Function Replace() neg. test. Call Replace with bizarre filemodes.
|
sl@0
|
2017 |
//! Uses API elements: Replace().
|
sl@0
|
2018 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
2019 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0303.txt", EFileShareReadersOnly | EFileWrite
|
sl@0
|
2020 |
//! 3. Close RFs.
|
sl@0
|
2021 |
//!
|
sl@0
|
2022 |
//! @SYMTestStatus Implemented
|
sl@0
|
2023 |
//! @SYMTestPriority Critical
|
sl@0
|
2024 |
//! @SYMTestExpectedResults returns KErrArgument on step 2.
|
sl@0
|
2025 |
//!
|
sl@0
|
2026 |
//! @SYMTestType CIT
|
sl@0
|
2027 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2028 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2029 |
CREATE_OBJECT RFile file
|
sl@0
|
2030 |
COMMAND RFs1 new
|
sl@0
|
2031 |
COMMAND RFs1 Connect
|
sl@0
|
2032 |
COMMAND file new
|
sl@0
|
2033 |
COMMAND !Error=-6 file Replace PBASE-F32-File-PublicApi-0303-001-Replace_command005
|
sl@0
|
2034 |
COMMAND file ~
|
sl@0
|
2035 |
COMMAND RFs1 ~
|
sl@0
|
2036 |
END_TEST_BLOCK
|
sl@0
|
2037 |
END_TESTCASE PBASE-F32-File-PublicApi-0303
|
sl@0
|
2038 |
|
sl@0
|
2039 |
//
|
sl@0
|
2040 |
// TEMP
|
sl@0
|
2041 |
//
|
sl@0
|
2042 |
|
sl@0
|
2043 |
START_TESTCASE PBASE-F32-File-PublicApi-0401
|
sl@0
|
2044 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0401
|
sl@0
|
2045 |
//! @SYMAPI RFile
|
sl@0
|
2046 |
//! @SYMTestCaseDesc Function Temp() neg. test. Try to create temporary file in nonexistant directory.
|
sl@0
|
2047 |
//! Uses API elements: Temp().
|
sl@0
|
2048 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
2049 |
//! 2. Call RFile::Temp passing RFs, literal "{Drives, RAMDriveChar}:\base\chickenfarm\", TDesc&, EFileWrite
|
sl@0
|
2050 |
//! 3. Close RFs.
|
sl@0
|
2051 |
//!
|
sl@0
|
2052 |
//! @SYMTestStatus Implemented
|
sl@0
|
2053 |
//! @SYMTestPriority Critical
|
sl@0
|
2054 |
//! @SYMTestExpectedResults RFile::Temp() KErrPathNotFound on step 2.
|
sl@0
|
2055 |
//!
|
sl@0
|
2056 |
//! @SYMTestType CIT
|
sl@0
|
2057 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2058 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2059 |
CREATE_OBJECT RFile file
|
sl@0
|
2060 |
COMMAND RFs1 new
|
sl@0
|
2061 |
COMMAND RFs1 Connect
|
sl@0
|
2062 |
COMMAND file new
|
sl@0
|
2063 |
COMMAND !Error=-12 file Temp PBASE-F32-File-PublicApi-0401-001-Temp_command005
|
sl@0
|
2064 |
COMMAND file ~
|
sl@0
|
2065 |
COMMAND RFs1 ~
|
sl@0
|
2066 |
END_TEST_BLOCK
|
sl@0
|
2067 |
END_TESTCASE PBASE-F32-File-PublicApi-0401
|
sl@0
|
2068 |
|
sl@0
|
2069 |
|
sl@0
|
2070 |
START_TESTCASE PBASE-F32-File-PublicApi-0403
|
sl@0
|
2071 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0403
|
sl@0
|
2072 |
//! @SYMAPI RFile
|
sl@0
|
2073 |
//! @SYMTestCaseDesc Function Temp() neg. test. Try to create a temporary file with obscure filemodes.
|
sl@0
|
2074 |
//! Uses API elements: Temp().
|
sl@0
|
2075 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
2076 |
//! 2. Call RFile::Temp passing RFs, literal "{Drives, RAMDriveTestPath}file\", TDesc&, EFileShareReadersOnly | EFileWrite
|
sl@0
|
2077 |
//! 3. Close RFs.
|
sl@0
|
2078 |
//!
|
sl@0
|
2079 |
//! @SYMTestStatus Implemented
|
sl@0
|
2080 |
//! @SYMTestPriority Critical
|
sl@0
|
2081 |
//! @SYMTestExpectedResults RFile::Temp() returns KErrArgument on step 2.
|
sl@0
|
2082 |
//!
|
sl@0
|
2083 |
//! @SYMTestType CIT
|
sl@0
|
2084 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2085 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2086 |
CREATE_OBJECT RFile file
|
sl@0
|
2087 |
COMMAND RFs1 new
|
sl@0
|
2088 |
COMMAND RFs1 Connect
|
sl@0
|
2089 |
COMMAND file new
|
sl@0
|
2090 |
COMMAND !Error=-6 file Temp PBASE-F32-File-PublicApi-0403-001-Temp_command005
|
sl@0
|
2091 |
COMMAND file ~
|
sl@0
|
2092 |
COMMAND RFs1 ~
|
sl@0
|
2093 |
END_TEST_BLOCK
|
sl@0
|
2094 |
END_TESTCASE PBASE-F32-File-PublicApi-0403
|
sl@0
|
2095 |
|
sl@0
|
2096 |
|
sl@0
|
2097 |
//
|
sl@0
|
2098 |
// READ3
|
sl@0
|
2099 |
//
|
sl@0
|
2100 |
|
sl@0
|
2101 |
|
sl@0
|
2102 |
START_TESTCASE PBASE-F32-File-PublicApi-0701
|
sl@0
|
2103 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0701
|
sl@0
|
2104 |
//! @SYMAPI RFile
|
sl@0
|
2105 |
//! @SYMTestCaseDesc Synchronous Read() neg. test - try to read negative length.
|
sl@0
|
2106 |
//! Uses API elements: Read().
|
sl@0
|
2107 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
2108 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\0701.txt", EFileWrite
|
sl@0
|
2109 |
//! 3. Write "test" to file
|
sl@0
|
2110 |
//! 4. Reset file position.
|
sl@0
|
2111 |
//! 5. Call RFile::Read() passing TDesC, -1 for the length
|
sl@0
|
2112 |
//! 6. Close RFile.
|
sl@0
|
2113 |
//! 7. Delete file.
|
sl@0
|
2114 |
//! 8. Close RFs.
|
sl@0
|
2115 |
//!
|
sl@0
|
2116 |
//! @SYMTestStatus Implemented
|
sl@0
|
2117 |
//! @SYMTestPriority Critical
|
sl@0
|
2118 |
//! @SYMTestExpectedResults RFile::Read() returns KErrArgument.
|
sl@0
|
2119 |
//!
|
sl@0
|
2120 |
//! @SYMTestType CIT
|
sl@0
|
2121 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2122 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2123 |
CREATE_OBJECT RFile file
|
sl@0
|
2124 |
COMMAND RFs1 new
|
sl@0
|
2125 |
COMMAND RFs1 Connect
|
sl@0
|
2126 |
COMMAND file new
|
sl@0
|
2127 |
COMMAND file Replace PBASE-F32-File-PublicApi-0701-001-Replace_command005
|
sl@0
|
2128 |
COMMAND file Write PBASE-F32-File-PublicApi-0701-001-Write_command006
|
sl@0
|
2129 |
COMMAND !Error=-6 file Read PBASE-F32-File-PublicApi-0701-001-Read_command007
|
sl@0
|
2130 |
COMMAND file Close
|
sl@0
|
2131 |
COMMAND file ~
|
sl@0
|
2132 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0701-001-Delete_command011
|
sl@0
|
2133 |
COMMAND RFs1 ~
|
sl@0
|
2134 |
END_TEST_BLOCK
|
sl@0
|
2135 |
END_TESTCASE PBASE-F32-File-PublicApi-0701
|
sl@0
|
2136 |
|
sl@0
|
2137 |
|
sl@0
|
2138 |
START_TESTCASE PBASE-F32-File-PublicApi-0702
|
sl@0
|
2139 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0702
|
sl@0
|
2140 |
//! @SYMAPI RFile
|
sl@0
|
2141 |
//! @SYMTestCaseDesc Synchronous Read() neg. test - Will open file and try to read more data from it, than the buffer length.
|
sl@0
|
2142 |
//! Uses API elements: Read().
|
sl@0
|
2143 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
2144 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0702.txt", EFileWrite
|
sl@0
|
2145 |
//! 3. Write "readtest" to file
|
sl@0
|
2146 |
//! 4. Reset file position.
|
sl@0
|
2147 |
//! 5. Create buffer descriptor with length 4.
|
sl@0
|
2148 |
//! 5. Call RFile::Read() passing buffer, 1000 for the length.
|
sl@0
|
2149 |
//! 6. Close RFile.
|
sl@0
|
2150 |
//! 7. Delete file.
|
sl@0
|
2151 |
//! 8. Close RFs.
|
sl@0
|
2152 |
//!
|
sl@0
|
2153 |
//! @SYMTestStatus Implemented
|
sl@0
|
2154 |
//! @SYMTestPriority Critical
|
sl@0
|
2155 |
//! @SYMTestExpectedResults RFile::Read() returns an KErrOverlow.
|
sl@0
|
2156 |
//!
|
sl@0
|
2157 |
//! @SYMTestType CIT
|
sl@0
|
2158 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2159 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2160 |
CREATE_OBJECT RFile file
|
sl@0
|
2161 |
COMMAND RFs1 new
|
sl@0
|
2162 |
COMMAND RFs1 Connect
|
sl@0
|
2163 |
COMMAND file new
|
sl@0
|
2164 |
COMMAND file Replace PBASE-F32-File-PublicApi-0702-001-Replace_command005
|
sl@0
|
2165 |
COMMAND file Write PBASE-F32-File-PublicApi-0702-001-Write_command006
|
sl@0
|
2166 |
COMMAND !Error=-9 file Read PBASE-F32-File-PublicApi-0702-001-Read_command007
|
sl@0
|
2167 |
COMMAND file Close
|
sl@0
|
2168 |
COMMAND file ~
|
sl@0
|
2169 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0702-001-Delete_command011
|
sl@0
|
2170 |
COMMAND RFs1 ~
|
sl@0
|
2171 |
END_TEST_BLOCK
|
sl@0
|
2172 |
END_TESTCASE PBASE-F32-File-PublicApi-0702
|
sl@0
|
2173 |
|
sl@0
|
2174 |
|
sl@0
|
2175 |
START_TESTCASE PBASE-F32-File-PublicApi-0703
|
sl@0
|
2176 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0703
|
sl@0
|
2177 |
//! @SYMAPI RFile
|
sl@0
|
2178 |
//! @SYMTestCaseDesc Synchronous Read(TDesC8& aData, TInt length) test. Pass 0 for length
|
sl@0
|
2179 |
//! Uses API elements: Read().
|
sl@0
|
2180 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
2181 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0703.txt", EFileWrite
|
sl@0
|
2182 |
//! 3. Write "readtest" to file
|
sl@0
|
2183 |
//! 4. Reset file position.
|
sl@0
|
2184 |
//! 5. Create buffer descriptor with length 4.
|
sl@0
|
2185 |
//! 5. Call RFile::Read() passing buffer, 0 for the length.
|
sl@0
|
2186 |
//! 6. Close RFile.
|
sl@0
|
2187 |
//! 7. Close RFs.
|
sl@0
|
2188 |
//!
|
sl@0
|
2189 |
//! @SYMTestStatus Implemented
|
sl@0
|
2190 |
//! @SYMTestPriority Critical
|
sl@0
|
2191 |
//! @SYMTestExpectedResults RFile::Read() returns empty descriptor
|
sl@0
|
2192 |
//!
|
sl@0
|
2193 |
//! @SYMTestType CIT
|
sl@0
|
2194 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2195 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2196 |
CREATE_OBJECT RFile file
|
sl@0
|
2197 |
COMMAND RFs1 new
|
sl@0
|
2198 |
COMMAND RFs1 Connect
|
sl@0
|
2199 |
COMMAND file new
|
sl@0
|
2200 |
COMMAND file Replace PBASE-F32-File-PublicApi-0703-001-Replace_command005
|
sl@0
|
2201 |
COMMAND file Write PBASE-F32-File-PublicApi-0703-001-Write_command006
|
sl@0
|
2202 |
COMMAND file Read PBASE-F32-File-PublicApi-0703-001-Read_command007
|
sl@0
|
2203 |
COMMAND file Close
|
sl@0
|
2204 |
COMMAND file ~
|
sl@0
|
2205 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0703-001-Delete_command011
|
sl@0
|
2206 |
COMMAND RFs1 ~
|
sl@0
|
2207 |
END_TEST_BLOCK
|
sl@0
|
2208 |
END_TESTCASE PBASE-F32-File-PublicApi-0703
|
sl@0
|
2209 |
|
sl@0
|
2210 |
|
sl@0
|
2211 |
//
|
sl@0
|
2212 |
// READ4
|
sl@0
|
2213 |
//
|
sl@0
|
2214 |
|
sl@0
|
2215 |
|
sl@0
|
2216 |
START_TESTCASE PBASE-F32-File-PublicApi-0801
|
sl@0
|
2217 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0801
|
sl@0
|
2218 |
//! @SYMAPI RFile
|
sl@0
|
2219 |
//! @SYMTestCaseDesc Asynchronous Read() neg. test - try to read negative length.
|
sl@0
|
2220 |
//! Uses API elements: Read().
|
sl@0
|
2221 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
2222 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0801.txt", EFileWrite
|
sl@0
|
2223 |
//! 3. Write "test" to file
|
sl@0
|
2224 |
//! 4. Reset file position.
|
sl@0
|
2225 |
//! 5. Call RFile::Read() passing TDesC, -1 for the length, TRequestStatus
|
sl@0
|
2226 |
//! 6. wait for request.
|
sl@0
|
2227 |
//! 7. Close RFile.
|
sl@0
|
2228 |
//! 8. Delete file.
|
sl@0
|
2229 |
//! 9. Close RFs.
|
sl@0
|
2230 |
//!
|
sl@0
|
2231 |
//! @SYMTestStatus Implemented
|
sl@0
|
2232 |
//! @SYMTestPriority Critical
|
sl@0
|
2233 |
//! @SYMTestExpectedResults RFile::Read() returns KErrArgument with TRequestStatus.
|
sl@0
|
2234 |
//!
|
sl@0
|
2235 |
//! @SYMTestType CIT
|
sl@0
|
2236 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2237 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2238 |
CREATE_OBJECT RFile file
|
sl@0
|
2239 |
COMMAND RFs1 new
|
sl@0
|
2240 |
COMMAND RFs1 Connect
|
sl@0
|
2241 |
COMMAND file new
|
sl@0
|
2242 |
COMMAND file Replace PBASE-F32-File-PublicApi-0801-001-Replace_command005
|
sl@0
|
2243 |
COMMAND file Write PBASE-F32-File-PublicApi-0801-001-Write_command006
|
sl@0
|
2244 |
COMMAND !AsyncError=-6 file Read PBASE-F32-File-PublicApi-0801-001-Read_command007
|
sl@0
|
2245 |
OUTSTANDING
|
sl@0
|
2246 |
COMMAND file Close
|
sl@0
|
2247 |
COMMAND file ~
|
sl@0
|
2248 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0801-001-Delete_command011
|
sl@0
|
2249 |
COMMAND RFs1 ~
|
sl@0
|
2250 |
END_TEST_BLOCK
|
sl@0
|
2251 |
END_TESTCASE PBASE-F32-File-PublicApi-0801
|
sl@0
|
2252 |
|
sl@0
|
2253 |
|
sl@0
|
2254 |
START_TESTCASE PBASE-F32-File-PublicApi-0802
|
sl@0
|
2255 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0802
|
sl@0
|
2256 |
//! @SYMAPI RFile
|
sl@0
|
2257 |
//! @SYMTestCaseDesc Asynchronous Read() neg. test - Will open file and try to read more data from it, than the buffer length.
|
sl@0
|
2258 |
//! Uses API elements: Read().
|
sl@0
|
2259 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
2260 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0802.txt", EFileWrite
|
sl@0
|
2261 |
//! 3. Write "readtest" to file
|
sl@0
|
2262 |
//! 4. Reset file position.
|
sl@0
|
2263 |
//! 5. Create buffer descriptor with length 4.
|
sl@0
|
2264 |
//! 6. Call RFile::Read() passing buffer, 1000 for the length, TRequestStatus
|
sl@0
|
2265 |
//! 7. Wait for status.
|
sl@0
|
2266 |
//! 8. Close RFile.
|
sl@0
|
2267 |
//! 9. Delete file.
|
sl@0
|
2268 |
//! 10. Close RFs.
|
sl@0
|
2269 |
//!
|
sl@0
|
2270 |
//! @SYMTestStatus Implemented
|
sl@0
|
2271 |
//! @SYMTestPriority Critical
|
sl@0
|
2272 |
//! @SYMTestExpectedResults RFile::Read() returns an KErrOverlow, with TRequestStatus.
|
sl@0
|
2273 |
//!
|
sl@0
|
2274 |
//! @SYMTestType CIT
|
sl@0
|
2275 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2276 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2277 |
CREATE_OBJECT RFile file
|
sl@0
|
2278 |
COMMAND RFs1 new
|
sl@0
|
2279 |
COMMAND RFs1 Connect
|
sl@0
|
2280 |
COMMAND file new
|
sl@0
|
2281 |
COMMAND file Replace PBASE-F32-File-PublicApi-0802-001-Replace_command005
|
sl@0
|
2282 |
COMMAND file Write PBASE-F32-File-PublicApi-0802-001-Write_command006
|
sl@0
|
2283 |
COMMAND !AsyncError=-9 file Read PBASE-F32-File-PublicApi-0802-001-Read_command007
|
sl@0
|
2284 |
OUTSTANDING
|
sl@0
|
2285 |
COMMAND file Close
|
sl@0
|
2286 |
COMMAND file ~
|
sl@0
|
2287 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0802-001-Delete_command011
|
sl@0
|
2288 |
COMMAND RFs1 ~
|
sl@0
|
2289 |
END_TEST_BLOCK
|
sl@0
|
2290 |
END_TESTCASE PBASE-F32-File-PublicApi-0802
|
sl@0
|
2291 |
|
sl@0
|
2292 |
|
sl@0
|
2293 |
//
|
sl@0
|
2294 |
// READ5
|
sl@0
|
2295 |
//
|
sl@0
|
2296 |
|
sl@0
|
2297 |
|
sl@0
|
2298 |
START_TESTCASE PBASE-F32-File-PublicApi-0901
|
sl@0
|
2299 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0901
|
sl@0
|
2300 |
//! @SYMAPI RFile
|
sl@0
|
2301 |
//! @SYMTestCaseDesc Synchronous Read() neg. test - try to read from negative position.
|
sl@0
|
2302 |
//! Uses API elements: Read().
|
sl@0
|
2303 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
2304 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0901.txt", EFileWrite
|
sl@0
|
2305 |
//! 3. Write "test" to file
|
sl@0
|
2306 |
//! 4. Reset file position.
|
sl@0
|
2307 |
//! 5. Call RFile::Read() passing -1 for position.
|
sl@0
|
2308 |
//! 6. Close file.
|
sl@0
|
2309 |
//! 7. Delete file.
|
sl@0
|
2310 |
//! 8. Close file server session.
|
sl@0
|
2311 |
//!
|
sl@0
|
2312 |
//! @SYMTestStatus Implemented
|
sl@0
|
2313 |
//! @SYMTestPriority Critical
|
sl@0
|
2314 |
//! @SYMTestExpectedResults Panic FSCLIENT:19 at step 5.
|
sl@0
|
2315 |
//!
|
sl@0
|
2316 |
//! @SYMTestType CIT
|
sl@0
|
2317 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2318 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2319 |
CREATE_OBJECT RFile file
|
sl@0
|
2320 |
COMMAND RFs1 new
|
sl@0
|
2321 |
COMMAND RFs1 Connect
|
sl@0
|
2322 |
COMMAND file new
|
sl@0
|
2323 |
COMMAND file Replace PBASE-F32-File-PublicApi-0901-001-Replace_command005
|
sl@0
|
2324 |
COMMAND file Write PBASE-F32-File-PublicApi-0901-001-Write_command006
|
sl@0
|
2325 |
COMMAND file Read PBASE-F32-File-PublicApi-0901-001-Read_command007
|
sl@0
|
2326 |
COMMAND file Close
|
sl@0
|
2327 |
COMMAND file ~
|
sl@0
|
2328 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0901-001-Delete_command011
|
sl@0
|
2329 |
COMMAND RFs1 ~
|
sl@0
|
2330 |
END_TEST_BLOCK !PanicCode=19 !PanicString="FSCLIENT panic"
|
sl@0
|
2331 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2332 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2333 |
COMMAND RFs1 new
|
sl@0
|
2334 |
COMMAND RFs1 Connect
|
sl@0
|
2335 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0901-001-Delete_command011
|
sl@0
|
2336 |
COMMAND RFs1 ~
|
sl@0
|
2337 |
END_TEST_BLOCK
|
sl@0
|
2338 |
END_TESTCASE PBASE-F32-File-PublicApi-0901
|
sl@0
|
2339 |
|
sl@0
|
2340 |
|
sl@0
|
2341 |
START_TESTCASE PBASE-F32-File-PublicApi-0902
|
sl@0
|
2342 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-0902
|
sl@0
|
2343 |
//! @SYMAPI RFile
|
sl@0
|
2344 |
//! @SYMTestCaseDesc Synchronous Read() neg. test - try to read beyond file's length.
|
sl@0
|
2345 |
//! Uses API elements: Read().
|
sl@0
|
2346 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
2347 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc0902.txt", EFileWrite
|
sl@0
|
2348 |
//! 3. Write "test" to file
|
sl@0
|
2349 |
//! 4. Reset file position.
|
sl@0
|
2350 |
//! 5. Call RFile::Read() passing 100 for position.
|
sl@0
|
2351 |
//! 6. Close file.
|
sl@0
|
2352 |
//! 7. Delete file.
|
sl@0
|
2353 |
//! 8. Close file server session.
|
sl@0
|
2354 |
//!
|
sl@0
|
2355 |
//! @SYMTestStatus Implemented
|
sl@0
|
2356 |
//! @SYMTestPriority Critical
|
sl@0
|
2357 |
//! @SYMTestExpectedResults RFile::Read(data, position) returns zero length descriptor.
|
sl@0
|
2358 |
//!
|
sl@0
|
2359 |
//! @SYMTestType CIT
|
sl@0
|
2360 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2361 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2362 |
CREATE_OBJECT RFile file
|
sl@0
|
2363 |
COMMAND RFs1 new
|
sl@0
|
2364 |
COMMAND RFs1 Connect
|
sl@0
|
2365 |
COMMAND file new
|
sl@0
|
2366 |
COMMAND file Replace PBASE-F32-File-PublicApi-0902-001-Replace_command005
|
sl@0
|
2367 |
COMMAND file Write PBASE-F32-File-PublicApi-0902-001-Write_command006
|
sl@0
|
2368 |
COMMAND file Read PBASE-F32-File-PublicApi-0902-001-Read_command007
|
sl@0
|
2369 |
COMMAND file Close
|
sl@0
|
2370 |
COMMAND file ~
|
sl@0
|
2371 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-0902-001-Delete_command011
|
sl@0
|
2372 |
COMMAND RFs1 ~
|
sl@0
|
2373 |
END_TEST_BLOCK
|
sl@0
|
2374 |
END_TESTCASE PBASE-F32-File-PublicApi-0902
|
sl@0
|
2375 |
|
sl@0
|
2376 |
|
sl@0
|
2377 |
//
|
sl@0
|
2378 |
// READ6
|
sl@0
|
2379 |
//
|
sl@0
|
2380 |
|
sl@0
|
2381 |
|
sl@0
|
2382 |
START_TESTCASE PBASE-F32-File-PublicApi-1001
|
sl@0
|
2383 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-1001
|
sl@0
|
2384 |
//! @SYMAPI RFile
|
sl@0
|
2385 |
//! @SYMTestCaseDesc Asynchronous Read() neg. test - try to read from negative position.
|
sl@0
|
2386 |
//! Uses API elements: Read().
|
sl@0
|
2387 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
2388 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc1001.txt", EFileWrite
|
sl@0
|
2389 |
//! 3. Write "synchronous read with position test" to file
|
sl@0
|
2390 |
//! 4. Call RFile::Read() passing -1 for position, TRequestStatus.
|
sl@0
|
2391 |
//! 5. close file.
|
sl@0
|
2392 |
//! 6. Delete tc1001.txt
|
sl@0
|
2393 |
//! 7. Close file server session.
|
sl@0
|
2394 |
//!
|
sl@0
|
2395 |
//! @SYMTestStatus Implemented
|
sl@0
|
2396 |
//! @SYMTestPriority Critical
|
sl@0
|
2397 |
//! @SYMTestExpectedResults Panic FSCLIENT:19 at step 5.
|
sl@0
|
2398 |
//!
|
sl@0
|
2399 |
//! @SYMTestType CIT
|
sl@0
|
2400 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2401 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2402 |
CREATE_OBJECT RFile file
|
sl@0
|
2403 |
COMMAND RFs1 new
|
sl@0
|
2404 |
COMMAND RFs1 Connect
|
sl@0
|
2405 |
COMMAND file new
|
sl@0
|
2406 |
COMMAND file Replace PBASE-F32-File-PublicApi-1001-001-Replace_command005
|
sl@0
|
2407 |
COMMAND file Write PBASE-F32-File-PublicApi-1001-001-Write_command006
|
sl@0
|
2408 |
COMMAND file Read PBASE-F32-File-PublicApi-1001-001-Read_command007
|
sl@0
|
2409 |
OUTSTANDING
|
sl@0
|
2410 |
COMMAND file Close
|
sl@0
|
2411 |
COMMAND file ~
|
sl@0
|
2412 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-1001-001-Delete_command011
|
sl@0
|
2413 |
COMMAND RFs1 ~
|
sl@0
|
2414 |
END_TEST_BLOCK !PanicCode=19 !PanicString="FSCLIENT panic"
|
sl@0
|
2415 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2416 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2417 |
COMMAND RFs1 new
|
sl@0
|
2418 |
COMMAND RFs1 Connect
|
sl@0
|
2419 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-1001-001-Delete_command011
|
sl@0
|
2420 |
COMMAND RFs1 ~
|
sl@0
|
2421 |
END_TEST_BLOCK
|
sl@0
|
2422 |
END_TESTCASE PBASE-F32-File-PublicApi-1001
|
sl@0
|
2423 |
|
sl@0
|
2424 |
|
sl@0
|
2425 |
START_TESTCASE PBASE-F32-File-PublicApi-1002
|
sl@0
|
2426 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-1002
|
sl@0
|
2427 |
//! @SYMAPI RFile
|
sl@0
|
2428 |
//! @SYMTestCaseDesc Asynchronous Read() neg. test - try to read beyond files length.
|
sl@0
|
2429 |
//! Uses API elements: Read().
|
sl@0
|
2430 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
2431 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc1002.txt", EFileWrite
|
sl@0
|
2432 |
//! 3. Write "test" to file
|
sl@0
|
2433 |
//! 4. Reset file position.
|
sl@0
|
2434 |
//! 5. Call RFile::Read() passing 100 for position, TRequestStatus.
|
sl@0
|
2435 |
//! 6. close file.
|
sl@0
|
2436 |
//! 7. Delete tc1002.txt
|
sl@0
|
2437 |
//! 8. Close file server session.
|
sl@0
|
2438 |
//!
|
sl@0
|
2439 |
//! @SYMTestStatus Implemented
|
sl@0
|
2440 |
//! @SYMTestPriority Critical
|
sl@0
|
2441 |
//! @SYMTestExpectedResults RFile::Read(data, position, status) returns zero length descriptor.
|
sl@0
|
2442 |
//!
|
sl@0
|
2443 |
//! @SYMTestType CIT
|
sl@0
|
2444 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2445 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2446 |
CREATE_OBJECT RFile file
|
sl@0
|
2447 |
COMMAND RFs1 new
|
sl@0
|
2448 |
COMMAND RFs1 Connect
|
sl@0
|
2449 |
COMMAND file new
|
sl@0
|
2450 |
COMMAND file Replace PBASE-F32-File-PublicApi-1002-001-Replace_command005
|
sl@0
|
2451 |
COMMAND file Write PBASE-F32-File-PublicApi-1002-001-Write_command006
|
sl@0
|
2452 |
COMMAND file Read PBASE-F32-File-PublicApi-1002-001-Read_command007
|
sl@0
|
2453 |
OUTSTANDING
|
sl@0
|
2454 |
COMMAND file Close
|
sl@0
|
2455 |
COMMAND file ~
|
sl@0
|
2456 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-1002-001-Delete_command011
|
sl@0
|
2457 |
COMMAND RFs1 ~
|
sl@0
|
2458 |
END_TEST_BLOCK
|
sl@0
|
2459 |
END_TESTCASE PBASE-F32-File-PublicApi-1002
|
sl@0
|
2460 |
|
sl@0
|
2461 |
//
|
sl@0
|
2462 |
// READ7
|
sl@0
|
2463 |
//
|
sl@0
|
2464 |
|
sl@0
|
2465 |
|
sl@0
|
2466 |
START_TESTCASE PBASE-F32-File-PublicApi-1101
|
sl@0
|
2467 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-1101
|
sl@0
|
2468 |
//! @SYMAPI RFile
|
sl@0
|
2469 |
//! @SYMTestCaseDesc Synchronous Read() neg. test - Will try to read from negative position.
|
sl@0
|
2470 |
//! Uses API elements: Read().
|
sl@0
|
2471 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
2472 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc1101.txt", EFileWrite
|
sl@0
|
2473 |
//! 3. Write "test" to file
|
sl@0
|
2474 |
//! 4. Reset file position.
|
sl@0
|
2475 |
//! 5. Call RFile::Read() passing 4 for length and -1 for position.
|
sl@0
|
2476 |
//!
|
sl@0
|
2477 |
//! @SYMTestStatus Implemented
|
sl@0
|
2478 |
//! @SYMTestPriority Critical
|
sl@0
|
2479 |
//! @SYMTestExpectedResults Panic FSCLIENT:19 at step 5.
|
sl@0
|
2480 |
//!
|
sl@0
|
2481 |
//! @SYMTestType CIT
|
sl@0
|
2482 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2483 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2484 |
CREATE_OBJECT RFile file
|
sl@0
|
2485 |
COMMAND RFs1 new
|
sl@0
|
2486 |
COMMAND RFs1 Connect
|
sl@0
|
2487 |
COMMAND file new
|
sl@0
|
2488 |
COMMAND file Replace PBASE-F32-File-PublicApi-1101-001-Replace_command005
|
sl@0
|
2489 |
COMMAND file Write PBASE-F32-File-PublicApi-1101-001-Write_command006
|
sl@0
|
2490 |
COMMAND file Read PBASE-F32-File-PublicApi-1101-001-Read_command007
|
sl@0
|
2491 |
COMMAND file Close
|
sl@0
|
2492 |
COMMAND file ~
|
sl@0
|
2493 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-1101-001-Delete_command011
|
sl@0
|
2494 |
COMMAND RFs1 ~
|
sl@0
|
2495 |
END_TEST_BLOCK !PanicCode=19 !PanicString="FSCLIENT panic"
|
sl@0
|
2496 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2497 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2498 |
COMMAND RFs1 new
|
sl@0
|
2499 |
COMMAND RFs1 Connect
|
sl@0
|
2500 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-1101-001-Delete_command011
|
sl@0
|
2501 |
COMMAND RFs1 ~
|
sl@0
|
2502 |
END_TEST_BLOCK
|
sl@0
|
2503 |
END_TESTCASE PBASE-F32-File-PublicApi-1101
|
sl@0
|
2504 |
|
sl@0
|
2505 |
|
sl@0
|
2506 |
START_TESTCASE PBASE-F32-File-PublicApi-1102
|
sl@0
|
2507 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-1102
|
sl@0
|
2508 |
//! @SYMAPI RFile
|
sl@0
|
2509 |
//! @SYMTestCaseDesc Synchronous Read() neg. test - will try to read negative length.
|
sl@0
|
2510 |
//! Uses API elements: Read().
|
sl@0
|
2511 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
2512 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc1102.txt", EFileWrite
|
sl@0
|
2513 |
//! 3. Write "test" to file
|
sl@0
|
2514 |
//! 4. Reset file position.
|
sl@0
|
2515 |
//! 5. Call RFile::Read() passing -4 for length and 10 for position.
|
sl@0
|
2516 |
//! 6. Close RFile.
|
sl@0
|
2517 |
//! 7. Delete file.
|
sl@0
|
2518 |
//! 8. Close RFs.
|
sl@0
|
2519 |
//!
|
sl@0
|
2520 |
//! @SYMTestStatus Implemented
|
sl@0
|
2521 |
//! @SYMTestPriority Critical
|
sl@0
|
2522 |
//! @SYMTestExpectedResults RFile::Read() returns KErrArgument.
|
sl@0
|
2523 |
//!
|
sl@0
|
2524 |
//! @SYMTestType CIT
|
sl@0
|
2525 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2526 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2527 |
CREATE_OBJECT RFile file
|
sl@0
|
2528 |
COMMAND RFs1 new
|
sl@0
|
2529 |
COMMAND RFs1 Connect
|
sl@0
|
2530 |
COMMAND file new
|
sl@0
|
2531 |
COMMAND file Replace PBASE-F32-File-PublicApi-1102-001-Replace_command005
|
sl@0
|
2532 |
COMMAND file Write PBASE-F32-File-PublicApi-1102-001-Write_command006
|
sl@0
|
2533 |
COMMAND !Error=-6 file Read PBASE-F32-File-PublicApi-1102-001-Read_command007
|
sl@0
|
2534 |
COMMAND file Close
|
sl@0
|
2535 |
COMMAND file ~
|
sl@0
|
2536 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-1102-001-Delete_command011
|
sl@0
|
2537 |
COMMAND RFs1 ~
|
sl@0
|
2538 |
END_TEST_BLOCK
|
sl@0
|
2539 |
END_TESTCASE PBASE-F32-File-PublicApi-1102
|
sl@0
|
2540 |
|
sl@0
|
2541 |
|
sl@0
|
2542 |
START_TESTCASE PBASE-F32-File-PublicApi-1103
|
sl@0
|
2543 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-1103
|
sl@0
|
2544 |
//! @SYMAPI RFile
|
sl@0
|
2545 |
//! @SYMTestCaseDesc Synchronous Read() neg. test - Will try to read from position beyond file length.
|
sl@0
|
2546 |
//! Uses API elements: Read().
|
sl@0
|
2547 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
2548 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc1103.txt", EFileWrite
|
sl@0
|
2549 |
//! 3. Write "test" to file
|
sl@0
|
2550 |
//! 4. Reset file position.
|
sl@0
|
2551 |
//! 5. Call RFile::Read() passing 4 for length and 10 for position (larger than file's content).
|
sl@0
|
2552 |
//! 6. Close RFile.
|
sl@0
|
2553 |
//! 7. Delete file.
|
sl@0
|
2554 |
//! 8. Close RFs.
|
sl@0
|
2555 |
//!
|
sl@0
|
2556 |
//! @SYMTestStatus Implemented
|
sl@0
|
2557 |
//! @SYMTestPriority Critical
|
sl@0
|
2558 |
//! @SYMTestExpectedResults RFile::Read() returns KErrNone. Length of data read is 0.
|
sl@0
|
2559 |
//!
|
sl@0
|
2560 |
//! @SYMTestType CIT
|
sl@0
|
2561 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2562 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2563 |
CREATE_OBJECT RFile file
|
sl@0
|
2564 |
COMMAND RFs1 new
|
sl@0
|
2565 |
COMMAND RFs1 Connect
|
sl@0
|
2566 |
COMMAND file new
|
sl@0
|
2567 |
COMMAND file Replace PBASE-F32-File-PublicApi-1103-001-Replace_command005
|
sl@0
|
2568 |
COMMAND file Write PBASE-F32-File-PublicApi-1103-001-Write_command006
|
sl@0
|
2569 |
COMMAND file Read PBASE-F32-File-PublicApi-1103-001-Read_command007
|
sl@0
|
2570 |
COMMAND file Close
|
sl@0
|
2571 |
COMMAND file ~
|
sl@0
|
2572 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-1103-001-Delete_command011
|
sl@0
|
2573 |
COMMAND RFs1 ~
|
sl@0
|
2574 |
END_TEST_BLOCK
|
sl@0
|
2575 |
END_TESTCASE PBASE-F32-File-PublicApi-1103
|
sl@0
|
2576 |
|
sl@0
|
2577 |
|
sl@0
|
2578 |
START_TESTCASE PBASE-F32-File-PublicApi-1104
|
sl@0
|
2579 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-1104
|
sl@0
|
2580 |
//! @SYMAPI RFile
|
sl@0
|
2581 |
//! @SYMTestCaseDesc Synchronous Read() neg. test - Read more from file than buffer's length.
|
sl@0
|
2582 |
//! Uses API elements: Read().
|
sl@0
|
2583 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
2584 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc1104.txt", EFileRead
|
sl@0
|
2585 |
//! 3. Write "readtest" to file
|
sl@0
|
2586 |
//! 4. Reset file position.
|
sl@0
|
2587 |
//! 5. Call RFile::Read() passing buffer (with size 4) 1000 for length and 10 for position.
|
sl@0
|
2588 |
//! 6. Close RFile.
|
sl@0
|
2589 |
//! 7. Delete file.
|
sl@0
|
2590 |
//! 8. Close RFs.
|
sl@0
|
2591 |
//!
|
sl@0
|
2592 |
//! @SYMTestStatus Implemented
|
sl@0
|
2593 |
//! @SYMTestPriority Critical
|
sl@0
|
2594 |
//! @SYMTestExpectedResults RFile::Read() returns an KErrOverlow.
|
sl@0
|
2595 |
//!
|
sl@0
|
2596 |
//! @SYMTestType CIT
|
sl@0
|
2597 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2598 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2599 |
CREATE_OBJECT RFile file
|
sl@0
|
2600 |
COMMAND RFs1 new
|
sl@0
|
2601 |
COMMAND RFs1 Connect
|
sl@0
|
2602 |
COMMAND file new
|
sl@0
|
2603 |
COMMAND file Replace PBASE-F32-File-PublicApi-1104-001-Replace_command005
|
sl@0
|
2604 |
COMMAND file Write PBASE-F32-File-PublicApi-1104-001-Write_command006
|
sl@0
|
2605 |
COMMAND !Error=-9 file Read PBASE-F32-File-PublicApi-1104-001-Read_command007
|
sl@0
|
2606 |
COMMAND file Close
|
sl@0
|
2607 |
COMMAND file ~
|
sl@0
|
2608 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-1104-001-Delete_command011
|
sl@0
|
2609 |
COMMAND RFs1 ~
|
sl@0
|
2610 |
END_TEST_BLOCK
|
sl@0
|
2611 |
END_TESTCASE PBASE-F32-File-PublicApi-1104
|
sl@0
|
2612 |
|
sl@0
|
2613 |
|
sl@0
|
2614 |
//
|
sl@0
|
2615 |
// READ8
|
sl@0
|
2616 |
//
|
sl@0
|
2617 |
|
sl@0
|
2618 |
|
sl@0
|
2619 |
START_TESTCASE PBASE-F32-File-PublicApi-1201
|
sl@0
|
2620 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-1201
|
sl@0
|
2621 |
//! @SYMAPI RFile
|
sl@0
|
2622 |
//! @SYMTestCaseDesc Asynchronous Read() neg. test - Will try to read from negative position.
|
sl@0
|
2623 |
//! Uses API elements: Read().
|
sl@0
|
2624 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
2625 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc1201.txt", EFileWrite
|
sl@0
|
2626 |
//! 3. Write "test" to file
|
sl@0
|
2627 |
//! 4. Reset file position.
|
sl@0
|
2628 |
//! 5. Call RFile::Read() passing 4 for length and -1 for position and TRequestStatus.
|
sl@0
|
2629 |
//!
|
sl@0
|
2630 |
//! @SYMTestStatus Implemented
|
sl@0
|
2631 |
//! @SYMTestPriority Critical
|
sl@0
|
2632 |
//! @SYMTestExpectedResults Panic FSCLIENT:19 at step 5.
|
sl@0
|
2633 |
//!
|
sl@0
|
2634 |
//! @SYMTestType CIT
|
sl@0
|
2635 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2636 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2637 |
CREATE_OBJECT RFile file
|
sl@0
|
2638 |
COMMAND RFs1 new
|
sl@0
|
2639 |
COMMAND RFs1 Connect
|
sl@0
|
2640 |
COMMAND file new
|
sl@0
|
2641 |
COMMAND file Replace PBASE-F32-File-PublicApi-1201-001-Replace_command005
|
sl@0
|
2642 |
COMMAND file Write PBASE-F32-File-PublicApi-1201-001-Write_command006
|
sl@0
|
2643 |
COMMAND file Read PBASE-F32-File-PublicApi-1201-001-Read_command007
|
sl@0
|
2644 |
OUTSTANDING
|
sl@0
|
2645 |
COMMAND file Close
|
sl@0
|
2646 |
COMMAND file ~
|
sl@0
|
2647 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-1201-001-Delete_command011
|
sl@0
|
2648 |
COMMAND RFs1 ~
|
sl@0
|
2649 |
END_TEST_BLOCK !PanicCode=19 !PanicString="FSCLIENT panic"
|
sl@0
|
2650 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2651 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2652 |
COMMAND RFs1 new
|
sl@0
|
2653 |
COMMAND RFs1 Connect
|
sl@0
|
2654 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-1201-001-Delete_command011
|
sl@0
|
2655 |
COMMAND RFs1 ~
|
sl@0
|
2656 |
END_TEST_BLOCK
|
sl@0
|
2657 |
END_TESTCASE PBASE-F32-File-PublicApi-1201
|
sl@0
|
2658 |
|
sl@0
|
2659 |
|
sl@0
|
2660 |
START_TESTCASE PBASE-F32-File-PublicApi-1202
|
sl@0
|
2661 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-1202
|
sl@0
|
2662 |
//! @SYMAPI RFile
|
sl@0
|
2663 |
//! @SYMTestCaseDesc Asynchronous Read() neg. test - will try to read negative length.
|
sl@0
|
2664 |
//! Uses API elements: Read().
|
sl@0
|
2665 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
2666 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc1202.txt", EFileWrite
|
sl@0
|
2667 |
//! 3. Write "test" to file
|
sl@0
|
2668 |
//! 4. Reset file position.
|
sl@0
|
2669 |
//! 5. Call RFile::Read() passing -4 for length and 10 for position and TRequestStatus.
|
sl@0
|
2670 |
//! 6. wait for request to complete
|
sl@0
|
2671 |
//! 7. Close RFile.
|
sl@0
|
2672 |
//! 8. Delete file.
|
sl@0
|
2673 |
//! 9. Close RFs.
|
sl@0
|
2674 |
//!
|
sl@0
|
2675 |
//! @SYMTestStatus Implemented
|
sl@0
|
2676 |
//! @SYMTestPriority Critical
|
sl@0
|
2677 |
//! @SYMTestExpectedResults RFile::Read() returns KErrArgument.
|
sl@0
|
2678 |
//!
|
sl@0
|
2679 |
//! @SYMTestType CIT
|
sl@0
|
2680 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2681 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2682 |
CREATE_OBJECT RFile file
|
sl@0
|
2683 |
COMMAND RFs1 new
|
sl@0
|
2684 |
COMMAND RFs1 Connect
|
sl@0
|
2685 |
COMMAND file new
|
sl@0
|
2686 |
COMMAND file Replace PBASE-F32-File-PublicApi-1202-001-Replace_command005
|
sl@0
|
2687 |
COMMAND file Write PBASE-F32-File-PublicApi-1202-001-Write_command006
|
sl@0
|
2688 |
COMMAND !AsyncError=-6 file Read PBASE-F32-File-PublicApi-1202-001-Read_command007
|
sl@0
|
2689 |
OUTSTANDING
|
sl@0
|
2690 |
COMMAND file Close
|
sl@0
|
2691 |
COMMAND file ~
|
sl@0
|
2692 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-1202-001-Delete_command011
|
sl@0
|
2693 |
COMMAND RFs1 ~
|
sl@0
|
2694 |
END_TEST_BLOCK
|
sl@0
|
2695 |
END_TESTCASE PBASE-F32-File-PublicApi-1202
|
sl@0
|
2696 |
|
sl@0
|
2697 |
|
sl@0
|
2698 |
START_TESTCASE PBASE-F32-File-PublicApi-1203
|
sl@0
|
2699 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-1203
|
sl@0
|
2700 |
//! @SYMAPI RFile
|
sl@0
|
2701 |
//! @SYMTestCaseDesc Asynchronous Read() neg. test - Will try to read from position beyond file length.
|
sl@0
|
2702 |
//! Uses API elements: Read().
|
sl@0
|
2703 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
2704 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc1203.txt", EFileWrite
|
sl@0
|
2705 |
//! 3. Write "test" to file
|
sl@0
|
2706 |
//! 4. Reset file position.
|
sl@0
|
2707 |
//! 5. Call RFile::Read(), 4 for length, 10 for position.
|
sl@0
|
2708 |
//! 6. Wait for request to complete.
|
sl@0
|
2709 |
//! 7. Close RFile.
|
sl@0
|
2710 |
//! 8. Delete file.
|
sl@0
|
2711 |
//! 9. Close RFs.
|
sl@0
|
2712 |
//!
|
sl@0
|
2713 |
//! @SYMTestStatus Implemented
|
sl@0
|
2714 |
//! @SYMTestPriority Critical
|
sl@0
|
2715 |
//! @SYMTestExpectedResults RFile::Read() returns KErrNone. Length of data read is 0.
|
sl@0
|
2716 |
//!
|
sl@0
|
2717 |
//! @SYMTestType CIT
|
sl@0
|
2718 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2719 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2720 |
CREATE_OBJECT RFile file
|
sl@0
|
2721 |
COMMAND RFs1 new
|
sl@0
|
2722 |
COMMAND RFs1 Connect
|
sl@0
|
2723 |
COMMAND file new
|
sl@0
|
2724 |
COMMAND file Replace PBASE-F32-File-PublicApi-1203-001-Replace_command005
|
sl@0
|
2725 |
COMMAND file Write PBASE-F32-File-PublicApi-1203-001-Write_command006
|
sl@0
|
2726 |
COMMAND file Read PBASE-F32-File-PublicApi-1203-001-Read_command007
|
sl@0
|
2727 |
OUTSTANDING
|
sl@0
|
2728 |
COMMAND file Close
|
sl@0
|
2729 |
COMMAND file ~
|
sl@0
|
2730 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-1203-001-Delete_command011
|
sl@0
|
2731 |
COMMAND RFs1 ~
|
sl@0
|
2732 |
END_TEST_BLOCK
|
sl@0
|
2733 |
END_TESTCASE PBASE-F32-File-PublicApi-1203
|
sl@0
|
2734 |
|
sl@0
|
2735 |
|
sl@0
|
2736 |
START_TESTCASE PBASE-F32-File-PublicApi-1204
|
sl@0
|
2737 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-1204
|
sl@0
|
2738 |
//! @SYMAPI RFile
|
sl@0
|
2739 |
//! @SYMTestCaseDesc Synchronous Read() neg. test - Read more from file than buffer's length.
|
sl@0
|
2740 |
//! Uses API elements: Read().
|
sl@0
|
2741 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
2742 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc1204.txt", EFileWrite
|
sl@0
|
2743 |
//! 3. Write "synchronous read with length and position test" to file
|
sl@0
|
2744 |
//! 4. Reset file position.
|
sl@0
|
2745 |
//! 5. Call RFile::Read() passing buffer (buffer size 4) 1000 for length and for position 10, TRequestStatus.
|
sl@0
|
2746 |
//! 6. Wait for request.
|
sl@0
|
2747 |
//! 7. Close RFile.
|
sl@0
|
2748 |
//! 8. Delete file.
|
sl@0
|
2749 |
//! 9. Close RFs.
|
sl@0
|
2750 |
//!
|
sl@0
|
2751 |
//! @SYMTestStatus Implemented
|
sl@0
|
2752 |
//! @SYMTestPriority Critical
|
sl@0
|
2753 |
//! @SYMTestExpectedResults RFile::Read() returns an KErrOverlow.
|
sl@0
|
2754 |
//!
|
sl@0
|
2755 |
//! @SYMTestType CIT
|
sl@0
|
2756 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2757 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2758 |
CREATE_OBJECT RFile file
|
sl@0
|
2759 |
COMMAND RFs1 new
|
sl@0
|
2760 |
COMMAND RFs1 Connect
|
sl@0
|
2761 |
COMMAND file new
|
sl@0
|
2762 |
COMMAND file Replace PBASE-F32-File-PublicApi-1204-001-Replace_command005
|
sl@0
|
2763 |
COMMAND file Write PBASE-F32-File-PublicApi-1204-001-Write_command006
|
sl@0
|
2764 |
COMMAND !AsyncError=-9 file Read PBASE-F32-File-PublicApi-1204-001-Read_command007
|
sl@0
|
2765 |
OUTSTANDING
|
sl@0
|
2766 |
COMMAND file Close
|
sl@0
|
2767 |
COMMAND file ~
|
sl@0
|
2768 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-1204-001-Delete_command011
|
sl@0
|
2769 |
COMMAND RFs1 ~
|
sl@0
|
2770 |
END_TEST_BLOCK
|
sl@0
|
2771 |
END_TESTCASE PBASE-F32-File-PublicApi-1204
|
sl@0
|
2772 |
|
sl@0
|
2773 |
//
|
sl@0
|
2774 |
// Write
|
sl@0
|
2775 |
//
|
sl@0
|
2776 |
|
sl@0
|
2777 |
START_TESTCASE PBASE-F32-File-PublicApi-1301
|
sl@0
|
2778 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-1301
|
sl@0
|
2779 |
//! @SYMAPI RFile
|
sl@0
|
2780 |
//! @SYMTestCaseDesc Function Write(const TDesC8 &aDes) test - write an emptry buffer to file.
|
sl@0
|
2781 |
//!
|
sl@0
|
2782 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
2783 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc1301.txt", EFileWrite.
|
sl@0
|
2784 |
//! 3. Call Write, passing "" and descriptor with length 0.
|
sl@0
|
2785 |
//! 4. Close file
|
sl@0
|
2786 |
//! 5. Close RFile.
|
sl@0
|
2787 |
//! 6. Delete file
|
sl@0
|
2788 |
//! 7. Close RFs.
|
sl@0
|
2789 |
//!
|
sl@0
|
2790 |
//! @SYMTestStatus Implemented
|
sl@0
|
2791 |
//! @SYMTestPriority Critical
|
sl@0
|
2792 |
//! @SYMTestExpectedResults No panic is raised, or error returned.
|
sl@0
|
2793 |
//!
|
sl@0
|
2794 |
//! @SYMTestType CIT
|
sl@0
|
2795 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2796 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2797 |
CREATE_OBJECT RFile file
|
sl@0
|
2798 |
COMMAND RFs1 new
|
sl@0
|
2799 |
COMMAND RFs1 Connect
|
sl@0
|
2800 |
COMMAND file new
|
sl@0
|
2801 |
COMMAND file Replace PBASE-F32-File-PublicApi-1301-001-Replace_command005
|
sl@0
|
2802 |
COMMAND file Write PBASE-F32-File-PublicApi-1301-001-Write_command006
|
sl@0
|
2803 |
COMMAND file Close
|
sl@0
|
2804 |
COMMAND file ~
|
sl@0
|
2805 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-1301-001-Delete_command010
|
sl@0
|
2806 |
COMMAND RFs1 ~
|
sl@0
|
2807 |
END_TEST_BLOCK
|
sl@0
|
2808 |
END_TESTCASE PBASE-F32-File-PublicApi-1301
|
sl@0
|
2809 |
|
sl@0
|
2810 |
//
|
sl@0
|
2811 |
// Write2
|
sl@0
|
2812 |
//
|
sl@0
|
2813 |
|
sl@0
|
2814 |
START_TESTCASE PBASE-F32-File-PublicApi-1401
|
sl@0
|
2815 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-1401
|
sl@0
|
2816 |
//! @SYMAPI RFile
|
sl@0
|
2817 |
//! @SYMTestCaseDesc Function WWrite(const TDesC8 &aDes, TRequestStatus &aStatus) test - write an emptry buffer to file.
|
sl@0
|
2818 |
//!
|
sl@0
|
2819 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
2820 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc.txt", EFileWrite.
|
sl@0
|
2821 |
//! 3. Call Write, passing "" and descriptor with length 0.
|
sl@0
|
2822 |
//! 4. Close file
|
sl@0
|
2823 |
//! 5. Close RFile.
|
sl@0
|
2824 |
//! 6. Delete file
|
sl@0
|
2825 |
//! 7. Close RFs.
|
sl@0
|
2826 |
//!
|
sl@0
|
2827 |
//! @SYMTestStatus Implemented
|
sl@0
|
2828 |
//! @SYMTestPriority Critical
|
sl@0
|
2829 |
//! @SYMTestExpectedResults No panic is raised, or error returned.
|
sl@0
|
2830 |
//!
|
sl@0
|
2831 |
//! @SYMTestType CIT
|
sl@0
|
2832 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2833 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2834 |
CREATE_OBJECT RFile file
|
sl@0
|
2835 |
COMMAND RFs1 new
|
sl@0
|
2836 |
COMMAND RFs1 Connect
|
sl@0
|
2837 |
COMMAND file new
|
sl@0
|
2838 |
COMMAND file Replace PBASE-F32-File-PublicApi-1401-001-Replace_command005
|
sl@0
|
2839 |
COMMAND file Write PBASE-F32-File-PublicApi-1401-001-Write_command006
|
sl@0
|
2840 |
OUTSTANDING
|
sl@0
|
2841 |
COMMAND file Close
|
sl@0
|
2842 |
COMMAND file ~
|
sl@0
|
2843 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-1401-001-Delete_command010
|
sl@0
|
2844 |
COMMAND RFs1 ~
|
sl@0
|
2845 |
END_TEST_BLOCK
|
sl@0
|
2846 |
END_TESTCASE PBASE-F32-File-PublicApi-1401
|
sl@0
|
2847 |
|
sl@0
|
2848 |
|
sl@0
|
2849 |
//
|
sl@0
|
2850 |
// Write3
|
sl@0
|
2851 |
//
|
sl@0
|
2852 |
|
sl@0
|
2853 |
|
sl@0
|
2854 |
START_TESTCASE PBASE-F32-File-PublicApi-1602
|
sl@0
|
2855 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-1602
|
sl@0
|
2856 |
//! @SYMAPI RFile
|
sl@0
|
2857 |
//! @SYMTestCaseDesc Function write neg. test - pass negative number for length.
|
sl@0
|
2858 |
//!
|
sl@0
|
2859 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
2860 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc1602.txt", EFileWrite.
|
sl@0
|
2861 |
//! 3. Call Write, pass message "short data" and -1 length.
|
sl@0
|
2862 |
//! 4. Close file
|
sl@0
|
2863 |
//! 5. Close RFile.
|
sl@0
|
2864 |
//! 6. Delete file
|
sl@0
|
2865 |
//! 7. Close RFs.
|
sl@0
|
2866 |
//!
|
sl@0
|
2867 |
//! @SYMTestStatus Implemented
|
sl@0
|
2868 |
//! @SYMTestPriority Critical
|
sl@0
|
2869 |
//! @SYMTestExpectedResults Write() returns KErrArgument.
|
sl@0
|
2870 |
//!
|
sl@0
|
2871 |
//! @SYMTestType CIT
|
sl@0
|
2872 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2873 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2874 |
CREATE_OBJECT RFile file
|
sl@0
|
2875 |
COMMAND RFs1 new
|
sl@0
|
2876 |
COMMAND RFs1 Connect
|
sl@0
|
2877 |
COMMAND file new
|
sl@0
|
2878 |
COMMAND file Replace PBASE-F32-File-PublicApi-1602-001-Replace_command005
|
sl@0
|
2879 |
COMMAND !Error=-6 file Write PBASE-F32-File-PublicApi-1602-001-Write_command006
|
sl@0
|
2880 |
COMMAND file Close
|
sl@0
|
2881 |
COMMAND file ~
|
sl@0
|
2882 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-1602-001-Delete_command010
|
sl@0
|
2883 |
COMMAND RFs1 ~
|
sl@0
|
2884 |
END_TEST_BLOCK
|
sl@0
|
2885 |
END_TESTCASE PBASE-F32-File-PublicApi-1602
|
sl@0
|
2886 |
|
sl@0
|
2887 |
|
sl@0
|
2888 |
START_TESTCASE PBASE-F32-File-PublicApi-1603
|
sl@0
|
2889 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-1603
|
sl@0
|
2890 |
//! @SYMAPI RFile
|
sl@0
|
2891 |
//! @SYMTestCaseDesc Function write neg. test - pass 0 number for length.
|
sl@0
|
2892 |
//!
|
sl@0
|
2893 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
2894 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc1603.txt", EFileWrite.
|
sl@0
|
2895 |
//! 3. Call Write, pass message "short data" and 0.
|
sl@0
|
2896 |
//! 4. Close file
|
sl@0
|
2897 |
//! 5. Close RFile.
|
sl@0
|
2898 |
//! 6. Delete file.
|
sl@0
|
2899 |
//! 7. Close RFs.
|
sl@0
|
2900 |
//!
|
sl@0
|
2901 |
//! @SYMTestStatus Implemented
|
sl@0
|
2902 |
//! @SYMTestPriority Critical
|
sl@0
|
2903 |
//! @SYMTestExpectedResults Write() returns KErrNone.
|
sl@0
|
2904 |
//!
|
sl@0
|
2905 |
//! @SYMTestType CIT
|
sl@0
|
2906 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2907 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2908 |
CREATE_OBJECT RFile file
|
sl@0
|
2909 |
COMMAND RFs1 new
|
sl@0
|
2910 |
COMMAND RFs1 Connect
|
sl@0
|
2911 |
COMMAND file new
|
sl@0
|
2912 |
COMMAND file Replace PBASE-F32-File-PublicApi-1603-001-Replace_command005
|
sl@0
|
2913 |
COMMAND file Write PBASE-F32-File-PublicApi-1603-001-Write_command006
|
sl@0
|
2914 |
COMMAND file Close
|
sl@0
|
2915 |
COMMAND file ~
|
sl@0
|
2916 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-1603-001-Delete_command010
|
sl@0
|
2917 |
COMMAND RFs1 ~
|
sl@0
|
2918 |
END_TEST_BLOCK
|
sl@0
|
2919 |
END_TESTCASE PBASE-F32-File-PublicApi-1603
|
sl@0
|
2920 |
|
sl@0
|
2921 |
|
sl@0
|
2922 |
//
|
sl@0
|
2923 |
// Write4
|
sl@0
|
2924 |
//
|
sl@0
|
2925 |
|
sl@0
|
2926 |
START_TESTCASE PBASE-F32-File-PublicApi-1701
|
sl@0
|
2927 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-1701
|
sl@0
|
2928 |
//! @SYMAPI RFile
|
sl@0
|
2929 |
//! @SYMTestCaseDesc Asynchronous function write neg. test - pass negative number for length.
|
sl@0
|
2930 |
//!
|
sl@0
|
2931 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
2932 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc1701.txt", EFileWrite.
|
sl@0
|
2933 |
//! 3. Call Write passing literal "test", -1 for length and TRequestStatus.
|
sl@0
|
2934 |
//! 4. Close RFile.
|
sl@0
|
2935 |
//! 5. Delete file.
|
sl@0
|
2936 |
//! 6. Close RFs.
|
sl@0
|
2937 |
//!
|
sl@0
|
2938 |
//! @SYMTestStatus Implemented
|
sl@0
|
2939 |
//! @SYMTestPriority Critical
|
sl@0
|
2940 |
//! @SYMTestExpectedResults Write() returns KErrArgument.
|
sl@0
|
2941 |
//!
|
sl@0
|
2942 |
//! @SYMTestType CIT
|
sl@0
|
2943 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2944 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2945 |
CREATE_OBJECT RFile file
|
sl@0
|
2946 |
COMMAND RFs1 new
|
sl@0
|
2947 |
COMMAND RFs1 Connect
|
sl@0
|
2948 |
COMMAND file new
|
sl@0
|
2949 |
COMMAND file Replace PBASE-F32-File-PublicApi-1701-001-Replace_command005
|
sl@0
|
2950 |
COMMAND !AsyncError=-6 file Write PBASE-F32-File-PublicApi-1701-001-Write_command006
|
sl@0
|
2951 |
OUTSTANDING
|
sl@0
|
2952 |
COMMAND file Close
|
sl@0
|
2953 |
COMMAND file ~
|
sl@0
|
2954 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-1701-001-Delete_command010
|
sl@0
|
2955 |
COMMAND RFs1 ~
|
sl@0
|
2956 |
END_TEST_BLOCK
|
sl@0
|
2957 |
END_TESTCASE PBASE-F32-File-PublicApi-1701
|
sl@0
|
2958 |
|
sl@0
|
2959 |
START_TESTCASE PBASE-F32-File-PublicApi-1702
|
sl@0
|
2960 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-1702
|
sl@0
|
2961 |
//! @SYMAPI RFile
|
sl@0
|
2962 |
//! @SYMTestCaseDesc Asynchronous function write test - pass 0 for length.
|
sl@0
|
2963 |
//!
|
sl@0
|
2964 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
2965 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc1702.txt", EFileWrite.
|
sl@0
|
2966 |
//! 3. Call Write passing literal "test", 0 for length and TRequestStatus.
|
sl@0
|
2967 |
//! 4. Close RFile.
|
sl@0
|
2968 |
//! 5. Delete file.
|
sl@0
|
2969 |
//! 6. Close RFs.
|
sl@0
|
2970 |
//!
|
sl@0
|
2971 |
//! @SYMTestStatus Implemented
|
sl@0
|
2972 |
//! @SYMTestPriority Critical
|
sl@0
|
2973 |
//! @SYMTestExpectedResults No panics raised or errors returned.
|
sl@0
|
2974 |
//!
|
sl@0
|
2975 |
//! @SYMTestType CIT
|
sl@0
|
2976 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
2977 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
2978 |
CREATE_OBJECT RFile file
|
sl@0
|
2979 |
COMMAND RFs1 new
|
sl@0
|
2980 |
COMMAND RFs1 Connect
|
sl@0
|
2981 |
COMMAND file new
|
sl@0
|
2982 |
COMMAND file Replace PBASE-F32-File-PublicApi-1702-001-Replace_command005
|
sl@0
|
2983 |
COMMAND file Write PBASE-F32-File-PublicApi-1702-001-Write_command006
|
sl@0
|
2984 |
OUTSTANDING
|
sl@0
|
2985 |
COMMAND file Close
|
sl@0
|
2986 |
COMMAND file ~
|
sl@0
|
2987 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-1702-001-Delete_command010
|
sl@0
|
2988 |
COMMAND RFs1 ~
|
sl@0
|
2989 |
END_TEST_BLOCK
|
sl@0
|
2990 |
END_TESTCASE PBASE-F32-File-PublicApi-1702
|
sl@0
|
2991 |
|
sl@0
|
2992 |
|
sl@0
|
2993 |
//
|
sl@0
|
2994 |
// Write5
|
sl@0
|
2995 |
//
|
sl@0
|
2996 |
|
sl@0
|
2997 |
|
sl@0
|
2998 |
START_TESTCASE PBASE-F32-File-PublicApi-1801
|
sl@0
|
2999 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-1801
|
sl@0
|
3000 |
//! @SYMAPI RFile
|
sl@0
|
3001 |
//! @SYMTestCaseDesc Function write neg. test. Write to negative position.
|
sl@0
|
3002 |
//! Uses API elements:.
|
sl@0
|
3003 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
3004 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc1801.txt", EFileWrite.
|
sl@0
|
3005 |
//! 3. Call Write passing "test" and -1 for position.
|
sl@0
|
3006 |
//!
|
sl@0
|
3007 |
//!
|
sl@0
|
3008 |
//! @SYMTestStatus Implemented
|
sl@0
|
3009 |
//! @SYMTestPriority Critical
|
sl@0
|
3010 |
//! @SYMTestExpectedResults Panic FSCLIENT:19.
|
sl@0
|
3011 |
//!
|
sl@0
|
3012 |
//! @SYMTestType CIT
|
sl@0
|
3013 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3014 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3015 |
CREATE_OBJECT RFile file
|
sl@0
|
3016 |
COMMAND RFs1 new
|
sl@0
|
3017 |
COMMAND RFs1 Connect
|
sl@0
|
3018 |
COMMAND file new
|
sl@0
|
3019 |
COMMAND file Replace PBASE-F32-File-PublicApi-1801-001-Replace_command005
|
sl@0
|
3020 |
COMMAND file Write PBASE-F32-File-PublicApi-1801-001-Write_command006
|
sl@0
|
3021 |
COMMAND file Close
|
sl@0
|
3022 |
COMMAND file ~
|
sl@0
|
3023 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-1801-001-Delete_command010
|
sl@0
|
3024 |
COMMAND RFs1 ~
|
sl@0
|
3025 |
END_TEST_BLOCK !PanicCode=19 !PanicString="FSCLIENT panic"
|
sl@0
|
3026 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3027 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3028 |
COMMAND RFs1 new
|
sl@0
|
3029 |
COMMAND RFs1 Connect
|
sl@0
|
3030 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-1801-001-Delete_command010
|
sl@0
|
3031 |
COMMAND RFs1 ~
|
sl@0
|
3032 |
END_TEST_BLOCK
|
sl@0
|
3033 |
END_TESTCASE PBASE-F32-File-PublicApi-1801
|
sl@0
|
3034 |
|
sl@0
|
3035 |
|
sl@0
|
3036 |
START_TESTCASE PBASE-F32-File-PublicApi-1802
|
sl@0
|
3037 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-1802
|
sl@0
|
3038 |
//! @SYMAPI RFile
|
sl@0
|
3039 |
//! @SYMTestCaseDesc Synchronous function write test. Pass a 0 length descriptor to RFile::Write().
|
sl@0
|
3040 |
//! Uses API elements: void Write(TInt aPos, const TDesC8 &aDes, TRequestStatus &aStatus).
|
sl@0
|
3041 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
3042 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc1802.txt", EFileWrite.
|
sl@0
|
3043 |
//! 3. Call Write passing "" and 1 for position.
|
sl@0
|
3044 |
//!
|
sl@0
|
3045 |
//!
|
sl@0
|
3046 |
//! @SYMTestStatus Implemented
|
sl@0
|
3047 |
//! @SYMTestPriority Critical
|
sl@0
|
3048 |
//! @SYMTestExpectedResults No error is returned or panic raised.
|
sl@0
|
3049 |
//!
|
sl@0
|
3050 |
//! @SYMTestType CIT
|
sl@0
|
3051 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3052 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3053 |
CREATE_OBJECT RFile file
|
sl@0
|
3054 |
COMMAND RFs1 new
|
sl@0
|
3055 |
COMMAND RFs1 Connect
|
sl@0
|
3056 |
COMMAND file new
|
sl@0
|
3057 |
COMMAND file Replace PBASE-F32-File-PublicApi-1802-001-Replace_command005
|
sl@0
|
3058 |
COMMAND file Write PBASE-F32-File-PublicApi-1802-001-Write_command006
|
sl@0
|
3059 |
COMMAND file Close
|
sl@0
|
3060 |
COMMAND file ~
|
sl@0
|
3061 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-1802-001-Delete_command010
|
sl@0
|
3062 |
COMMAND RFs1 ~
|
sl@0
|
3063 |
END_TEST_BLOCK
|
sl@0
|
3064 |
END_TESTCASE PBASE-F32-File-PublicApi-1802
|
sl@0
|
3065 |
|
sl@0
|
3066 |
|
sl@0
|
3067 |
//
|
sl@0
|
3068 |
// Write6
|
sl@0
|
3069 |
//
|
sl@0
|
3070 |
|
sl@0
|
3071 |
|
sl@0
|
3072 |
START_TESTCASE PBASE-F32-File-PublicApi-1901
|
sl@0
|
3073 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-1901
|
sl@0
|
3074 |
//! @SYMAPI RFile
|
sl@0
|
3075 |
//! @SYMTestCaseDesc Asynchronous function write neg. test. Pass a negative number for position to RFile::Write().
|
sl@0
|
3076 |
//! Uses API elements: void Write(TInt aPos, const TDesC8 &aDes, TRequestStatus &aStatus).
|
sl@0
|
3077 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
3078 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc1901.txt", EFileWrite.
|
sl@0
|
3079 |
//! 3. Call Write passing "test" and -1 for position.
|
sl@0
|
3080 |
//!
|
sl@0
|
3081 |
//!
|
sl@0
|
3082 |
//! @SYMTestStatus Implemented
|
sl@0
|
3083 |
//! @SYMTestPriority Critical
|
sl@0
|
3084 |
//! @SYMTestExpectedResults Panic FSCLIENT:19.
|
sl@0
|
3085 |
//!
|
sl@0
|
3086 |
//! @SYMTestType CIT
|
sl@0
|
3087 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3088 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3089 |
CREATE_OBJECT RFile file
|
sl@0
|
3090 |
COMMAND RFs1 new
|
sl@0
|
3091 |
COMMAND RFs1 Connect
|
sl@0
|
3092 |
COMMAND file new
|
sl@0
|
3093 |
COMMAND file Replace PBASE-F32-File-PublicApi-1901-001-Replace_command005
|
sl@0
|
3094 |
COMMAND file Write PBASE-F32-File-PublicApi-1901-001-Write_command006
|
sl@0
|
3095 |
OUTSTANDING
|
sl@0
|
3096 |
COMMAND file Close
|
sl@0
|
3097 |
COMMAND file ~
|
sl@0
|
3098 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-1901-001-Delete_command010
|
sl@0
|
3099 |
COMMAND RFs1 ~
|
sl@0
|
3100 |
END_TEST_BLOCK !PanicCode=19 !PanicString="FSCLIENT panic"
|
sl@0
|
3101 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3102 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3103 |
COMMAND RFs1 new
|
sl@0
|
3104 |
COMMAND RFs1 Connect
|
sl@0
|
3105 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-1901-001-Delete_command010
|
sl@0
|
3106 |
COMMAND RFs1 ~
|
sl@0
|
3107 |
END_TEST_BLOCK
|
sl@0
|
3108 |
END_TESTCASE PBASE-F32-File-PublicApi-1901
|
sl@0
|
3109 |
|
sl@0
|
3110 |
|
sl@0
|
3111 |
START_TESTCASE PBASE-F32-File-PublicApi-1902
|
sl@0
|
3112 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-1902
|
sl@0
|
3113 |
//! @SYMAPI RFile
|
sl@0
|
3114 |
//! @SYMTestCaseDesc Asynchronous function write test. Pass a 0 length descriptor to RFile::Write().
|
sl@0
|
3115 |
//! Uses API elements: void Write(TInt aPos, const TDesC8 &aDes, TRequestStatus &aStatus).
|
sl@0
|
3116 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
3117 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc1902.txt", EFileWrite.
|
sl@0
|
3118 |
//! 3. Call Write passing descriptor with length 0 and 1 for position.
|
sl@0
|
3119 |
//!
|
sl@0
|
3120 |
//!
|
sl@0
|
3121 |
//! @SYMTestStatus Implemented
|
sl@0
|
3122 |
//! @SYMTestPriority Critical
|
sl@0
|
3123 |
//! @SYMTestExpectedResults No error is returned or panic raised.
|
sl@0
|
3124 |
//!
|
sl@0
|
3125 |
//! @SYMTestType CIT
|
sl@0
|
3126 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3127 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3128 |
CREATE_OBJECT RFile file
|
sl@0
|
3129 |
COMMAND RFs1 new
|
sl@0
|
3130 |
COMMAND RFs1 Connect
|
sl@0
|
3131 |
COMMAND file new
|
sl@0
|
3132 |
COMMAND file Replace PBASE-F32-File-PublicApi-1902-001-Replace_command005
|
sl@0
|
3133 |
COMMAND file Write PBASE-F32-File-PublicApi-1902-001-Write_command006
|
sl@0
|
3134 |
OUTSTANDING
|
sl@0
|
3135 |
COMMAND file Close
|
sl@0
|
3136 |
COMMAND file ~
|
sl@0
|
3137 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-1902-001-Delete_command010
|
sl@0
|
3138 |
COMMAND RFs1 ~
|
sl@0
|
3139 |
END_TEST_BLOCK
|
sl@0
|
3140 |
END_TESTCASE PBASE-F32-File-PublicApi-1902
|
sl@0
|
3141 |
|
sl@0
|
3142 |
|
sl@0
|
3143 |
//
|
sl@0
|
3144 |
// Write7
|
sl@0
|
3145 |
//
|
sl@0
|
3146 |
|
sl@0
|
3147 |
|
sl@0
|
3148 |
START_TESTCASE PBASE-F32-File-PublicApi-2001
|
sl@0
|
3149 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-2001
|
sl@0
|
3150 |
//! @SYMAPI RFile
|
sl@0
|
3151 |
//! @SYMTestCaseDesc Function Write(TInt aPos, const TDesC8 &aDes, TInt aLength) neg. test. Pass a negative position and negative length.
|
sl@0
|
3152 |
//! Uses API elements: Write().
|
sl@0
|
3153 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
3154 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc2001.txt", EFileWrite.
|
sl@0
|
3155 |
//! 3. call write, pass "test", -1 for length, -1 for position.
|
sl@0
|
3156 |
//!
|
sl@0
|
3157 |
//!
|
sl@0
|
3158 |
//! @SYMTestStatus Implemented
|
sl@0
|
3159 |
//! @SYMTestPriority Critical
|
sl@0
|
3160 |
//! @SYMTestExpectedResults Panic, FSCLIENT:19
|
sl@0
|
3161 |
//!
|
sl@0
|
3162 |
//! @SYMTestType CIT
|
sl@0
|
3163 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3164 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3165 |
CREATE_OBJECT RFile file
|
sl@0
|
3166 |
COMMAND RFs1 new
|
sl@0
|
3167 |
COMMAND RFs1 Connect
|
sl@0
|
3168 |
COMMAND file new
|
sl@0
|
3169 |
COMMAND file Replace PBASE-F32-File-PublicApi-2001-001-Replace_command005
|
sl@0
|
3170 |
COMMAND file Write PBASE-F32-File-PublicApi-2001-001-Write_command006
|
sl@0
|
3171 |
COMMAND file Close
|
sl@0
|
3172 |
COMMAND file ~
|
sl@0
|
3173 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-2001-001-Delete_command010
|
sl@0
|
3174 |
COMMAND RFs1 ~
|
sl@0
|
3175 |
END_TEST_BLOCK !PanicCode=19 !PanicString="FSCLIENT panic"
|
sl@0
|
3176 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3177 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3178 |
COMMAND RFs1 new
|
sl@0
|
3179 |
COMMAND RFs1 Connect
|
sl@0
|
3180 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-2001-001-Delete_command010
|
sl@0
|
3181 |
COMMAND RFs1 ~
|
sl@0
|
3182 |
END_TEST_BLOCK
|
sl@0
|
3183 |
END_TESTCASE PBASE-F32-File-PublicApi-2001
|
sl@0
|
3184 |
|
sl@0
|
3185 |
|
sl@0
|
3186 |
START_TESTCASE PBASE-F32-File-PublicApi-2002
|
sl@0
|
3187 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-2002
|
sl@0
|
3188 |
//! @SYMAPI RFile
|
sl@0
|
3189 |
//! @SYMTestCaseDesc Function Write(TInt aPos, const TDesC8 &aDes, TInt aLength) test. Pass 0 for length.
|
sl@0
|
3190 |
//! Uses API elements: Write().
|
sl@0
|
3191 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
3192 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc2002.txt", EFileWrite.
|
sl@0
|
3193 |
//! 3. call write, pass "test", 0 for length, 0 for position.
|
sl@0
|
3194 |
//!
|
sl@0
|
3195 |
//!
|
sl@0
|
3196 |
//! @SYMTestStatus Implemented
|
sl@0
|
3197 |
//! @SYMTestPriority Critical
|
sl@0
|
3198 |
//! @SYMTestExpectedResults No panic is raised and no error is returned
|
sl@0
|
3199 |
//!
|
sl@0
|
3200 |
//! @SYMTestType CIT
|
sl@0
|
3201 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3202 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3203 |
CREATE_OBJECT RFile file
|
sl@0
|
3204 |
COMMAND RFs1 new
|
sl@0
|
3205 |
COMMAND RFs1 Connect
|
sl@0
|
3206 |
COMMAND file new
|
sl@0
|
3207 |
COMMAND file Replace PBASE-F32-File-PublicApi-2002-001-Replace_command005
|
sl@0
|
3208 |
COMMAND file Write PBASE-F32-File-PublicApi-2002-001-Write_command006
|
sl@0
|
3209 |
COMMAND file Close
|
sl@0
|
3210 |
COMMAND file ~
|
sl@0
|
3211 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-2002-001-Delete_command010
|
sl@0
|
3212 |
COMMAND RFs1 ~
|
sl@0
|
3213 |
END_TEST_BLOCK
|
sl@0
|
3214 |
END_TESTCASE PBASE-F32-File-PublicApi-2002
|
sl@0
|
3215 |
|
sl@0
|
3216 |
|
sl@0
|
3217 |
START_TESTCASE PBASE-F32-File-PublicApi-2003
|
sl@0
|
3218 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-2003
|
sl@0
|
3219 |
//! @SYMAPI RFile
|
sl@0
|
3220 |
//! @SYMTestCaseDesc Function Write(TInt aPos, const TDesC8 &aDes, TInt aLength) test. Pass -1 for length.
|
sl@0
|
3221 |
//! Uses API elements: Write().
|
sl@0
|
3222 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
3223 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc2003.txt", EFileWrite.
|
sl@0
|
3224 |
//! 3. call write, pass "test", -1 for length, 0 for position.
|
sl@0
|
3225 |
//!
|
sl@0
|
3226 |
//!
|
sl@0
|
3227 |
//! @SYMTestStatus Implemented
|
sl@0
|
3228 |
//! @SYMTestPriority Critical
|
sl@0
|
3229 |
//! @SYMTestExpectedResults RFile::Write returns KerrArgument
|
sl@0
|
3230 |
//!
|
sl@0
|
3231 |
//! @SYMTestType CIT
|
sl@0
|
3232 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3233 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3234 |
CREATE_OBJECT RFile file
|
sl@0
|
3235 |
COMMAND RFs1 new
|
sl@0
|
3236 |
COMMAND RFs1 Connect
|
sl@0
|
3237 |
COMMAND file new
|
sl@0
|
3238 |
COMMAND file Replace PBASE-F32-File-PublicApi-2003-001-Replace_command005
|
sl@0
|
3239 |
COMMAND !Error=-6 file Write PBASE-F32-File-PublicApi-2003-001-Write_command006
|
sl@0
|
3240 |
COMMAND file Close
|
sl@0
|
3241 |
COMMAND file ~
|
sl@0
|
3242 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-2003-001-Delete_command010
|
sl@0
|
3243 |
COMMAND RFs1 ~
|
sl@0
|
3244 |
END_TEST_BLOCK
|
sl@0
|
3245 |
END_TESTCASE PBASE-F32-File-PublicApi-2003
|
sl@0
|
3246 |
|
sl@0
|
3247 |
|
sl@0
|
3248 |
//
|
sl@0
|
3249 |
// Write8
|
sl@0
|
3250 |
//
|
sl@0
|
3251 |
|
sl@0
|
3252 |
|
sl@0
|
3253 |
START_TESTCASE PBASE-F32-File-PublicApi-2101
|
sl@0
|
3254 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-2101
|
sl@0
|
3255 |
//! @SYMAPI RFile
|
sl@0
|
3256 |
//! @SYMTestCaseDesc Asynchronous function write test. Pass a negative position and negative length.
|
sl@0
|
3257 |
//! Uses API elements: Write().
|
sl@0
|
3258 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
3259 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc2101.txt", EFileWrite.
|
sl@0
|
3260 |
//! 3. call write, pass literal "negative write test", -1 for length, -1 for negative, TRequestStatus.
|
sl@0
|
3261 |
//!
|
sl@0
|
3262 |
//!
|
sl@0
|
3263 |
//! @SYMTestStatus Implemented
|
sl@0
|
3264 |
//! @SYMTestPriority Critical
|
sl@0
|
3265 |
//! @SYMTestExpectedResults Panic, FSCLIENT:19
|
sl@0
|
3266 |
//!
|
sl@0
|
3267 |
//! @SYMTestType CIT
|
sl@0
|
3268 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3269 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3270 |
CREATE_OBJECT RFile file
|
sl@0
|
3271 |
COMMAND RFs1 new
|
sl@0
|
3272 |
COMMAND RFs1 Connect
|
sl@0
|
3273 |
COMMAND file new
|
sl@0
|
3274 |
COMMAND file Replace PBASE-F32-File-PublicApi-2101-001-Replace_command005
|
sl@0
|
3275 |
COMMAND file Write PBASE-F32-File-PublicApi-2101-001-Write_command006
|
sl@0
|
3276 |
OUTSTANDING
|
sl@0
|
3277 |
COMMAND file Close
|
sl@0
|
3278 |
COMMAND file ~
|
sl@0
|
3279 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-2101-001-Delete_command010
|
sl@0
|
3280 |
COMMAND RFs1 ~
|
sl@0
|
3281 |
END_TEST_BLOCK !PanicCode=19 !PanicString="FSCLIENT panic"
|
sl@0
|
3282 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3283 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3284 |
COMMAND RFs1 new
|
sl@0
|
3285 |
COMMAND RFs1 Connect
|
sl@0
|
3286 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-2101-001-Delete_command010
|
sl@0
|
3287 |
COMMAND RFs1 ~
|
sl@0
|
3288 |
END_TEST_BLOCK
|
sl@0
|
3289 |
END_TESTCASE PBASE-F32-File-PublicApi-2101
|
sl@0
|
3290 |
|
sl@0
|
3291 |
|
sl@0
|
3292 |
START_TESTCASE PBASE-F32-File-PublicApi-2102
|
sl@0
|
3293 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-2102
|
sl@0
|
3294 |
//! @SYMAPI RFile
|
sl@0
|
3295 |
//! @SYMTestCaseDesc Function Write(TInt aPos, const TDesC8 &aDes, TInt aLength) test. Pass 0 for length.
|
sl@0
|
3296 |
//! Uses API elements: Write().
|
sl@0
|
3297 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
3298 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc2102.txt", EFileWrite.
|
sl@0
|
3299 |
//! 3. call write, pass "test", 0 for length, 0 for position.
|
sl@0
|
3300 |
//!
|
sl@0
|
3301 |
//!
|
sl@0
|
3302 |
//! @SYMTestStatus Implemented
|
sl@0
|
3303 |
//! @SYMTestPriority Critical
|
sl@0
|
3304 |
//! @SYMTestExpectedResults No panic is raised and no error is returned
|
sl@0
|
3305 |
//!
|
sl@0
|
3306 |
//! @SYMTestType CIT
|
sl@0
|
3307 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3308 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3309 |
CREATE_OBJECT RFile file
|
sl@0
|
3310 |
COMMAND RFs1 new
|
sl@0
|
3311 |
COMMAND RFs1 Connect
|
sl@0
|
3312 |
COMMAND file new
|
sl@0
|
3313 |
COMMAND file Replace PBASE-F32-File-PublicApi-2102-001-Replace_command005
|
sl@0
|
3314 |
COMMAND file Write PBASE-F32-File-PublicApi-2102-001-Write_command006
|
sl@0
|
3315 |
OUTSTANDING
|
sl@0
|
3316 |
COMMAND file Close
|
sl@0
|
3317 |
COMMAND file ~
|
sl@0
|
3318 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-2102-001-Delete_command010
|
sl@0
|
3319 |
COMMAND RFs1 ~
|
sl@0
|
3320 |
END_TEST_BLOCK
|
sl@0
|
3321 |
END_TESTCASE PBASE-F32-File-PublicApi-2102
|
sl@0
|
3322 |
|
sl@0
|
3323 |
|
sl@0
|
3324 |
START_TESTCASE PBASE-F32-File-PublicApi-2103
|
sl@0
|
3325 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-2103
|
sl@0
|
3326 |
//! @SYMAPI RFile
|
sl@0
|
3327 |
//! @SYMTestCaseDesc Function Write(TInt aPos, const TDesC8 &aDes, TInt aLength) test. Pass a negative length.
|
sl@0
|
3328 |
//! Uses API elements: Write().
|
sl@0
|
3329 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
3330 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc2103.txt", EFileWrite.
|
sl@0
|
3331 |
//! 3. call write, pass "test", -1 for length, 0 for position.
|
sl@0
|
3332 |
//!
|
sl@0
|
3333 |
//!
|
sl@0
|
3334 |
//! @SYMTestStatus Implemented
|
sl@0
|
3335 |
//! @SYMTestPriority Critical
|
sl@0
|
3336 |
//! @SYMTestExpectedResults RFile::Write returns KerrArgument
|
sl@0
|
3337 |
//!
|
sl@0
|
3338 |
//! @SYMTestType CIT
|
sl@0
|
3339 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3340 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3341 |
CREATE_OBJECT RFile file
|
sl@0
|
3342 |
COMMAND RFs1 new
|
sl@0
|
3343 |
COMMAND RFs1 Connect
|
sl@0
|
3344 |
COMMAND file new
|
sl@0
|
3345 |
COMMAND file Replace PBASE-F32-File-PublicApi-2103-001-Replace_command005
|
sl@0
|
3346 |
COMMAND !AsyncError=-6 file Write PBASE-F32-File-PublicApi-2103-001-Write_command006
|
sl@0
|
3347 |
OUTSTANDING
|
sl@0
|
3348 |
COMMAND file Close
|
sl@0
|
3349 |
COMMAND file ~
|
sl@0
|
3350 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-2103-001-Delete_command010
|
sl@0
|
3351 |
COMMAND RFs1 ~
|
sl@0
|
3352 |
END_TEST_BLOCK
|
sl@0
|
3353 |
END_TESTCASE PBASE-F32-File-PublicApi-2103
|
sl@0
|
3354 |
|
sl@0
|
3355 |
|
sl@0
|
3356 |
//
|
sl@0
|
3357 |
// Lock
|
sl@0
|
3358 |
//
|
sl@0
|
3359 |
|
sl@0
|
3360 |
|
sl@0
|
3361 |
START_TESTCASE PBASE-F32-File-PublicApi-2201
|
sl@0
|
3362 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-2201
|
sl@0
|
3363 |
//! @SYMAPI RFile
|
sl@0
|
3364 |
//! @SYMTestCaseDesc Function Lock() neg. test - open a file and try to lock zero bytes.
|
sl@0
|
3365 |
//! Uses API elements: Lock(), Unlock(), Read().
|
sl@0
|
3366 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
3367 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc2201.txt", EFileRead.
|
sl@0
|
3368 |
//! 3. Write "test" to file.
|
sl@0
|
3369 |
//! 4. Lock the file by Calling Lock(), passing pos 0, len 0.
|
sl@0
|
3370 |
//! 5. Close file.
|
sl@0
|
3371 |
//! 6. Close fs session.
|
sl@0
|
3372 |
//!
|
sl@0
|
3373 |
//!
|
sl@0
|
3374 |
//! @SYMTestStatus Implemented
|
sl@0
|
3375 |
//! @SYMTestPriority Critical
|
sl@0
|
3376 |
//! @SYMTestExpectedResults Panic - FSCLIENT:17
|
sl@0
|
3377 |
//!
|
sl@0
|
3378 |
//! @SYMTestType CIT
|
sl@0
|
3379 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3380 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3381 |
CREATE_OBJECT RFile file
|
sl@0
|
3382 |
COMMAND RFs1 new
|
sl@0
|
3383 |
COMMAND RFs1 Connect
|
sl@0
|
3384 |
COMMAND file new
|
sl@0
|
3385 |
COMMAND file Replace PBASE-F32-File-PublicApi-2201-001-Replace_command005
|
sl@0
|
3386 |
COMMAND file Write PBASE-F32-File-PublicApi-2201-001-Write_command006
|
sl@0
|
3387 |
COMMAND file Lock PBASE-F32-File-PublicApi-2201-001-Lock_command007
|
sl@0
|
3388 |
COMMAND file Close
|
sl@0
|
3389 |
COMMAND file ~
|
sl@0
|
3390 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-2201-001-Delete_command011
|
sl@0
|
3391 |
COMMAND RFs1 ~
|
sl@0
|
3392 |
END_TEST_BLOCK !PanicCode=17 !PanicString="FSCLIENT"
|
sl@0
|
3393 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3394 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3395 |
COMMAND RFs1 new
|
sl@0
|
3396 |
COMMAND RFs1 Connect
|
sl@0
|
3397 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-2201-001-Delete_command011
|
sl@0
|
3398 |
COMMAND RFs1 ~
|
sl@0
|
3399 |
END_TEST_BLOCK
|
sl@0
|
3400 |
END_TESTCASE PBASE-F32-File-PublicApi-2201
|
sl@0
|
3401 |
|
sl@0
|
3402 |
|
sl@0
|
3403 |
START_TESTCASE PBASE-F32-File-PublicApi-2202
|
sl@0
|
3404 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-2202
|
sl@0
|
3405 |
//! @SYMAPI RFile
|
sl@0
|
3406 |
//! @SYMTestCaseDesc Function Lock() neg. test - open same file with two handles, try to lock the same region twice.
|
sl@0
|
3407 |
//! Uses API elements: Lock(), Unlock(), Read().
|
sl@0
|
3408 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
3409 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc2202.txt", EFileWrite, open file as fileOne.
|
sl@0
|
3410 |
//! 3. Lock the file by Calling Lock().
|
sl@0
|
3411 |
//! 4. Open "{Drives, RAMDriveTestPath}file\tc2202.txt" as fileTwo.
|
sl@0
|
3412 |
//! 5. lock the file 2 at the same position and length as fileOne.
|
sl@0
|
3413 |
//! 6. Close fileOne.
|
sl@0
|
3414 |
//! 7. Close fileTwo
|
sl@0
|
3415 |
//! 8. Delete file
|
sl@0
|
3416 |
//! 9. Close first RFs.
|
sl@0
|
3417 |
//!
|
sl@0
|
3418 |
//! @SYMTestStatus Implemented
|
sl@0
|
3419 |
//! @SYMTestPriority Critical
|
sl@0
|
3420 |
//! @SYMTestExpectedResults Lock() returns KErrLocked at step 5.
|
sl@0
|
3421 |
//!
|
sl@0
|
3422 |
//! @SYMTestType CIT
|
sl@0
|
3423 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3424 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3425 |
CREATE_OBJECT RFile file
|
sl@0
|
3426 |
CREATE_OBJECT RFile file2
|
sl@0
|
3427 |
COMMAND RFs1 new
|
sl@0
|
3428 |
COMMAND RFs1 Connect
|
sl@0
|
3429 |
COMMAND file new
|
sl@0
|
3430 |
COMMAND file Replace PBASE-F32-File-PublicApi-2202-001-Replace_command005
|
sl@0
|
3431 |
COMMAND file Write PBASE-F32-File-PublicApi-2202-001-Write_command006
|
sl@0
|
3432 |
COMMAND file Lock PBASE-F32-File-PublicApi-2202-001-Lock_command007
|
sl@0
|
3433 |
COMMAND file2 new
|
sl@0
|
3434 |
COMMAND file2 Open PBASE-F32-File-PublicApi-2202-001-Open_command010
|
sl@0
|
3435 |
COMMAND !Error=-22 file2 Lock PBASE-F32-File-PublicApi-2202-001-Lock_command011
|
sl@0
|
3436 |
COMMAND file2 Close
|
sl@0
|
3437 |
COMMAND file2 ~
|
sl@0
|
3438 |
COMMAND file Close
|
sl@0
|
3439 |
COMMAND file ~
|
sl@0
|
3440 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-2202-001-Delete_command017
|
sl@0
|
3441 |
COMMAND RFs1 ~
|
sl@0
|
3442 |
END_TEST_BLOCK
|
sl@0
|
3443 |
END_TESTCASE PBASE-F32-File-PublicApi-2202
|
sl@0
|
3444 |
|
sl@0
|
3445 |
|
sl@0
|
3446 |
START_TESTCASE PBASE-F32-File-PublicApi-2203
|
sl@0
|
3447 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-2203
|
sl@0
|
3448 |
//! @SYMAPI RFile
|
sl@0
|
3449 |
//! @SYMTestCaseDesc Function Lock() neg. test - try to lock negative length.
|
sl@0
|
3450 |
//! Uses API elements: Lock(), Unlock(), Read().
|
sl@0
|
3451 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
3452 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc2203.txt", EFileWrite, open file as fileOne.
|
sl@0
|
3453 |
//! 3. Lock the file by Calling Lock() with 0 for pos and -1 for length.
|
sl@0
|
3454 |
//!
|
sl@0
|
3455 |
//! @SYMTestStatus Implemented
|
sl@0
|
3456 |
//! @SYMTestPriority Critical
|
sl@0
|
3457 |
//! @SYMTestExpectedResults Lock() returns panic.
|
sl@0
|
3458 |
//!
|
sl@0
|
3459 |
//! @SYMTestType CIT
|
sl@0
|
3460 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3461 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3462 |
CREATE_OBJECT RFile file
|
sl@0
|
3463 |
COMMAND RFs1 new
|
sl@0
|
3464 |
COMMAND RFs1 Connect
|
sl@0
|
3465 |
COMMAND file new
|
sl@0
|
3466 |
COMMAND file Replace PBASE-F32-File-PublicApi-2203-001-Replace_command005
|
sl@0
|
3467 |
COMMAND file Write PBASE-F32-File-PublicApi-2203-001-Write_command006
|
sl@0
|
3468 |
COMMAND file Lock PBASE-F32-File-PublicApi-2203-001-Lock_command007
|
sl@0
|
3469 |
END_TEST_BLOCK !PanicCode=17 !PanicString="FSCLIENT"
|
sl@0
|
3470 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3471 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3472 |
COMMAND RFs1 new
|
sl@0
|
3473 |
COMMAND RFs1 Connect
|
sl@0
|
3474 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-2203-001-Delete_command011
|
sl@0
|
3475 |
COMMAND RFs1 ~
|
sl@0
|
3476 |
END_TEST_BLOCK
|
sl@0
|
3477 |
END_TESTCASE PBASE-F32-File-PublicApi-2203
|
sl@0
|
3478 |
|
sl@0
|
3479 |
|
sl@0
|
3480 |
START_TESTCASE PBASE-F32-File-PublicApi-2204
|
sl@0
|
3481 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-2204
|
sl@0
|
3482 |
//! @SYMAPI RFile
|
sl@0
|
3483 |
//! @SYMTestCaseDesc Function Lock() neg. test - try to lock negative position.
|
sl@0
|
3484 |
//! Uses API elements: Lock(), Unlock(), Read().
|
sl@0
|
3485 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
3486 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc2204.txt", EFileWrite, open file as fileOne.
|
sl@0
|
3487 |
//! 3. Lock the file by Calling Lock() with -1 for pos and 1 for length.
|
sl@0
|
3488 |
//! 4. Close file.
|
sl@0
|
3489 |
//! 5. Delete file.
|
sl@0
|
3490 |
//! 6. Close RFs.
|
sl@0
|
3491 |
//!
|
sl@0
|
3492 |
//! @SYMTestStatus Implemented
|
sl@0
|
3493 |
//! @SYMTestPriority Critical
|
sl@0
|
3494 |
//! @SYMTestExpectedResults No error returned or panic raised.
|
sl@0
|
3495 |
//!
|
sl@0
|
3496 |
//! @SYMTestType CIT
|
sl@0
|
3497 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3498 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3499 |
CREATE_OBJECT RFile file
|
sl@0
|
3500 |
COMMAND RFs1 new
|
sl@0
|
3501 |
COMMAND RFs1 Connect
|
sl@0
|
3502 |
COMMAND file new
|
sl@0
|
3503 |
COMMAND file Replace PBASE-F32-File-PublicApi-2204-001-Replace_command005
|
sl@0
|
3504 |
COMMAND file Write PBASE-F32-File-PublicApi-2204-001-Write_command006
|
sl@0
|
3505 |
COMMAND file Lock PBASE-F32-File-PublicApi-2204-001-Lock_command007
|
sl@0
|
3506 |
END_TEST_BLOCK !PanicCode=19 !PanicString="FSCLIENT panic"
|
sl@0
|
3507 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3508 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3509 |
COMMAND RFs1 new
|
sl@0
|
3510 |
COMMAND RFs1 Connect
|
sl@0
|
3511 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-2204-001-Delete_command010
|
sl@0
|
3512 |
COMMAND RFs1 ~
|
sl@0
|
3513 |
END_TEST_BLOCK
|
sl@0
|
3514 |
END_TESTCASE PBASE-F32-File-PublicApi-2204
|
sl@0
|
3515 |
|
sl@0
|
3516 |
START_TESTCASE PBASE-F32-File-PublicApi-2205
|
sl@0
|
3517 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-2205
|
sl@0
|
3518 |
//! @SYMAPI RFile
|
sl@0
|
3519 |
//! @SYMTestCaseDesc Function Lock() neg. test - try to write to locked file.
|
sl@0
|
3520 |
//! Uses API elements: Lock(), Unlock(), Read().
|
sl@0
|
3521 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
3522 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc2205.txt", EFileWrite, open file as file1.
|
sl@0
|
3523 |
//! 3. Call RFile::Open passing RFs, literal "{Drives, RAMDriveTestPath}file\tc2205.txt", EFileWrite | EFileShareAny, open file as file2.
|
sl@0
|
3524 |
//! 4. Write "test" to file through file1.
|
sl@0
|
3525 |
//! 5. Lock the file by Calling Lock() with 6 for pos and 4 for length, through file1
|
sl@0
|
3526 |
//! 6. Write "Trying to write to locked region" through new handle
|
sl@0
|
3527 |
//! 7. Close file.
|
sl@0
|
3528 |
//! 8. Close second handle
|
sl@0
|
3529 |
//! 9. Delete file.
|
sl@0
|
3530 |
//! 10. Close RFs.
|
sl@0
|
3531 |
//!
|
sl@0
|
3532 |
//! @SYMTestStatus Implemented
|
sl@0
|
3533 |
//! @SYMTestPriority Critical
|
sl@0
|
3534 |
//! @SYMTestExpectedResults trying to write to locked file returns KErrLocked
|
sl@0
|
3535 |
//!
|
sl@0
|
3536 |
//! @SYMTestType CIT
|
sl@0
|
3537 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3538 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3539 |
CREATE_OBJECT RFile file
|
sl@0
|
3540 |
CREATE_OBJECT RFile file2
|
sl@0
|
3541 |
COMMAND RFs1 new
|
sl@0
|
3542 |
COMMAND RFs1 Connect
|
sl@0
|
3543 |
COMMAND file new
|
sl@0
|
3544 |
COMMAND file Replace PBASE-F32-File-PublicApi-2205-001-Replace_command005
|
sl@0
|
3545 |
COMMAND file2 new
|
sl@0
|
3546 |
COMMAND file2 Open PBASE-F32-File-PublicApi-2205-001-Open_command008
|
sl@0
|
3547 |
COMMAND file Write PBASE-F32-File-PublicApi-2205-001-Write_command010
|
sl@0
|
3548 |
COMMAND file Lock PBASE-F32-File-PublicApi-2205-001-Lock_command011
|
sl@0
|
3549 |
COMMAND !Error=-22 file2 Write PBASE-F32-File-PublicApi-2205-001-Write_command013
|
sl@0
|
3550 |
COMMAND file2 Close
|
sl@0
|
3551 |
COMMAND file2 ~
|
sl@0
|
3552 |
COMMAND file Close
|
sl@0
|
3553 |
COMMAND file ~
|
sl@0
|
3554 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-2205-001-Delete_command020
|
sl@0
|
3555 |
COMMAND RFs1 ~
|
sl@0
|
3556 |
END_TEST_BLOCK
|
sl@0
|
3557 |
END_TESTCASE PBASE-F32-File-PublicApi-2205
|
sl@0
|
3558 |
|
sl@0
|
3559 |
//
|
sl@0
|
3560 |
// UnLock
|
sl@0
|
3561 |
//
|
sl@0
|
3562 |
|
sl@0
|
3563 |
|
sl@0
|
3564 |
START_TESTCASE PBASE-F32-File-PublicApi-2301
|
sl@0
|
3565 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-2301
|
sl@0
|
3566 |
//! @SYMAPI RFile
|
sl@0
|
3567 |
//! @SYMTestCaseDesc Function UnLock() neg. test - open a file try to unlock a region that has not been locked.
|
sl@0
|
3568 |
//!
|
sl@0
|
3569 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
3570 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc2301.txt", EFileWrite.
|
sl@0
|
3571 |
//! 3. write "test data" to file.
|
sl@0
|
3572 |
//! 4. call UnLock with position 2 and with length 4
|
sl@0
|
3573 |
//! 5. close file
|
sl@0
|
3574 |
//! 6. Delete file.
|
sl@0
|
3575 |
//! 7. close fs.
|
sl@0
|
3576 |
//!
|
sl@0
|
3577 |
//! @SYMTestStatus Implemented
|
sl@0
|
3578 |
//! @SYMTestPriority Critical
|
sl@0
|
3579 |
//! @SYMTestExpectedResults UnLock() returns KErrNotFound.
|
sl@0
|
3580 |
//!
|
sl@0
|
3581 |
//! @SYMTestType CIT
|
sl@0
|
3582 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3583 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3584 |
CREATE_OBJECT RFile file
|
sl@0
|
3585 |
COMMAND RFs1 new
|
sl@0
|
3586 |
COMMAND RFs1 Connect
|
sl@0
|
3587 |
COMMAND file new
|
sl@0
|
3588 |
COMMAND file Replace PBASE-F32-File-PublicApi-2301-001-Replace_command005
|
sl@0
|
3589 |
COMMAND file Write PBASE-F32-File-PublicApi-2301-001-Write_command006
|
sl@0
|
3590 |
COMMAND !Error=-1 file UnLock PBASE-F32-File-PublicApi-2301-001-UnLock_command007
|
sl@0
|
3591 |
COMMAND file Close
|
sl@0
|
3592 |
COMMAND file ~
|
sl@0
|
3593 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-2301-001-Delete_command011
|
sl@0
|
3594 |
COMMAND RFs1 ~
|
sl@0
|
3595 |
END_TEST_BLOCK
|
sl@0
|
3596 |
END_TESTCASE PBASE-F32-File-PublicApi-2301
|
sl@0
|
3597 |
|
sl@0
|
3598 |
|
sl@0
|
3599 |
START_TESTCASE PBASE-F32-File-PublicApi-2302
|
sl@0
|
3600 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-2302
|
sl@0
|
3601 |
//! @SYMAPI RFile
|
sl@0
|
3602 |
//! @SYMTestCaseDesc Function UnLock() neg. test - open a file lock some part, try to unlock a portion of the locked region.
|
sl@0
|
3603 |
//!
|
sl@0
|
3604 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
3605 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc2302.txt", EFileWrite.
|
sl@0
|
3606 |
//! 3. Write some data to file.
|
sl@0
|
3607 |
//! 4. Lock the file by Calling Lock() with pos 0 and length 2.
|
sl@0
|
3608 |
//! 5. UnLock a portion of that file with posi 0 and length 1.
|
sl@0
|
3609 |
//! 6. Close that file.
|
sl@0
|
3610 |
//! 7. Delete file.
|
sl@0
|
3611 |
//! 8. close fs session.
|
sl@0
|
3612 |
//!
|
sl@0
|
3613 |
//! @SYMTestStatus Implemented
|
sl@0
|
3614 |
//! @SYMTestPriority Critical
|
sl@0
|
3615 |
//! @SYMTestExpectedResults UnLock() returns KErrNotFound.
|
sl@0
|
3616 |
//!
|
sl@0
|
3617 |
//! @SYMTestType CIT
|
sl@0
|
3618 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3619 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3620 |
CREATE_OBJECT RFile file
|
sl@0
|
3621 |
COMMAND RFs1 new
|
sl@0
|
3622 |
COMMAND RFs1 Connect
|
sl@0
|
3623 |
COMMAND file new
|
sl@0
|
3624 |
COMMAND file Replace PBASE-F32-File-PublicApi-2302-001-Replace_command005
|
sl@0
|
3625 |
COMMAND file Write PBASE-F32-File-PublicApi-2302-001-Write_command006
|
sl@0
|
3626 |
COMMAND file Lock PBASE-F32-File-PublicApi-2302-001-Lock_command007
|
sl@0
|
3627 |
COMMAND !Error=-1 file UnLock PBASE-F32-File-PublicApi-2302-001-Close_command008
|
sl@0
|
3628 |
COMMAND file Close
|
sl@0
|
3629 |
COMMAND file ~
|
sl@0
|
3630 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-2302-001-Delete_command014
|
sl@0
|
3631 |
COMMAND RFs1 ~
|
sl@0
|
3632 |
END_TEST_BLOCK
|
sl@0
|
3633 |
END_TESTCASE PBASE-F32-File-PublicApi-2302
|
sl@0
|
3634 |
|
sl@0
|
3635 |
|
sl@0
|
3636 |
START_TESTCASE PBASE-F32-File-PublicApi-2303
|
sl@0
|
3637 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-2303
|
sl@0
|
3638 |
//! @SYMAPI RFile
|
sl@0
|
3639 |
//! @SYMTestCaseDesc Function UnLock() neg. test - UnLock a region with negative length
|
sl@0
|
3640 |
//!
|
sl@0
|
3641 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
3642 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc2303.txt", EFileWrite.
|
sl@0
|
3643 |
//! 3. Write some data to file.
|
sl@0
|
3644 |
//! 4. Call Lock with pos 2, length 2.
|
sl@0
|
3645 |
//! 5. UnLock by calling 2 for position -2 for length.
|
sl@0
|
3646 |
//!
|
sl@0
|
3647 |
//! @SYMTestStatus Implemented
|
sl@0
|
3648 |
//! @SYMTestPriority Critical
|
sl@0
|
3649 |
//! @SYMTestExpectedResults UnLock() causes FSCLIENT:18.
|
sl@0
|
3650 |
//!
|
sl@0
|
3651 |
//! @SYMTestType CIT
|
sl@0
|
3652 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3653 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3654 |
CREATE_OBJECT RFile file
|
sl@0
|
3655 |
COMMAND RFs1 new
|
sl@0
|
3656 |
COMMAND RFs1 Connect
|
sl@0
|
3657 |
COMMAND file new
|
sl@0
|
3658 |
COMMAND file Replace PBASE-F32-File-PublicApi-2303-001-Replace_command005
|
sl@0
|
3659 |
COMMAND file Write PBASE-F32-File-PublicApi-2303-001-Write_command006
|
sl@0
|
3660 |
COMMAND file Lock PBASE-F32-File-PublicApi-2303-001-Lock_command007
|
sl@0
|
3661 |
COMMAND file UnLock PBASE-F32-File-PublicApi-2303-001-UnLock_command008
|
sl@0
|
3662 |
END_TEST_BLOCK !PanicCode=18 !PanicString="FSCLIENT"
|
sl@0
|
3663 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3664 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3665 |
COMMAND RFs1 new
|
sl@0
|
3666 |
COMMAND RFs1 Connect
|
sl@0
|
3667 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-2303-001-Delete_command011
|
sl@0
|
3668 |
COMMAND RFs1 ~
|
sl@0
|
3669 |
END_TEST_BLOCK
|
sl@0
|
3670 |
END_TESTCASE PBASE-F32-File-PublicApi-2303
|
sl@0
|
3671 |
|
sl@0
|
3672 |
|
sl@0
|
3673 |
START_TESTCASE PBASE-F32-File-PublicApi-2304
|
sl@0
|
3674 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-2304
|
sl@0
|
3675 |
//! @SYMAPI RFile
|
sl@0
|
3676 |
//! @SYMTestCaseDesc Function UnLock() neg. test - UnLock a region with negative position
|
sl@0
|
3677 |
//!
|
sl@0
|
3678 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
3679 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc2304.txt", EFileWrite.
|
sl@0
|
3680 |
//! 3. Write some data to file.
|
sl@0
|
3681 |
//! 4. Call Lock with pos 2, length 2.
|
sl@0
|
3682 |
//! 5. UnLock by calling -2 for position 2 for length.
|
sl@0
|
3683 |
//! 6. Close that file.
|
sl@0
|
3684 |
//! 7. Delete file.
|
sl@0
|
3685 |
//! 8. close fs session.
|
sl@0
|
3686 |
//!
|
sl@0
|
3687 |
//! @SYMTestStatus Implemented
|
sl@0
|
3688 |
//! @SYMTestPriority Critical
|
sl@0
|
3689 |
//! @SYMTestExpectedResults RFile::UnLock() causes FSCLIENT:19.
|
sl@0
|
3690 |
//!
|
sl@0
|
3691 |
//! @SYMTestType CIT
|
sl@0
|
3692 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3693 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3694 |
CREATE_OBJECT RFile file
|
sl@0
|
3695 |
COMMAND RFs1 new
|
sl@0
|
3696 |
COMMAND RFs1 Connect
|
sl@0
|
3697 |
COMMAND file new
|
sl@0
|
3698 |
COMMAND file Replace PBASE-F32-File-PublicApi-2304-001-Replace_command005
|
sl@0
|
3699 |
COMMAND file Write PBASE-F32-File-PublicApi-2304-001-Write_command006
|
sl@0
|
3700 |
COMMAND file Lock PBASE-F32-File-PublicApi-2304-001-Lock_command007
|
sl@0
|
3701 |
COMMAND file UnLock PBASE-F32-File-PublicApi-2304-001-UnLock_command008
|
sl@0
|
3702 |
END_TEST_BLOCK !PanicCode=19 !PanicString="FSCLIENT panic"
|
sl@0
|
3703 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3704 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3705 |
COMMAND RFs1 new
|
sl@0
|
3706 |
COMMAND RFs1 Connect
|
sl@0
|
3707 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-2304-001-Delete_command012
|
sl@0
|
3708 |
COMMAND RFs1 ~
|
sl@0
|
3709 |
END_TEST_BLOCK
|
sl@0
|
3710 |
END_TESTCASE PBASE-F32-File-PublicApi-2304
|
sl@0
|
3711 |
|
sl@0
|
3712 |
|
sl@0
|
3713 |
//
|
sl@0
|
3714 |
// Seek
|
sl@0
|
3715 |
//
|
sl@0
|
3716 |
|
sl@0
|
3717 |
|
sl@0
|
3718 |
START_TESTCASE PBASE-F32-File-PublicApi-2401
|
sl@0
|
3719 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-2401
|
sl@0
|
3720 |
//! @SYMAPI RFile
|
sl@0
|
3721 |
//! @SYMTestCaseDesc Function Seek() neg. test - try to seek to negative position.
|
sl@0
|
3722 |
//!
|
sl@0
|
3723 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
3724 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc2401.txt", EFileWrite.
|
sl@0
|
3725 |
//! 3. Write "Seek test" to file.
|
sl@0
|
3726 |
//! 4. Call RFile::Seek() passing ESeekStart, -10.
|
sl@0
|
3727 |
//! 5. Close file.
|
sl@0
|
3728 |
//! 6. Delete file.
|
sl@0
|
3729 |
//! 7. Close fs session.
|
sl@0
|
3730 |
//!
|
sl@0
|
3731 |
//! @SYMTestStatus Implemented
|
sl@0
|
3732 |
//! @SYMTestPriority Critical
|
sl@0
|
3733 |
//! @SYMTestExpectedResults Seek returns KErrArgument.
|
sl@0
|
3734 |
//!
|
sl@0
|
3735 |
//! @SYMTestType CIT
|
sl@0
|
3736 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3737 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3738 |
CREATE_OBJECT RFile file
|
sl@0
|
3739 |
COMMAND RFs1 new
|
sl@0
|
3740 |
COMMAND RFs1 Connect
|
sl@0
|
3741 |
COMMAND file new
|
sl@0
|
3742 |
COMMAND file Replace PBASE-F32-File-PublicApi-2401-001-Replace_command005
|
sl@0
|
3743 |
COMMAND file Write PBASE-F32-File-PublicApi-2401-001-Write_command006
|
sl@0
|
3744 |
COMMAND !Error=-6 file Seek PBASE-F32-File-PublicApi-2401-001-Seek_command007
|
sl@0
|
3745 |
COMMAND file Close
|
sl@0
|
3746 |
COMMAND file ~
|
sl@0
|
3747 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-2401-001-Delete_command011
|
sl@0
|
3748 |
COMMAND RFs1 ~
|
sl@0
|
3749 |
END_TEST_BLOCK
|
sl@0
|
3750 |
END_TESTCASE PBASE-F32-File-PublicApi-2401
|
sl@0
|
3751 |
|
sl@0
|
3752 |
|
sl@0
|
3753 |
//
|
sl@0
|
3754 |
// Flush
|
sl@0
|
3755 |
//
|
sl@0
|
3756 |
|
sl@0
|
3757 |
|
sl@0
|
3758 |
|
sl@0
|
3759 |
|
sl@0
|
3760 |
//
|
sl@0
|
3761 |
// Size
|
sl@0
|
3762 |
//
|
sl@0
|
3763 |
|
sl@0
|
3764 |
|
sl@0
|
3765 |
|
sl@0
|
3766 |
|
sl@0
|
3767 |
//
|
sl@0
|
3768 |
// SetSize
|
sl@0
|
3769 |
//
|
sl@0
|
3770 |
|
sl@0
|
3771 |
|
sl@0
|
3772 |
START_TESTCASE PBASE-F32-File-PublicApi-2701
|
sl@0
|
3773 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-2701
|
sl@0
|
3774 |
//! @SYMAPI RFile
|
sl@0
|
3775 |
//! @SYMTestCaseDesc Function SetSize() neg test - try to pass a negative size.
|
sl@0
|
3776 |
//!
|
sl@0
|
3777 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
3778 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc2701.txt", EFileWrite.
|
sl@0
|
3779 |
//! 3. Write "test" to file.
|
sl@0
|
3780 |
//! 3. Call SetSize with -2.
|
sl@0
|
3781 |
//!
|
sl@0
|
3782 |
//! @SYMTestStatus Implemented
|
sl@0
|
3783 |
//! @SYMTestPriority Critical
|
sl@0
|
3784 |
//! @SYMTestExpectedResults Panic - FSCLIENT:20
|
sl@0
|
3785 |
//!
|
sl@0
|
3786 |
//! @SYMTestType CIT
|
sl@0
|
3787 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3788 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3789 |
CREATE_OBJECT RFile file
|
sl@0
|
3790 |
COMMAND RFs1 new
|
sl@0
|
3791 |
COMMAND RFs1 Connect
|
sl@0
|
3792 |
COMMAND file new
|
sl@0
|
3793 |
COMMAND file Replace PBASE-F32-File-PublicApi-2701-001-Replace_command005
|
sl@0
|
3794 |
COMMAND file Write PBASE-F32-File-PublicApi-2701-001-Write_command006
|
sl@0
|
3795 |
COMMAND file SetSize PBASE-F32-File-PublicApi-2701-001-SetSize_command007
|
sl@0
|
3796 |
COMMAND file Close
|
sl@0
|
3797 |
COMMAND file ~
|
sl@0
|
3798 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-2701-001-Delete_command011
|
sl@0
|
3799 |
COMMAND RFs1 ~
|
sl@0
|
3800 |
END_TEST_BLOCK !PanicCode=20 !PanicString="FSCLIENT"
|
sl@0
|
3801 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3802 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3803 |
COMMAND RFs1 new
|
sl@0
|
3804 |
COMMAND RFs1 Connect
|
sl@0
|
3805 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-2701-001-Delete_command011
|
sl@0
|
3806 |
COMMAND RFs1 ~
|
sl@0
|
3807 |
END_TEST_BLOCK
|
sl@0
|
3808 |
END_TESTCASE PBASE-F32-File-PublicApi-2701
|
sl@0
|
3809 |
|
sl@0
|
3810 |
|
sl@0
|
3811 |
//
|
sl@0
|
3812 |
// Att
|
sl@0
|
3813 |
//
|
sl@0
|
3814 |
|
sl@0
|
3815 |
|
sl@0
|
3816 |
|
sl@0
|
3817 |
//
|
sl@0
|
3818 |
// SetAtt
|
sl@0
|
3819 |
//
|
sl@0
|
3820 |
|
sl@0
|
3821 |
|
sl@0
|
3822 |
START_TESTCASE PBASE-F32-File-PublicApi-2901
|
sl@0
|
3823 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-2901
|
sl@0
|
3824 |
//! @SYMAPI RFile
|
sl@0
|
3825 |
//! @SYMTestCaseDesc Function SetAtt neg. test - set same attribute on both bitmasks.
|
sl@0
|
3826 |
//! Uses API elements: Att().
|
sl@0
|
3827 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
3828 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc2901.txt", EFileWrite.
|
sl@0
|
3829 |
//! 3. Write "test" to file.
|
sl@0
|
3830 |
//! 4. Call RFile::SetAtt, passing KEntryAttNormal, KEntryAttNormal
|
sl@0
|
3831 |
//!
|
sl@0
|
3832 |
//!
|
sl@0
|
3833 |
//! @SYMTestStatus Implemented
|
sl@0
|
3834 |
//! @SYMTestPriority Critical
|
sl@0
|
3835 |
//! @SYMTestExpectedResults Panic FSCLIENT:21 at step 3.
|
sl@0
|
3836 |
//!
|
sl@0
|
3837 |
//! @SYMTestType CIT
|
sl@0
|
3838 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3839 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3840 |
CREATE_OBJECT RFile file
|
sl@0
|
3841 |
COMMAND RFs1 new
|
sl@0
|
3842 |
COMMAND RFs1 Connect
|
sl@0
|
3843 |
COMMAND file new
|
sl@0
|
3844 |
COMMAND file Replace PBASE-F32-File-PublicApi-2901-001-Replace_command005
|
sl@0
|
3845 |
COMMAND file Write PBASE-F32-File-PublicApi-2901-001-Write_command006
|
sl@0
|
3846 |
COMMAND file SetAtt PBASE-F32-File-PublicApi-2901-001-SetAtt_command007
|
sl@0
|
3847 |
COMMAND file Close
|
sl@0
|
3848 |
COMMAND file ~
|
sl@0
|
3849 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-2901-001-Delete_command011
|
sl@0
|
3850 |
COMMAND RFs1 ~
|
sl@0
|
3851 |
END_TEST_BLOCK !PanicCode=21 !PanicString="FSCLIENT panic"
|
sl@0
|
3852 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3853 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3854 |
COMMAND RFs1 new
|
sl@0
|
3855 |
COMMAND RFs1 Connect
|
sl@0
|
3856 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-2901-001-Delete_command011
|
sl@0
|
3857 |
COMMAND RFs1 ~
|
sl@0
|
3858 |
END_TEST_BLOCK
|
sl@0
|
3859 |
END_TESTCASE PBASE-F32-File-PublicApi-2901
|
sl@0
|
3860 |
|
sl@0
|
3861 |
|
sl@0
|
3862 |
//
|
sl@0
|
3863 |
// Modified
|
sl@0
|
3864 |
//
|
sl@0
|
3865 |
|
sl@0
|
3866 |
|
sl@0
|
3867 |
|
sl@0
|
3868 |
//
|
sl@0
|
3869 |
// SetModified
|
sl@0
|
3870 |
//
|
sl@0
|
3871 |
|
sl@0
|
3872 |
|
sl@0
|
3873 |
START_TESTCASE PBASE-F32-File-PublicApi-3101
|
sl@0
|
3874 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-3101
|
sl@0
|
3875 |
//! @SYMAPI RFile
|
sl@0
|
3876 |
//! @SYMTestCaseDesc Function SetModified neg. test - open file for reading and set it's date.
|
sl@0
|
3877 |
//! Uses API elements: Modified(), SetModified().
|
sl@0
|
3878 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
3879 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc3101.txt", EFileWrite.
|
sl@0
|
3880 |
//! 3. Write "test" to file
|
sl@0
|
3881 |
//! 4. Call RFile::SetModified.
|
sl@0
|
3882 |
//! 5. Close file.
|
sl@0
|
3883 |
//! 6. Delete file.
|
sl@0
|
3884 |
//! 7. Close fs.
|
sl@0
|
3885 |
//!
|
sl@0
|
3886 |
//! @SYMTestStatus Implemented
|
sl@0
|
3887 |
//! @SYMTestPriority Critical
|
sl@0
|
3888 |
//! @SYMTestExpectedResults RFile::SetModified returns KErrAccessDenied.
|
sl@0
|
3889 |
//!
|
sl@0
|
3890 |
//! @SYMTestType CIT
|
sl@0
|
3891 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3892 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3893 |
CREATE_OBJECT RFile file
|
sl@0
|
3894 |
COMMAND RFs1 new
|
sl@0
|
3895 |
COMMAND RFs1 Connect
|
sl@0
|
3896 |
COMMAND file new
|
sl@0
|
3897 |
COMMAND file Replace PBASE-F32-File-PublicApi-3101-001-Replace_command005
|
sl@0
|
3898 |
COMMAND file Write PBASE-F32-File-PublicApi-3101-001-Write_command006
|
sl@0
|
3899 |
COMMAND file Close
|
sl@0
|
3900 |
COMMAND file Open PBASE-F32-File-PublicApi-3101-001-Open_command008
|
sl@0
|
3901 |
COMMAND !Error=-21 file SetModified PBASE-F32-File-PublicApi-3101-001-SetModified_command009
|
sl@0
|
3902 |
COMMAND file Close
|
sl@0
|
3903 |
COMMAND file ~
|
sl@0
|
3904 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-3101-001-Delete_command013
|
sl@0
|
3905 |
COMMAND RFs1 ~
|
sl@0
|
3906 |
END_TEST_BLOCK
|
sl@0
|
3907 |
END_TESTCASE PBASE-F32-File-PublicApi-3101
|
sl@0
|
3908 |
|
sl@0
|
3909 |
|
sl@0
|
3910 |
//
|
sl@0
|
3911 |
// ChangeMode
|
sl@0
|
3912 |
//
|
sl@0
|
3913 |
|
sl@0
|
3914 |
|
sl@0
|
3915 |
START_TESTCASE PBASE-F32-File-PublicApi-5501
|
sl@0
|
3916 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-5501
|
sl@0
|
3917 |
//! @SYMAPI RFile
|
sl@0
|
3918 |
//! @SYMTestCaseDesc Function ChangeMode() neg. test - call ChangeMode with value outside of set (EFileShareExclusive, EFileShareReadersOnly).
|
sl@0
|
3919 |
//! Uses API elements: SetModified().
|
sl@0
|
3920 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
3921 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc5501.txt", EFileShareExclusive.
|
sl@0
|
3922 |
//! 3. Write "test" to file.
|
sl@0
|
3923 |
//! 4. Call RFile::ChangeMode() passing it EFileWrite.
|
sl@0
|
3924 |
//! 5. Close RFile.
|
sl@0
|
3925 |
//! 6. Delete file.
|
sl@0
|
3926 |
//! 7. Close RFs.
|
sl@0
|
3927 |
//!
|
sl@0
|
3928 |
//! @SYMTestStatus Implemented
|
sl@0
|
3929 |
//! @SYMTestPriority Critical
|
sl@0
|
3930 |
//! @SYMTestExpectedResults RFile::ChangeMode() returns KErrArgument.
|
sl@0
|
3931 |
//!
|
sl@0
|
3932 |
//! @SYMTestType CIT
|
sl@0
|
3933 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3934 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3935 |
CREATE_OBJECT RFile file
|
sl@0
|
3936 |
COMMAND RFs1 new
|
sl@0
|
3937 |
COMMAND RFs1 Connect
|
sl@0
|
3938 |
COMMAND file new
|
sl@0
|
3939 |
COMMAND file Replace PBASE-F32-File-PublicApi-5501-001-Replace_command005
|
sl@0
|
3940 |
COMMAND file Write PBASE-F32-File-PublicApi-5501-001-Write_command006
|
sl@0
|
3941 |
COMMAND !Error=-6 file ChangeMode PBASE-F32-File-PublicApi-5501-001-ChangeMode_command007
|
sl@0
|
3942 |
COMMAND file Close
|
sl@0
|
3943 |
COMMAND file ~
|
sl@0
|
3944 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-5501-001-Delete_command011
|
sl@0
|
3945 |
COMMAND RFs1 ~
|
sl@0
|
3946 |
END_TEST_BLOCK
|
sl@0
|
3947 |
END_TESTCASE PBASE-F32-File-PublicApi-5501
|
sl@0
|
3948 |
|
sl@0
|
3949 |
//
|
sl@0
|
3950 |
// Set
|
sl@0
|
3951 |
//
|
sl@0
|
3952 |
|
sl@0
|
3953 |
|
sl@0
|
3954 |
START_TESTCASE PBASE-F32-File-PublicApi-3201
|
sl@0
|
3955 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-3201
|
sl@0
|
3956 |
//! @SYMAPI RFile
|
sl@0
|
3957 |
//! @SYMTestCaseDesc Function Set() neg. test - try to clear and set the same attribute.
|
sl@0
|
3958 |
//! Uses API elements: Set(), Modified(), Att().
|
sl@0
|
3959 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
3960 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc3201.txt", EFileShareAny.
|
sl@0
|
3961 |
//! 3. Call RFile::Set() passing it 20070118:, KEntryAttReadOnly, KEntryAttReadOnly.
|
sl@0
|
3962 |
//! 4. Close file
|
sl@0
|
3963 |
//! 5. Delete file.
|
sl@0
|
3964 |
//! 6. Close Fs session
|
sl@0
|
3965 |
//!
|
sl@0
|
3966 |
//! @SYMTestStatus Implemented
|
sl@0
|
3967 |
//! @SYMTestPriority Critical
|
sl@0
|
3968 |
//! @SYMTestExpectedResults Panic - FSCLIENT:21.
|
sl@0
|
3969 |
//!
|
sl@0
|
3970 |
//! @SYMTestType CIT
|
sl@0
|
3971 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3972 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3973 |
CREATE_OBJECT RFile file
|
sl@0
|
3974 |
COMMAND RFs1 new
|
sl@0
|
3975 |
COMMAND RFs1 Connect
|
sl@0
|
3976 |
COMMAND file new
|
sl@0
|
3977 |
COMMAND file Replace PBASE-F32-File-PublicApi-3201-001-Replace_command005
|
sl@0
|
3978 |
COMMAND file Write PBASE-F32-File-PublicApi-3201-001-Write_command006
|
sl@0
|
3979 |
COMMAND file Set PBASE-F32-File-PublicApi-3201-001-Set_command007
|
sl@0
|
3980 |
COMMAND file Close
|
sl@0
|
3981 |
COMMAND file ~
|
sl@0
|
3982 |
COMMAND RFs1 ~
|
sl@0
|
3983 |
END_TEST_BLOCK !PanicCode=21 !PanicString="FSCLIENT panic"
|
sl@0
|
3984 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
3985 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
3986 |
COMMAND RFs1 new
|
sl@0
|
3987 |
COMMAND RFs1 Connect
|
sl@0
|
3988 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-3201-001-Delete_command011
|
sl@0
|
3989 |
COMMAND RFs1 ~
|
sl@0
|
3990 |
END_TEST_BLOCK
|
sl@0
|
3991 |
END_TESTCASE PBASE-F32-File-PublicApi-3201
|
sl@0
|
3992 |
|
sl@0
|
3993 |
|
sl@0
|
3994 |
|
sl@0
|
3995 |
//
|
sl@0
|
3996 |
// Rename
|
sl@0
|
3997 |
//
|
sl@0
|
3998 |
|
sl@0
|
3999 |
|
sl@0
|
4000 |
START_TESTCASE PBASE-F32-File-PublicApi-3401
|
sl@0
|
4001 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-3401
|
sl@0
|
4002 |
//! @SYMAPI RFile
|
sl@0
|
4003 |
//! @SYMTestCaseDesc Function Rename() neg. test - open file in read mode and try to rename it.
|
sl@0
|
4004 |
//! Uses API elements: RFile::Rename().
|
sl@0
|
4005 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
4006 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc3401.txt", EFileRead.
|
sl@0
|
4007 |
//! 3. Write "test" to file.
|
sl@0
|
4008 |
//! 4. Call RFile::Rename() passing it string literal "test_renamed.txt".
|
sl@0
|
4009 |
//! 5. Close RFile.
|
sl@0
|
4010 |
//! 6. Delete file.
|
sl@0
|
4011 |
//! 7. Close RFs.
|
sl@0
|
4012 |
//!
|
sl@0
|
4013 |
//! @SYMTestStatus Implemented
|
sl@0
|
4014 |
//! @SYMTestPriority Critical
|
sl@0
|
4015 |
//! @SYMTestExpectedResults RFile::Rename() returns KErrAccessDenied.
|
sl@0
|
4016 |
//!
|
sl@0
|
4017 |
//! @SYMTestType CIT
|
sl@0
|
4018 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
4019 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
4020 |
CREATE_OBJECT RFile file
|
sl@0
|
4021 |
COMMAND RFs1 new
|
sl@0
|
4022 |
COMMAND RFs1 Connect
|
sl@0
|
4023 |
COMMAND file new
|
sl@0
|
4024 |
COMMAND file Replace PBASE-F32-File-PublicApi-3401-001-Replace_command005
|
sl@0
|
4025 |
COMMAND file Write PBASE-F32-File-PublicApi-3401-001-Write_command006
|
sl@0
|
4026 |
COMMAND file Close
|
sl@0
|
4027 |
COMMAND file Open PBASE-F32-File-PublicApi-3401-001-Open_command008
|
sl@0
|
4028 |
COMMAND !Error=-21 file Rename PBASE-F32-File-PublicApi-3401-001-Rename_command009
|
sl@0
|
4029 |
COMMAND file Close
|
sl@0
|
4030 |
COMMAND file ~
|
sl@0
|
4031 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-3401-001-Delete_command12
|
sl@0
|
4032 |
COMMAND RFs1 ~
|
sl@0
|
4033 |
END_TEST_BLOCK
|
sl@0
|
4034 |
|
sl@0
|
4035 |
END_TESTCASE PBASE-F32-File-PublicApi-3401
|
sl@0
|
4036 |
|
sl@0
|
4037 |
|
sl@0
|
4038 |
|
sl@0
|
4039 |
START_TESTCASE PBASE-F32-File-PublicApi-3402
|
sl@0
|
4040 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-3402
|
sl@0
|
4041 |
//! @SYMAPI RFile
|
sl@0
|
4042 |
//! @SYMTestCaseDesc Function BlockMap() negative test, replace a file and then call BlockMap on it.
|
sl@0
|
4043 |
//! Uses API elements: Open(), BlockMap().
|
sl@0
|
4044 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
4045 |
//! 2. Call RFile::Replace() passing RFs, literal "{Drives, RAMDriveTestPath}file\tc3402.txt", EFileRead.
|
sl@0
|
4046 |
//! 4. Call RFile::BlockMap().
|
sl@0
|
4047 |
//! 5. Close RFile.
|
sl@0
|
4048 |
//! 6. Delete file.
|
sl@0
|
4049 |
//! 7. Close RFs.
|
sl@0
|
4050 |
//!
|
sl@0
|
4051 |
//! @SYMTestStatus Implemented
|
sl@0
|
4052 |
//! @SYMTestPriority Critical
|
sl@0
|
4053 |
//! @SYMTestExpectedResults BlockMap returns KErrNotSupported.
|
sl@0
|
4054 |
//!
|
sl@0
|
4055 |
//! @SYMTestType CIT
|
sl@0
|
4056 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
4057 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
4058 |
CREATE_OBJECT RFile file
|
sl@0
|
4059 |
COMMAND RFs1 new
|
sl@0
|
4060 |
COMMAND RFs1 Connect
|
sl@0
|
4061 |
COMMAND file new
|
sl@0
|
4062 |
COMMAND file Replace PBASE-F32-File-PublicApi-3402-001-Replace_command003
|
sl@0
|
4063 |
COMMAND !Error=-5 file BlockMap
|
sl@0
|
4064 |
COMMAND file Close
|
sl@0
|
4065 |
COMMAND file ~
|
sl@0
|
4066 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-3402-001-Delete_command007
|
sl@0
|
4067 |
COMMAND RFs1 ~
|
sl@0
|
4068 |
END_TEST_BLOCK
|
sl@0
|
4069 |
END_TESTCASE PBASE-F32-File-PublicApi-3402
|
sl@0
|
4070 |
|
sl@0
|
4071 |
|
sl@0
|
4072 |
START_TESTCASE PBASE-F32-File-PublicApi-3403
|
sl@0
|
4073 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-3403
|
sl@0
|
4074 |
//! @SYMAPI RFile
|
sl@0
|
4075 |
//! @SYMTestCaseDesc Function BlockMap() negative test. Call BlockMap with Usage ETestDebug
|
sl@0
|
4076 |
//! Uses API elements: Open(), BlockMap().
|
sl@0
|
4077 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
4078 |
//! 2. Call RFile::Replace() to create file tc3403 with EFileWrite
|
sl@0
|
4079 |
//! 4. Call RFile::BlockMap() passing ETestDebug for usage, 0 for startPos.
|
sl@0
|
4080 |
//! 5. Close RFile.
|
sl@0
|
4081 |
//! 6. Delete file.
|
sl@0
|
4082 |
//! 7. Close RFs.
|
sl@0
|
4083 |
//!
|
sl@0
|
4084 |
//! @SYMTestStatus Implemented
|
sl@0
|
4085 |
//! @SYMTestPriority Critical
|
sl@0
|
4086 |
//! @SYMTestExpectedResults BlockMap returns KErrNotSupported.
|
sl@0
|
4087 |
//!
|
sl@0
|
4088 |
//! @SYMTestType CIT
|
sl@0
|
4089 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
4090 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
4091 |
CREATE_OBJECT RFile file
|
sl@0
|
4092 |
COMMAND RFs1 new
|
sl@0
|
4093 |
COMMAND RFs1 Connect
|
sl@0
|
4094 |
COMMAND file new
|
sl@0
|
4095 |
COMMAND file Replace PBASE-F32-File-PublicApi-3403-001-Replace_command003
|
sl@0
|
4096 |
COMMAND !Error=-5 file BlockMap PBASE-F32-File-PublicApi-3403-001-BlockMap_command004
|
sl@0
|
4097 |
COMMAND file Close
|
sl@0
|
4098 |
COMMAND file ~
|
sl@0
|
4099 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-3403-001-Delete_command007
|
sl@0
|
4100 |
COMMAND RFs1 ~
|
sl@0
|
4101 |
END_TEST_BLOCK
|
sl@0
|
4102 |
END_TESTCASE PBASE-F32-File-PublicApi-3403
|
sl@0
|
4103 |
|
sl@0
|
4104 |
|
sl@0
|
4105 |
START_TESTCASE PBASE-F32-File-PublicApi-3501
|
sl@0
|
4106 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-3501
|
sl@0
|
4107 |
//! @SYMAPI RFile
|
sl@0
|
4108 |
//! @SYMTestCaseDesc Asynchronous Read(TDes8 &aDes, TInt aLength, TRequestStatus &aStatus) test. Pass 0 for length.
|
sl@0
|
4109 |
//! Uses API elements: Read().
|
sl@0
|
4110 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
4111 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc3501.txt", EFileWrite.
|
sl@0
|
4112 |
//! 3. Call RFile::Write passing literal "Asynchronous read with length test"
|
sl@0
|
4113 |
//! 4. Reset file position
|
sl@0
|
4114 |
//! 4. Create TRequestStatus variable.
|
sl@0
|
4115 |
//! 5. Call RFile::Read() passing TRequestStatus and 0 for length.
|
sl@0
|
4116 |
//! 6. Wait until asynchronous call completes
|
sl@0
|
4117 |
//! 7. Close RFile.
|
sl@0
|
4118 |
//! 8. Delete file.
|
sl@0
|
4119 |
//! 9. Close RFs.
|
sl@0
|
4120 |
//!
|
sl@0
|
4121 |
//! @SYMTestStatus Implemented
|
sl@0
|
4122 |
//! @SYMTestPriority Critical
|
sl@0
|
4123 |
//! @SYMTestExpectedResults RFile::Read() returns empty descriptor
|
sl@0
|
4124 |
//!
|
sl@0
|
4125 |
//! @SYMTestType CIT
|
sl@0
|
4126 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
4127 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
4128 |
CREATE_OBJECT RFile file
|
sl@0
|
4129 |
COMMAND RFs1 new
|
sl@0
|
4130 |
COMMAND RFs1 Connect
|
sl@0
|
4131 |
COMMAND file new
|
sl@0
|
4132 |
COMMAND file Replace PBASE-F32-File-PublicApi-3501-001-Replace_command005
|
sl@0
|
4133 |
COMMAND file Write PBASE-F32-File-PublicApi-3501-001-Write_command006
|
sl@0
|
4134 |
COMMAND file Seek PBASE-F32-File-PublicApi-3501-001-Seek_command007
|
sl@0
|
4135 |
COMMAND file Read PBASE-F32-File-PublicApi-3501-001-Read_command008
|
sl@0
|
4136 |
OUTSTANDING
|
sl@0
|
4137 |
COMMAND file Close
|
sl@0
|
4138 |
COMMAND file ~
|
sl@0
|
4139 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-3501-001-Delete_command012
|
sl@0
|
4140 |
COMMAND RFs1 ~
|
sl@0
|
4141 |
END_TEST_BLOCK
|
sl@0
|
4142 |
END_TESTCASE PBASE-F32-File-PublicApi-3501
|
sl@0
|
4143 |
|
sl@0
|
4144 |
|
sl@0
|
4145 |
START_TESTCASE PBASE-F32-File-PublicApi-3502
|
sl@0
|
4146 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-3502
|
sl@0
|
4147 |
//! @SYMAPI RFile
|
sl@0
|
4148 |
//! @SYMTestCaseDesc Synchronous Read(TInt aPos, TDes8 &aDes, TInt aLength) test. Pass 0 for length.
|
sl@0
|
4149 |
//! Uses API elements: Read().
|
sl@0
|
4150 |
//! @SYMTestActions 1. Create RFs session
|
sl@0
|
4151 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc3502.txt", EFileWrite
|
sl@0
|
4152 |
//! 3. Write "synchronous read with length and position test" to file
|
sl@0
|
4153 |
//! 4. Reset file position.
|
sl@0
|
4154 |
//! 5. Call RFile::Read() passing 0 for length and 5 for position.
|
sl@0
|
4155 |
//! 6. Close RFile.
|
sl@0
|
4156 |
//! 7. Delete file.
|
sl@0
|
4157 |
//! 8. Close RFs.
|
sl@0
|
4158 |
//!
|
sl@0
|
4159 |
//! @SYMTestStatus Implemented
|
sl@0
|
4160 |
//! @SYMTestPriority Critical
|
sl@0
|
4161 |
//! @SYMTestExpectedResults RFile::Read() returns empty descriptor
|
sl@0
|
4162 |
//!
|
sl@0
|
4163 |
//! @SYMTestType CIT
|
sl@0
|
4164 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
4165 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
4166 |
CREATE_OBJECT RFile file
|
sl@0
|
4167 |
COMMAND RFs1 new
|
sl@0
|
4168 |
COMMAND RFs1 Connect
|
sl@0
|
4169 |
COMMAND file new
|
sl@0
|
4170 |
COMMAND file Replace PBASE-F32-File-PublicApi-3502-001-Replace_command005
|
sl@0
|
4171 |
COMMAND file Write PBASE-F32-File-PublicApi-3502-001-Write_command006
|
sl@0
|
4172 |
COMMAND file Seek PBASE-F32-File-PublicApi-3502-001-Seek_command007
|
sl@0
|
4173 |
COMMAND file Read PBASE-F32-File-PublicApi-3502-001-Read_command008
|
sl@0
|
4174 |
COMMAND file Close
|
sl@0
|
4175 |
COMMAND file ~
|
sl@0
|
4176 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-3502-001-Delete_command012
|
sl@0
|
4177 |
COMMAND RFs1 ~
|
sl@0
|
4178 |
END_TEST_BLOCK
|
sl@0
|
4179 |
END_TESTCASE PBASE-F32-File-PublicApi-3502
|
sl@0
|
4180 |
|
sl@0
|
4181 |
|
sl@0
|
4182 |
START_TESTCASE PBASE-F32-File-PublicApi-3503
|
sl@0
|
4183 |
//! @SYMTestCaseID PBASE-F32-File-PublicApi-3503
|
sl@0
|
4184 |
//! @SYMAPI RFile
|
sl@0
|
4185 |
//! @SYMTestCaseDesc Asynchronous Read(TInt aPos, TDes8 &aDes, TInt aLength, TRequestStatus &aStatus) test. Pass 0 for length.
|
sl@0
|
4186 |
//! Uses API elements: Read().
|
sl@0
|
4187 |
//! @SYMTestActions 1. Create RFs session.
|
sl@0
|
4188 |
//! 2. Call RFile::Replace passing RFs, literal "{Drives, RAMDriveTestPath}file\tc3503.txt", EFileWrite.
|
sl@0
|
4189 |
//! 3. Call RFile::Write passing literal "asynchronous read with length and position test"
|
sl@0
|
4190 |
//! 4. Reset file position
|
sl@0
|
4191 |
//! 5. Call RFile::Read() passing TRequestStatus, 0 for length and 5 for position.
|
sl@0
|
4192 |
//! 6. Wait until asynchronous call completes
|
sl@0
|
4193 |
//! 7. Close RFile.
|
sl@0
|
4194 |
//! 8. Delete file.
|
sl@0
|
4195 |
//! 9. Close RFs.
|
sl@0
|
4196 |
//!
|
sl@0
|
4197 |
//! @SYMTestStatus Implemented
|
sl@0
|
4198 |
//! @SYMTestPriority Critical
|
sl@0
|
4199 |
//! @SYMTestExpectedResults RFile::Read() returns empty descriptor
|
sl@0
|
4200 |
//!
|
sl@0
|
4201 |
//! @SYMTestType CIT
|
sl@0
|
4202 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
4203 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
4204 |
CREATE_OBJECT RFile file
|
sl@0
|
4205 |
COMMAND RFs1 new
|
sl@0
|
4206 |
COMMAND RFs1 Connect
|
sl@0
|
4207 |
COMMAND file new
|
sl@0
|
4208 |
COMMAND file Replace PBASE-F32-File-PublicApi-3503-001-Replace_command005
|
sl@0
|
4209 |
COMMAND file Write PBASE-F32-File-PublicApi-3503-001-Write_command006
|
sl@0
|
4210 |
COMMAND file Seek PBASE-F32-File-PublicApi-3503-001-Seek_command007
|
sl@0
|
4211 |
COMMAND file Read PBASE-F32-File-PublicApi-3503-001-Read_command008
|
sl@0
|
4212 |
OUTSTANDING
|
sl@0
|
4213 |
COMMAND file Close
|
sl@0
|
4214 |
COMMAND file ~
|
sl@0
|
4215 |
COMMAND RFs1 Delete PBASE-F32-File-PublicApi-3503-001-Delete_command011
|
sl@0
|
4216 |
COMMAND RFs1 ~
|
sl@0
|
4217 |
END_TEST_BLOCK
|
sl@0
|
4218 |
END_TESTCASE PBASE-F32-File-PublicApi-3503
|
sl@0
|
4219 |
|
sl@0
|
4220 |
START_TESTCASE PBASE-F32-File-Uninstall
|
sl@0
|
4221 |
//! @SYMTestCaseID PBASE-F32-File-Uninstall
|
sl@0
|
4222 |
//! @SYMAPI RFile
|
sl@0
|
4223 |
//! @SYMTestCaseDesc Cleanup the directories created to test RFile
|
sl@0
|
4224 |
//! @SYMTestActions 1. Create RFs Session.
|
sl@0
|
4225 |
//! 2. Remove the directories created using Rfs::RmDir().
|
sl@0
|
4226 |
//! @SYMTestStatus Implemented
|
sl@0
|
4227 |
//! @SYMTestPriority Critical
|
sl@0
|
4228 |
//! @SYMTestExpectedResults Removes the directory created and keeps the environment clean.
|
sl@0
|
4229 |
//!
|
sl@0
|
4230 |
//! @SYMTestType CIT
|
sl@0
|
4231 |
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-File-PublicApi.ini
|
sl@0
|
4232 |
CREATE_OBJECT RFs RFs1
|
sl@0
|
4233 |
COMMAND RFs1 new
|
sl@0
|
4234 |
COMMAND RFs1 Connect
|
sl@0
|
4235 |
COMMAND RFs1 RmDir PBASE-F32-File-PublicApi-Unistall
|
sl@0
|
4236 |
COMMAND RFs1 ~
|
sl@0
|
4237 |
END_TEST_BLOCK
|
sl@0
|
4238 |
END_TESTCASE PBASE-F32-File-Uninstall
|