1047 |
1047 |
1048 nRes = TheFs.Delete(KBaseFN); |
1048 nRes = TheFs.Delete(KBaseFN); |
1049 test_KErrNone(nRes); |
1049 test_KErrNone(nRes); |
1050 for(i=0; i<MaxDummyFiles; ++i) |
1050 for(i=0; i<MaxDummyFiles; ++i) |
1051 { |
1051 { |
1052 nRes = DeleteFileX(KBaseFN, i); |
1052 nRes = DeleteFileX(KBaseFN, i); |
1053 test_KErrNone(nRes); |
1053 test_KErrNone(nRes); |
1054 } |
1054 } |
1055 } |
1055 } |
1056 |
1056 |
1057 void TestRAMDriveNotification() |
1057 void TestRAMDriveNotification() |
1148 |
1149 |
1149 FormatDrive(); |
1150 FormatDrive(); |
1150 } |
1151 } |
1151 |
1152 |
1152 //----------------------------------------------------------------------------- |
1153 //----------------------------------------------------------------------------- |
1153 |
1154 void CallTestsL() |
1154 GLDEF_C void CallTestsL() |
|
1155 // |
1155 // |
1156 // Do tests relative to session path |
1156 // Do tests relative to session path |
1157 // |
1157 // |
1158 { |
1158 { |
1159 //-- set up console output |
1159 //-- set up console output |
1160 Fat_Test_Utils::SetConsole(test.Console()); |
1160 Fat_Test_Utils::SetConsole(test.Console()); |
1161 |
1161 |
1162 // If TESTFAST mode (for automated test builds) is set, don't run LFFS tests. |
1162 // If TESTFAST mode (for automated test builds) is set, don't run LFFS tests. |
1163 if ((UserSvr::DebugMask(2) & 0x00000002) && IsTestingLFFS()) |
1163 if ((UserSvr::DebugMask(2) & 0x00000002) && IsTestingLFFS()) |
1164 { |
1164 { |
1165 test.Printf(_L("TEST NOT RUN FOR LFFS DRIVE")); |
1165 test.Printf(_L("TEST NOT RUN FOR LFFS DRIVE")); |
1166 return; |
1166 return; |
1176 |
1176 |
1177 TDriveInfo drv; |
1177 TDriveInfo drv; |
1178 r = TheFs.Drive(drv, gTestDrive); |
1178 r = TheFs.Drive(drv, gTestDrive); |
1179 test_KErrNone(r); |
1179 test_KErrNone(r); |
1180 |
1180 |
|
1181 |
1181 //-- print drive information |
1182 //-- print drive information |
1182 PrintDrvInfo(TheFs, gTestDrive); |
1183 PrintDrvInfo(TheFs, gTestDrive); |
|
1184 |
1183 |
1185 |
1184 // do not run the remainder of this test on RAM drive |
1186 // do not run the remainder of this test on RAM drive |
1185 if (drv.iType == EMediaRam) |
1187 if (drv.iType == EMediaRam) |
1186 { |
1188 { |
1187 TestRAMDriveNotification(); // Test drive space reservations trigger disk space notifications |
1189 TestRAMDriveNotification(); // Test drive space reservations trigger disk space notifications |
1188 test.Printf(_L("Main tests can't run on RAM drive %C:\n"), gSessionPath[0]); |
1190 test.Printf(_L("Main tests can't run on RAM drive %C:\n"), gSessionPath[0]); |
1189 return; |
1191 return; |
1190 } |
1192 } |
1191 |
1193 |
1192 if (Is_SimulatedSystemDrive(TheFs, gTestDrive)) |
1194 if (Is_Win32(TheFs, gTestDrive)) |
1193 { |
1195 { |
1194 test.Printf(_L("Skipping T_FALSESPACE on PlatSim/Emulator drive %C:\n"), gSessionPath[0]); |
1196 test.Printf(_L("Skipping on emulator %C: drive\n"), gSessionPath[0]); |
1195 return; |
1197 return; |
1196 } |
1198 } |
1197 |
1199 |
1198 Test0(); |
1200 Test0(); |
1199 Test1(); // General test for new APIs |
1201 Test1(); // General test for new APIs |
1200 Test2(); // Test to ensure drive and session reserve limits are not exceeded |
1202 Test2(); // Test to ensure drive and session reserve limits are not exceeded |
1201 Test3(); |
1203 Test3(); |
1202 Test4(); // Test filling the drive and that each checked API fails |
1204 Test4(); // test filling the drive and that each checked API fails |
1203 Test5(); |
1205 Test5(); |
1204 Test6(); |
1206 Test6(); |
1205 Test7(); |
1207 Test7(); |
1206 TestForDEF142554(); |
1208 TestForDEF142554(); |
1207 Test2(); // Run this test to check reserves are being cleared correctly |
1209 Test2(); // run this test to check reserves are being cleared correctly |
1208 |
1210 |
1209 TestFAT4G_Boundary(); |
1211 TestFAT4G_Boundary(); |
1210 |
1212 |
1211 TurnAllocFailureOff(); |
1213 TurnAllocFailureOff(); |
1212 } |
1214 } |