コード例 #1
0
static void DoTestsL()
	{
	User::LeaveIfError(Serv.Connect());
		
	test.Title();

	ResetTimeZoneToLondonL();

	CTzUserDataTest* userDataTest = CTzUserDataTest::NewLC();

	test.Start(_L("Test Basic User Data"));
	userDataTest->TestBasicUserDataL();

	test.Next(_L("Test Out Of Memory Behaviour (Client)"));
	userDataTest->TestOutOfMemoryBehaviourL(CTzUserDataTest::EClientOOM);

	test.Next(_L("Test Out Of Memory Behaviour (Server)"));
	userDataTest->TestOutOfMemoryBehaviourL(CTzUserDataTest::EServerOOM );
	
	test.Next(_L("@SYMTestCaseID PIM-APPSERV-TZS-TZR-0001 Test Time Conversion"));
	userDataTest->TestTimeConversionL();

	test.Next(_L("@SYMTestCaseID PIM-APPSERV-TZS-TZR-0002 Test Daylight Save"));
	userDataTest->TestDaylightSaveL();

	test.Next(_L("Test Boundary Test"));
	userDataTest->BoundaryTestL();

	test.Next(_L("Test Server Response To Changes"));
	userDataTest->TestServerResponseToChangesL();
	
	// Delete the user-defined TZ database before the next test case.
	Serv.CloseTzSession();
	Serv.DeleteFileL(KTzUserDataDb);

	test.Next(_L("Test Reusability Of TZ IDs"));
	userDataTest->TestTzIdReusabilityL();

	// Delete the user defined TZ database.
	Serv.CloseTzSession();
	Serv.DeleteFileL(KTzUserDataDb);	

	test.Next(_L("Null Test"));
	userDataTest->NullTestL();

	ResetTimeZoneToLondonL();

	CleanupStack::PopAndDestroy(userDataTest);

	test.End();

	Serv.Close();
	}
コード例 #2
0
LOCAL_C void DeleteFilesL()
	{
	RPIMTestServer serv;	
	CleanupClosePushL(serv);
	User::LeaveIfError(serv.Connect());
	serv.DeleteFileL(Ktimezonegroups_r01());	
	serv.DeleteFileL(Ktimezonegroups_r02());
	serv.DeleteFileL(Ktimezonegroups_rsc());
	serv.DeleteFileL(Ktimezones_r01());	
	serv.DeleteFileL(Ktimezones_r02());
	serv.DeleteFileL(Ktimezones_rsc());
	CleanupStack::PopAndDestroy(&serv);
	}
コード例 #3
0
LOCAL_C void CopyFileL(const TDesC& aFile1, const TDesC& aFile2)
	{
    RPIMTestServer serv;
    User::LeaveIfError(serv.Connect());
    serv.DeleteFileL(aFile2);
    serv.CopyFileL(aFile1, aFile2);
    serv.Close();
	}
コード例 #4
0
void DoTestL()
	{
	TAutoClose<RFs> theFS;
	TestNoErrL(theFS.iObj.Connect());

    User::LeaveIfError(serv.Connect());
	CleanupClosePushL(serv);

	TestExtHintFieldCreationL(theFS.iObj);

	CViewTester* viewTester = CViewTester::NewLC();
	viewTester->CreateFilterViewsL();
	CleanupStack::PopAndDestroy(viewTester);

    serv.DeleteFileL(KDatabaseFileName);
	serv.DeleteFileL(KDatabaseSecurePhysicalName);

	CleanupStack::PopAndDestroy(&serv);
	}
コード例 #5
0
TInt DeleteIniFile()
	{
	TInt retval = KErrNone;
	//TInt deleteSuccess;

	// Delete any existing ini file so that we can be sure this test is ok

    RPIMTestServer serv;
    User::LeaveIfError(serv.Connect());
    
    TRAPD (deleteSuccess, serv.DeleteFileL(KContactsModelIniFile));
    
    if ( deleteSuccess != KErrNotFound && deleteSuccess != KErrNone )
    {
		  retval = deleteSuccess;
	}
		
	return retval;
	}