baseapitest/basesvs/validation/f32/sfsrv/scripts/PBASE-F32-RDir-PublicApi-RAM.script
Fix for bug 2283 (RVCT 4.0 support is missing from PDK 3.0.h)
Have multiple extension sections in the bld.inf, one for each version
of the compiler. The RVCT version building the tools will build the
runtime libraries for its version, but make sure we extract all the other
versions from zip archives. Also add the archive for RVCT4.
//
// Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
// All rights reserved.
// This component and the accompanying materials are made available
// under the terms of "Eclipse Public License v1.0"
// which accompanies this distribution, and is available
// at the URL "http://www.eclipse.org/legal/epl-v10.html".
//
// Initial Contributors:
// Nokia Corporation - initial contribution.
//
// Contributors:
//
// Description:
//
//! @file
//! @SYMTestSuiteName pbase-f32-sfsrv-publicapi-ram
//! @SYMScriptTestEnvironment This test script requires a basic ROM.
//! @SYMScriptAuthor Jaanus Randveer, Runno Sgirka
//! @SYMScriptCreationDate 31/08/2007
//! @SYMScriptDescription The test script contains API tests for the following functions of RDir class:
//! TInt Open(RFs &aFs, const TDesC &aMatchName, const TUidType &aUidType)
//! TInt Open(RFs &aFs, const TDesC &aMatchName, TUint anAttMask)
//! void Close()
//! TInt Read(TEntryArray &anArray)
//! void Read(TEntryArray &anArray, TRequestStatus &aStatus)
//! TInt Read(TEntry &anEntry)
//! void Read(TPckg< TEntry > &anEntry, TRequestStatus &aStatus)
LOAD_SUITE T_SfSrv
DELAY 5000
START_TESTCASE PBASE-F32-RDir-CopyFiles
//! @SYMTestCaseID PBASE-F32-RDir-CopyFiles
//! @SYMAPI CFileMan
//! @SYMTestCaseDesc SetupTestCase to test RDir Apis
//! @SYMTestActions 1.Call Create a RFs session and call it's Connect() function.
//! 2. Use CFileMan to copy the files on to relavent directories.
//! @SYMTestStatus Implemented
//! @SYMTestPriority Critical
//! @SYMTestExpectedResults The CFileMan::Copy() copies the testdata files properly on to specific directories.
//! @SYMTestType CIT
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-RDir-PublicApi.ini
CREATE_OBJECT RFs RFs1
CREATE_OBJECT CFileMan CFileMan1
COMMAND RFs1 new
COMMAND RFs1 Connect
COMMAND CFileMan1 NewL PBASE-F32-RDir-PublicApi-NewL
COMMAND RFs1 MkDirAll PBASE-F32-RDir-PublicApi-001-RamDiskPath
COMMAND CFileMan1 Copy PBASE-F32-RDir-PublicApi-001-Copy_Any
COMMAND CFileMan1 Copy PBASE-F32-RDir-PublicApi-001-Copy_Bigline
COMMAND CFileMan1 Copy PBASE-F32-RDir-PublicApi-001-Copy_FtEof
COMMAND CFileMan1 Copy PBASE-F32-RDir-PublicApi-001-Copy_FtRead
COMMAND CFileMan1 Copy PBASE-F32-RDir-PublicApi-001-Copy_MLine
COMMAND CFileMan1 Copy PBASE-F32-RDir-PublicApi-001-Copy_NewFile
COMMAND CFileMan1 Copy PBASE-F32-RDir-PublicApi-001-Copy_Oneliner
COMMAND CFileMan1 Copy PBASE-F32-RDir-PublicApi-001-Copy_Test1
COMMAND CFileMan1 Copy PBASE-F32-RDir-PublicApi-001-Copy_Test2
COMMAND CFileMan1 Copy PBASE-F32-RDir-PublicApi-001-Copy_Test3
COMMAND CFileMan1 Copy PBASE-F32-RDir-PublicApi-001-Copy_Test
COMMAND CFileMan1 ~
COMMAND RFs1 ~
END_TEST_BLOCK
END_TESTCASE PBASE-F32-RDir-CopyFiles
START_TESTCASE PBASE-F32-RDir-PublicApi-5001
//! @SYMTestCaseID PBASE-F32-RDir-PublicApi-5001
//! @SYMAPI RDir
//! @SYMTestCaseDesc Function Open(RFs &aFs, const TDesC &aMatchName, const TUidType &aUidType) and
//! function Close() test, that opens a directory using the NULL UIDs.
//! Uses API elements: Open(), Close().
//! @SYMTestActions 1.Call Create a RFs session and call it's Connect() function.
//! 2.Call RDir::Open(RFs &aFs, const TDesC &aMatchName, const TUidType &aUidType),
//! and RFs session as first parameter, and <DRIVE>:\base\t_sfsrv\ as second parameter,
//! and empty TUidType as third parameter.
//! 3.Call RDir::Close().
//! @SYMTestStatus Implemented
//! @SYMTestPriority Critical
//! @SYMTestExpectedResults The Open() method call is completed returning KErrNone.
//! @SYMTestType CIT
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-RDir-PublicApi.ini
CREATE_OBJECT RFs RFs1
CREATE_OBJECT RDir RDir1
COMMAND RFs1 new
COMMAND RFs1 Connect
COMMAND RDir1 new
COMMAND RDir1 Open PBASE-F32-RDir-PublicApi-5001-001-Open_command005
COMMAND RDir1 Close
COMMAND RDir1 ~
COMMAND RFs1 ~
END_TEST_BLOCK
END_TESTCASE PBASE-F32-RDir-PublicApi-5001
START_TESTCASE PBASE-F32-RDir-PublicApi-5002
//! @SYMTestCaseID PBASE-F32-RDir-PublicApi-5002
//! @SYMAPI RDir
//! @SYMTestCaseDesc Function Open(RFs &aFs, const TDesC &aMatchName, TUint anAttMask) test, that opens a directory using
//! an attribute bitmask to filter the directory entry types.
//! Uses API elements: Open(), Close().
//! @SYMTestActions 1.Call Create a RFs session and call it's Connect() function.
//! 2.Call RDir::Open(RFs &aFs, const TDesC &aMatchName, TUint anAttMask),
//! and RFs session as first parameter, and <DRIVE>:\base\t_sfsrv\ as second parameter,
//! and KEntryAttNormal as third parameter.
//! 3.Call RDir::Close().
//! @SYMTestStatus Implemented
//! @SYMTestPriority Critical
//! @SYMTestExpectedResults The Open() method call is completed returning KErrNone.
//! @SYMTestType CIT
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-RDir-PublicApi.ini
CREATE_OBJECT RFs RFs1
CREATE_OBJECT RDir RDir1
COMMAND RFs1 new
COMMAND RFs1 Connect
COMMAND RDir1 new
COMMAND RDir1 Open PBASE-F32-RDir-PublicApi-5002-001-Open_command005
COMMAND RDir1 Close
COMMAND RDir1 ~
COMMAND RFs1 ~
END_TEST_BLOCK
END_TESTCASE PBASE-F32-RDir-PublicApi-5002
START_TESTCASE PBASE-F32-RDir-PublicApi-5003
//! @SYMTestCaseID PBASE-F32-RDir-PublicApi-5003
//! @SYMAPI RDir
//! @SYMTestCaseDesc Function Read(TEntryArray &anArray) test, that reads all filtered directory entries into the
//! specified array synchronously.
//! Uses API elements: Open(), Read(), Close().
//! @SYMTestActions 1.Call Create a RFs session and call it's Connect() function.
//! 2.Call RDir::Open(RFs &aFs, const TDesC &aMatchName, TUint anAttMask),
//! and RFs session as first parameter, and <DRIVE>:\base\t_sfsrv\ (containing 14 files: 1mb,
//! any.txt, big_line.txt, filetext_eof.txt, filetext_read.txt, multiline.txt, new_file.txt,
//! oneliner_tmp.txt, test_rom.txt, test.txt, Test1.txt, Test2.txt,
//! Test3.txt, USBLOAD.ZIP) as second parameter, and KEntryAttNormal
//! as third parameter.
//! 3.Call RDir::Read(TEntryArray &anArray) to read all filtered directory entries into the
//! specified array synchronously.
//! 4.Call RDir::Close().
//! @SYMTestStatus Implemented
//! @SYMTestPriority Critical
//! @SYMTestExpectedResults The Read() method call is completed returning KErrEof.
//! @SYMTestType CIT
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-RDir-PublicApi.ini
CREATE_OBJECT RFs RFs1
CREATE_OBJECT RDir RDir1
CREATE_OBJECT TEntryArray TEntryArray1
CREATE_OBJECT TEntry TEntry1
COMMAND RFs1 new
COMMAND RFs1 Connect
COMMAND TEntryArray1 new
COMMAND RDir1 new
COMMAND RDir1 Open PBASE-F32-RDir-PublicApi-5003-001-Open_command005
COMMAND !Error=-25 RDir1 Read PBASE-F32-RDir-PublicApi-5003-001-Read_command006
COMMAND RDir1 Close
COMMAND TEntry1 ~
COMMAND TEntryArray1 ~
COMMAND RDir1 ~
COMMAND RFs1 ~
END_TEST_BLOCK
END_TESTCASE PBASE-F32-RDir-PublicApi-5003
START_TESTCASE PBASE-F32-RDir-PublicApi-5004
//! @SYMTestCaseID PBASE-F32-RDir-PublicApi-5004
//! @SYMAPI RDir
//! @SYMTestCaseDesc Function Read(TEntryArray &anArray, TRequestStatus &aStatus) test, that reads all filtered directory
//! entries into the specified array asynchronously.
//! Uses API elements: Open(), Read(), Close().
//! @SYMTestActions 1.Call Create a RFs session and call it's Connect() function.
//! 2.Call RDir::Open(RFs &aFs, const TDesC &aMatchName, TUint anAttMask),
//! and RFs session as first parameter, and <DRIVE>:\base\t_sfsrv\ (containing 14 files: 1mb,
//! any.txt, big_line.txt, filetext_eof.txt, filetext_read.txt, multiline.txt, new_file.txt,
//! oneliner_tmp.txt, test_rom.txt, test.txt, Test1.txt, Test2.txt,
//! Test3.txt, USBLOAD.ZIP) as second parameter, and KEntryAttNormal
//! as third parameter.
//! 3.Call RDir::Read(TEntryArray &anArray, TRequestStatus &aStatus) to read all filtered directory
//! entries into the specified array asynchronously.
//! 4.Call RDir::Close().
//! @SYMTestStatus Implemented
//! @SYMTestPriority Critical
//! @SYMTestExpectedResults The Read() method call is completed returning KErrEof.
//! @SYMTestType CIT
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-RDir-PublicApi.ini
CREATE_OBJECT RFs RFs1
CREATE_OBJECT RDir RDir1
CREATE_OBJECT TEntryArray TEntryArray1
CREATE_OBJECT TEntry TEntry1
COMMAND RFs1 new
COMMAND RFs1 Connect
COMMAND TEntryArray1 new
COMMAND RDir1 new
COMMAND RDir1 Open PBASE-F32-RDir-PublicApi-5004-001-Open_command005
COMMAND !AsyncError=-25 RDir1 Read PBASE-F32-RDir-PublicApi-5004-001-Read_command006
OUTSTANDING
COMMAND RDir1 Close
COMMAND TEntry1 ~
COMMAND TEntryArray1 ~
COMMAND RDir1 ~
COMMAND RFs1 ~
END_TEST_BLOCK
END_TESTCASE PBASE-F32-RDir-PublicApi-5004
START_TESTCASE PBASE-F32-RDir-PublicApi-5007
//! @SYMTestCaseID PBASE-F32-RDir-PublicApi-5007
//! @SYMAPI RDir
//! @SYMTestCaseDesc Function Read(TEntry &anEntry) test, that calls multiple iterations of Read() and checks the values returned.
//! Uses API elements: Open(), Read(), Close().
//! @SYMTestActions 1.Call Create a RFs session and call it's Connect() function.
//! 2.Call RDir::Open(RFs &aFs, const TDesC &aMatchName, TUint anAttMask),
//! and RFs session as first parameter, and <DRIVE>:\base\t_sfsrv\ (containing 14 files: 1mb,
//! any.txt, big_line.txt, filetext_eof.txt, filetext_read.txt, multiline.txt, new_file.txt,
//! oneliner_tmp.txt, test_rom.txt, test.txt, Test1.txt, Test2.txt,
//! Test3.txt, USBLOAD.ZIP) as second parameter, and KEntryAttNormal
//! as third parameter.
//! 3.Call multiple RDir::Read(TEntry &anEntry) methods to read the contents of the entire directory.
//! 4.Call RDir::Close().
//! @SYMTestStatus Implemented
//! @SYMTestPriority Critical
//! @SYMTestExpectedResults The first six Read() method calls are completed returning KErrNone, the last returns error -25 (KErrEof) as there
//! are no more entries. All verifications with expected values pass.
//! @SYMTestType CIT
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-RDir-PublicApi.ini
CREATE_OBJECT RFs RFs1
CREATE_OBJECT RDir RDir1
CREATE_OBJECT TEntry TEntry1
COMMAND RFs1 new
COMMAND RFs1 Connect
COMMAND RDir1 new
COMMAND RDir1 Open PBASE-F32-RDir-PublicApi-5007-001-Open_command005
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-5007-001-Read_command006
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_sync
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_sync
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_sync
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_sync
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_sync
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_sync
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_sync
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_sync
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_sync
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_sync
COMMAND !Error=-25 RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_sync
COMMAND RDir1 Close
COMMAND TEntry1 ~
COMMAND RDir1 ~
COMMAND RFs1 ~
END_TEST_BLOCK
END_TESTCASE PBASE-F32-RDir-PublicApi-5007
START_TESTCASE PBASE-F32-RDir-PublicApi-5008
//! @SYMTestCaseID PBASE-F32-RDir-PublicApi-5008
//! @SYMAPI RDir
//! @SYMTestCaseDesc Function Read(TPckg<TEntry> &anEntry, TRequestStatus &aStatus) test, that calls multiple iterations of Read() and
//! checks the values returned.
//! Uses API elements: Open(), Read(), Close().
//! @SYMTestActions 1.Call Create a RFs session and call it's Connect() function.
//! 2.Call RDir::Open(RFs &aFs, const TDesC &aMatchName, TUint anAttMask),
//! and RFs session as first parameter, and <DRIVE>:\base\t_sfsrv\ (containing 14 files: 1mb,
//! any.txt, big_line.txt, filetext_eof.txt, filetext_read.txt, multiline.txt, new_file.txt,
//! oneliner_tmp.txt, test_rom.txt, test.txt, Test1.txt, Test2.txt,
//! Test3.txt, USBLOAD.ZIP) as second parameter, and KEntryAttNormal
//! as third parameter.
//! 3.Call multiple RDir::Read(TPckg<TEntry> &anEntry, TRequestStatus &aStatus) methods to read the contents of the
//! entire directory asynchronously.
//! 4.Call RDir::Close().
//! @SYMTestStatus Implemented
//! @SYMTestPriority Critical
//! @SYMTestExpectedResults The first six Read() method calls are completed returning KErrNone, the last returns error -25 (KErrEof) as there
//! are no more entries. All verifications with expected values pass.
//! @SYMTestType CIT
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-RDir-PublicApi.ini
CREATE_OBJECT RFs RFs1
CREATE_OBJECT RDir RDir1
CREATE_OBJECT TEntry TEntry1
COMMAND RFs1 new
COMMAND RFs1 Connect
COMMAND RDir1 new
COMMAND RDir1 Open PBASE-F32-RDir-PublicApi-5008-001-Open_command005
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-5008-001-Read_command006
OUTSTANDING
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_async
OUTSTANDING
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_async
OUTSTANDING
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_async
OUTSTANDING
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_async
OUTSTANDING
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_async
OUTSTANDING
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_async
OUTSTANDING
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_async
OUTSTANDING
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_async
OUTSTANDING
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_async
OUTSTANDING
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_async
OUTSTANDING
COMMAND !AsyncError=-25 RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_async
OUTSTANDING
COMMAND RDir1 Close
COMMAND TEntry1 ~
COMMAND RDir1 ~
COMMAND RFs1 ~
END_TEST_BLOCK
END_TESTCASE PBASE-F32-RDir-PublicApi-5008
START_TESTCASE PBASE-F32-RDir-PublicApi-5009
//! @SYMTestCaseID PBASE-F32-RDir-PublicApi-5009
//! @SYMAPI RDir
//! @SYMTestCaseDesc Function Open(RFs &aFs, const TDesC &aMatchName, TUint anAttMask) test, that checks that Open() makes it
//! possible to filter entries by attributes.
//! Uses API elements: Open(), Read(), Close().
//! @SYMTestActions 1.Call Create a RFs session and call it's Connect() function.
//! 2.Call RFs::setAtt, to set some attributes of the files in <DRIVE>:\base\t_sfsrv\.
//! 3.Call RDir::Open(RFs &aFs, const TDesC &aMatchName, TUint anAttMask),
//! and RFs session as first parameter, and <DRIVE>:\base\t_sfsrv\ (containing 14 files: 1mb,
//! any.txt, big_line.txt, filetext_eof.txt, filetext_read.txt, multiline.txt, new_file.txt,
//! oneliner_tmp.txt, test_rom.txt, test.txt, Test1.txt, Test2.txt,
//! Test3.txt, USBLOAD.ZIP) as second parameter, and
//! KEntryAttReadOnly|KEntryAttMatchExclusive as third parameter.
//! 4.Call multiple RDir::Read(TEntry &anEntry) methods to read the contents of the entire directory.
//! 5.Set previously set attributes back to normal.
//! 6.Call RDir::Close().
//! @SYMTestStatus Implemented
//! @SYMTestPriority Critical
//! @SYMTestExpectedResults The first two Read() method calls are completed returning KErrNone, the last returns error -25 (KErrEof) as there
//! are no more entries (only two read-only files - Test2.txt and USBLOAD.ZIP). All verifications with expected values
//! pass.
//! @SYMTestType CIT
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-RDir-PublicApi.ini
CREATE_OBJECT RFs RFs1
CREATE_OBJECT RDir RDir1
CREATE_OBJECT TEntry TEntry1
COMMAND RFs1 new
COMMAND RFs1 Connect
COMMAND RFs1 SetAtt PBASE-F32-RDir-PublicApi-5009-001-SetAtt_command005
COMMAND RFs1 SetAtt PBASE-F32-RDir-PublicApi-5009-001-SetAtt_command006
COMMAND RFs1 SetAtt PBASE-F32-RDir-PublicApi-5009-001-SetAtt_command008
COMMAND RFs1 SetAtt PBASE-F32-RDir-PublicApi-5009-001-SetAtt_command009
COMMAND RFs1 SetAtt PBASE-F32-RDir-PublicApi-5009-001-SetAtt_command010
COMMAND RFs1 SetAtt PBASE-F32-RDir-PublicApi-5009-001-SetAtt_command011
COMMAND RFs1 SetAtt PBASE-F32-RDir-PublicApi-5009-001-SetAtt_command012
COMMAND RFs1 SetAtt PBASE-F32-RDir-PublicApi-5009-001-SetAtt_command013
COMMAND RFs1 SetAtt PBASE-F32-RDir-PublicApi-5009-001-SetAtt_command014
COMMAND RFs1 SetAtt PBASE-F32-RDir-PublicApi-5009-001-SetAtt_command016
COMMAND RFs1 SetAtt PBASE-F32-RDir-PublicApi-5009-001-SetAtt_command020
COMMAND RFs1 SetAtt PBASE-F32-RDir-PublicApi-5009-001-SetAtt_command021
COMMAND RFs1 SetAtt PBASE-F32-RDir-PublicApi-5009-001-SetAtt_command015
COMMAND RDir1 new
COMMAND RDir1 Open PBASE-F32-RDir-PublicApi-5009-001-Open_command013
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-5009-001-Read_command014
COMMAND TEntry1 = PBASE-F32-RDir-PublicApi-global-001-assign_Test1
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-5009-001-Read_command015
COMMAND TEntry1 = PBASE-F32-RDir-PublicApi-global-001-assign_Test3
COMMAND !Error=-25 RDir1 Read PBASE-F32-RDir-PublicApi-5009-001-Read_command016
COMMAND TEntry1 = PBASE-F32-RDir-PublicApi-global-001-assign_EOF
COMMAND RFs1 SetAtt PBASE-F32-RDir-PublicApi-5009-001-SetAtt_command017
COMMAND RFs1 SetAtt PBASE-F32-RDir-PublicApi-5009-001-SetAtt_command019
COMMAND RDir1 Close
COMMAND TEntry1 ~
COMMAND RDir1 ~
COMMAND RFs1 ~
END_TEST_BLOCK
END_TESTCASE PBASE-F32-RDir-PublicApi-5009
START_TESTCASE PBASE-F32-RDir-PublicApi-5010
//! @SYMTestCaseID PBASE-F32-RDir-PublicApi-5010
//! @SYMAPI RDir
//! @SYMTestCaseDesc Function Open(RFs &aFs, const TDesC &aMatchName, const TUidType &aUidType) test, that checks that Open() works fine
//! with * wildcard.
//! Uses API elements: Open(), Read(), Close().
//! @SYMTestActions 1.Call Create a RFs session and call it's Connect() function.
//! 2.Call RDir::Open(RFs &aFs, const TDesC &aMatchName, const TUidType &aUidType),
//! and RFs session as first parameter, and <DRIVE>:\base\t_sfsrv\ (containing 14 files: 1mb,
//! any.txt, big_line.txt, filetext_eof.txt, filetext_read.txt, multiline.txt, new_file.txt,
//! oneliner_tmp.txt, test_rom.txt, test.txt, Test1.txt, Test2.txt,
//! Test3.txt, USBLOAD.ZIP) as second parameter, and empty TUidType as
//! third parameter.
//! 3.Call RDir::Read(TEntry &anEntry) to read a single directory entry synchronously.
//! 4.Call RDir::Close().
//! @SYMTestStatus Implemented
//! @SYMTestPriority Critical
//! @SYMTestExpectedResults The Open() method call is completed returning KErrNone. The last Read() method call returns KErrEof as there are
//! only 5 *.txt files (test.txt, Test1.txt, Test2.txt, Test3.txt, test_rom.txt). All other verifications pass.
//! @SYMTestType CIT
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-RDir-PublicApi.ini
CREATE_OBJECT RFs RFs1
CREATE_OBJECT RDir RDir1
CREATE_OBJECT TEntry TEntry1
COMMAND RFs1 new
COMMAND RFs1 Connect
COMMAND RDir1 new
COMMAND RDir1 Open PBASE-F32-RDir-PublicApi-5010-001-Open_command005
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-5010-001-Read_command007
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_sync
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_sync
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_sync
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_sync
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_sync
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_sync
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_sync
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_sync
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_sync
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_sync
COMMAND !Error=-25 RDir1 Read PBASE-F32-RDir-PublicApi-global-001-Read_compare_sync
COMMAND RDir1 Close
COMMAND TEntry1 ~
COMMAND RDir1 ~
COMMAND RFs1 ~
END_TEST_BLOCK
END_TESTCASE PBASE-F32-RDir-PublicApi-5010
START_TESTCASE PBASE-F32-RDir-PublicApi-5011
//! @SYMTestCaseID PBASE-F32-RDir-PublicApi-5011
//! @SYMAPI RDir
//! @SYMTestCaseDesc Function Open(RFs &aFs, const TDesC &aMatchName, TUint anAttMask) test, that checks that Open() works fine
//! with ? wildcard.
//! Uses API elements: Open(), Read(), Close().
//! @SYMTestActions 1.Call Create a RFs session and call it's Connect() function.
//! 2.Call RDir::Open(RFs &aFs, const TDesC &aMatchName, TUint anAttMask),
//! and RFs session as first parameter, and <DRIVE>:\base\t_sfsrv\ (containing 14 files: 1mb,
//! any.txt, big_line.txt, filetext_eof.txt, filetext_read.txt, multiline.txt, new_file.txt,
//! oneliner_tmp.txt, test_rom.txt, test.txt, Test1.txt, Test2.txt,
//! Test3.txt, USBLOAD.ZIP) as second parameter, and
//! KEntryAttNormal as third parameter.
//! 3.Call RDir::Read(TEntry &anEntry) to read a single directory entry synchronously.
//! 4.Call RDir::Close().
//! @SYMTestStatus Implemented
//! @SYMTestPriority Critical
//! @SYMTestExpectedResults The Open() method call is completed returning KErrNone. The last Read() method call returns KErrEof as there are
//! only 3 Test?.txt files (Test1.txt, Test2.txt, Test3.txt). All other verifications pass.
//! @SYMTestType CIT
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-RDir-PublicApi.ini
CREATE_OBJECT RFs RFs1
CREATE_OBJECT RDir RDir1
CREATE_OBJECT TEntry TEntry1
COMMAND RFs1 new
COMMAND RFs1 Connect
COMMAND RDir1 new
COMMAND RDir1 Open PBASE-F32-RDir-PublicApi-5011-001-Open_command005
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-5011-001-Read_command006
COMMAND TEntry1 = PBASE-F32-RDir-PublicApi-global-001-assign_Test1
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-5011-001-Read_command006
COMMAND TEntry1 = PBASE-F32-RDir-PublicApi-global-001-assign_Test2
COMMAND RDir1 Read PBASE-F32-RDir-PublicApi-5011-001-Read_command008
COMMAND TEntry1 = PBASE-F32-RDir-PublicApi-global-001-assign_Test3
COMMAND !Error=-25 RDir1 Read PBASE-F32-RDir-PublicApi-5011-001-Read_command009
COMMAND TEntry1 = PBASE-F32-RDir-PublicApi-global-001-assign_EOF
COMMAND RDir1 Close
COMMAND TEntry1 ~
COMMAND RDir1 ~
COMMAND RFs1 ~
END_TEST_BLOCK
END_TESTCASE PBASE-F32-RDir-PublicApi-5011
//////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////
////// //////
////// /////////////////////////////////// //////
////// /// /// //////
////// /// NEGATIVE TESTS /// //////
////// /// /// //////
////// /////////////////////////////////// //////
////// //////
//////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////////
//
//OPEN
//Open(RFs &aFs, const TDesC &aMatchName, const TUidType &aUidType)
//
////////////////////////////////////////////////////////////////////
START_TESTCASE PBASE-F32-RDir-PublicApi-5101
//! @SYMTestCaseID PBASE-F32-RDir-PublicApi-5101
//! @SYMAPI RDir
//! @SYMTestCaseDesc Function Open(RFs &aFs, const TDesC &aMatchName, const TUidType &aUidType) negative test, that tries to open
//! a directory which not exist and using the NULL UIDs.
//! Uses API elements: Open(), Close().
//! @SYMTestActions 1.Call Create a RFs session and call it's Connect() function.
//! 2.Call RDir::Open(RFs &aFs, const TDesC &aMatchName, const TUidType &aUidType),
//! and RFs session as first parameter, and <DRIVE>:\base\t_sfsrv\NotExist\ as second parameter,
//! and empty TUidType as third parameter.
//! 3.Call RDir::Close().
//! @SYMTestStatus Implemented
//! @SYMTestPriority Critical
//! @SYMTestExpectedResults The Open() method call returns error -12 (KErrPathNotFound).
//! @SYMTestType CIT
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-RDir-PublicApi.ini
CREATE_OBJECT RFs RFs1
CREATE_OBJECT RDir RDir1
COMMAND RFs1 new
COMMAND RFs1 Connect
COMMAND RDir1 new
COMMAND !Error=-12 RDir1 Open PBASE-F32-RDir-PublicApi-5101-001-Open_command005
COMMAND RDir1 Close
COMMAND RDir1 ~
COMMAND RFs1 ~
END_TEST_BLOCK
END_TESTCASE PBASE-F32-RDir-PublicApi-5101
START_TESTCASE PBASE-F32-RDir-PublicApi-5102
//! @SYMTestCaseID PBASE-F32-RDir-PublicApi-5102
//! @SYMAPI RDir
//! @SYMTestCaseDesc Function Open(RFs &aFs, const TDesC &aMatchName, const TUidType &aUidType) negative test, that tries to open
//! a directory using the NULL UIDs when directory path is not correct.
//! Uses API elements: Open(), Close().
//! @SYMTestActions 1.Call Create a RFs session and call it's Connect() function.
//! 2.Call RDir::Open(RFs &aFs, const TDesC &aMatchName, const TUidType &aUidType),
//! and RFs session as first parameter, and <DRIVE>:\base\t_sfsrv\\\\as second parameter,
//! and empty TUidType as third parameter.
//! 3.Call RDir::Close().
//! @SYMTestStatus Implemented
//! @SYMTestPriority Critical
//! @SYMTestExpectedResults The Open() method call returns error -28 (KErrBadName).
//! @SYMTestType CIT
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-RDir-PublicApi.ini
CREATE_OBJECT RFs RFs1
CREATE_OBJECT RDir RDir1
COMMAND RFs1 new
COMMAND RFs1 Connect
COMMAND RDir1 new
COMMAND !Error=-28 RDir1 Open PBASE-F32-RDir-PublicApi-5102-001-Open_command005
COMMAND RDir1 Close
COMMAND RDir1 ~
COMMAND RFs1 ~
END_TEST_BLOCK
END_TESTCASE PBASE-F32-RDir-PublicApi-5102
//////////////////////////////////////////////////////////
//
//OPEN
//Open(RFs &aFs, const TDesC &aMatchName, TUint anAttMask)
//
//////////////////////////////////////////////////////////
START_TESTCASE PBASE-F32-RDir-PublicApi-5103
//! @SYMTestCaseID PBASE-F32-RDir-PublicApi-5103
//! @SYMAPI RDir
//! @SYMTestCaseDesc Function Open(RFs &aFs, const TDesC &aMatchName, TUint anAttMask) test, that tries to open a directory
//! when directory path is not correct.
//! Uses API elements: Open(), Close().
//! @SYMTestActions 1.Call Create a RFs session and call it's Connect() function.
//! 2.Call RDir::Open(RFs &aFs, const TDesC &aMatchName, TUint anAttMask),
//! and empty RFs session as first parameter, and <DRIVE>:\base\t_sfsrv\\\\ as second parameter,
//! and KEntryAttNormal as third parameter.
//! 3.Call RDir::Close().
//! @SYMTestStatus Implemented
//! @SYMTestPriority Critical
//! @SYMTestExpectedResults The Open() method call returns error -28 (KErrBadName).
//! @SYMTestType CIT
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-RDir-PublicApi.ini
CREATE_OBJECT RFs RFs1
CREATE_OBJECT RDir RDir1
COMMAND RFs1 new
COMMAND RFs1 Connect
COMMAND RDir1 new
COMMAND !Error=-28 RDir1 Open PBASE-F32-RDir-PublicApi-5103-001-Open_command005
COMMAND RDir1 Close
COMMAND RDir1 ~
COMMAND RFs1 ~
END_TEST_BLOCK
START_TEST_BLOCK 100 T_SfSrv \base\PBASE-F32-RDir-PublicApi.ini
CREATE_OBJECT RFs RFs1
CREATE_OBJECT CFileMan CFileMan1
COMMAND RFs1 new
COMMAND RFs1 Connect
COMMAND CFileMan1 NewL PBASE-F32-RDir-PublicApi-NewL
COMMAND CFileMan1 Delete PBASE-F32-RDir-PublicApi-001-Delete
COMMAND RFs1 RmDir PBASE-F32-RDir-PublicApi-001-RmDir
COMMAND CFileMan1 ~
COMMAND RFs1 ~
END_TEST_BLOCK
END_TESTCASE PBASE-F32-RDir-PublicApi-5103