int main(int argc, char *argv[]) { testArray(); testPlugin(); testList(); return 0; testByteArray(); testHash(); testImage(); testIO(); testMap(); testString(); testStringList(); testStruct(); testThreads(); testVariant1(); testVariant2(); testVariant3(); testVector(); testVectorOfList(); testObject(argc, argv); QColor color(255,128,10); QFont font; while(true) ; return 0; }
int main() { testMutexes(); testConds(); testThreads(); return EXIT_SUCCESS; }
void run() { testThreads(0); testThreads(1); testThreads(2); testThreads(4); testThreads(16); testThreads(64); }
int main() { gboolean bRet; // initialize rwlock bRet = erRegRWLockInit(); if (FALSE == bRet) { ERREG_ERRORPRINTF("error"); return 0; } testThreads(); // destroy rwlock erRegRWLockDestroy(); return 0; }
GLDEF_C void CallTestsL() // // Do all tests // { TInt r = TTest::Init(); test_KErrNone(r); TChar drvch0 = TTest::DefaultDriveChar(); TChar drvch1 = 0; TChar drvch2 = 0; TInt drive0; TInt drive1; TInt drive2; const TInt KMaxArgs = 4; TPtrC argv[KMaxArgs]; TInt argc = TTest::ParseCommandArguments(argv, KMaxArgs); if (argc > 1) drvch0 = User::UpperCase(argv[1][0]); if (argc > 2) drvch1 = User::UpperCase(argv[2][0]); if (argc > 3) drvch2 = User::UpperCase(argv[3][0]); r = TheFs.CharToDrive(drvch0, drive0); test_KErrNone(r); if (TheFs.IsValidDrive(drive0)) MountTestFileSystem(drive0); else test.Printf(_L("Unable to mount test file system\n")); r = parseCmd(drvch1, drvch2); if (r != KErrNone) { UnmountFileSystem(drive0); User::Panic(_L("USER ABORT"), 0); } r = TheFs.CharToDrive(drvch1, drive1); test_KErrNone(r); r = TheFs.CharToDrive(drvch2, drive2); test_KErrNone(r); r = TheFs.FileSystemName(gFsName1, drive1); test_Value(r, r == KErrNone || r == KErrNotFound); r = TheFs.FileSystemName(gFsName2, drive2); test_Value(r, r == KErrNone || r == KErrNotFound); gDataLock.CreateLocal(); if (drive1 == drive2) { // !!! Disable platform security tests until we get the new APIs // if (User::Capability() & KCapabilityRoot) // CheckMountLFFS(TheFs, drvch1); test.Printf(_L("Using drive %c: (%S)\n"), (TUint)drvch1, &gFsName1); if (r == KErrNone) { test.Next(_L("Test with drive asynchronous")); RemountFileSystem(drive1, EFalse); testAsyncAccess(drvch1, drvch1); } if (r == KErrNone) { test.Next(_L("Test with drive synchronous")); RemountFileSystem(drive1, ETrue); testAsyncAccess(drvch1, drvch1); } } else { // !!! Disable platform security tests until we get the new APIs /* if (User::Capability() & KCapabilityRoot) { CheckMountLFFS(TheFs, drvch1); CheckMountLFFS(TheFs, drvch2); } */ test.Printf(_L("Using drives %c: (%S) and %c: (%S)\n"), (TUint)drvch1, &gFsName1, (TUint)drvch2, &gFsName2); #if !defined(TEST_ASYNC_IN_THREAD) if (r == KErrNone) { test.Next(_L("Test async r/w with both drives async")); RemountFileSystem(drive1, EFalse); RemountFileSystem(drive2, EFalse); testAsyncAccess(drvch1, drvch2); } if (r == KErrNone) { test.Next(_L("Test async r/w with 1st drive sync and 2nd async")); RemountFileSystem(drive1, ETrue); RemountFileSystem(drive2, EFalse); testAsyncAccess(drvch1, drvch2); } if (r == KErrNone) { test.Next(_L("Test async r/w with 1st drive async and 2nd sync")); RemountFileSystem(drive1, EFalse); RemountFileSystem(drive2, ETrue); testAsyncAccess(drvch1, drvch2); } if (r == KErrNone) { test.Next(_L("Test async r/w with both drives sync")); RemountFileSystem(drive1, ETrue); RemountFileSystem(drive2, ETrue); testAsyncAccess(drvch1, drvch2); } #else if (r == KErrNone) { test.Next(_L("Test async r/w with both drives asynchronous")); RemountFileSystem(drive1, EFalse); RemountFileSystem(drive2, EFalse); r = testThreads(testAsyncAccess, drvch1, drvch2); } if (r == KErrNone) { test.Next(_L("Test async r/w with one drive sync and one async")); RemountFileSystem(drive1, ETrue); RemountFileSystem(drive2, EFalse); r = testThreads(testAsyncAccess, drvch1, drvch2); } if (r == KErrNone) { test.Next(_L("Test async r/w with both drives synchronous")); RemountFileSystem(drive1, ETrue); RemountFileSystem(drive2, ETrue); r = testThreads(testAsyncAccess, drvch1, drvch2); } #endif #if defined(TEST_SYNC_IN_THREAD) if (r == KErrNone) { test.Next(_L("Test sync r/w with both drives asynchronous")); RemountFileSystem(drive1, EFalse); RemountFileSystem(drive2, EFalse); r = testThreads(testSyncAccess, drvch1, drvch2); } if (r == KErrNone) { test.Next(_L("Test sync r/w with one drive sync and one async")); RemountFileSystem(drive1, ETrue); RemountFileSystem(drive2, EFalse); r = testThreads(testSyncAccess, drvch1, drvch2); } if (r == KErrNone) { test.Next(_L("Test sync r/w with both drives synchronous")); RemountFileSystem(drive1, ETrue); RemountFileSystem(drive2, ETrue); r = testThreads(testSyncAccess, drvch1, drvch2); } #endif } gDataLock.Close(); UnmountFileSystem(drive0); test_Value(r, r == 0); }
int main(int argc, char **argv) { testThreads(); testThreadsEnded(); return 0; }