/*
*
* SetInputFileNameL
*
*/
void CTestStepActrl::SetReadFileNameL( const TDesC& aPathNameAndExtn )
{
//[ append the filename relative to the default path ]
 User::LeaveIfError(iFs.Connect());
 TFileName fileName = GetSuite()->DefaultPath();
 fileName.Append(aPathNameAndExtn);
 iFileConfigRead().iPath = fileName ;
}
Exemplo n.º 2
0
int
main()
{
        CuSuite  *suite  = CuSuiteNew();
        CuString *output = CuStringNew();
        CuSuiteAddSuite( suite, GetSuite());
        CuSuiteRun(suite);
        CuSuiteSummary( suite, output);
        fprintf( stdout, "%s\n", output->buffer);
        exit(suite->failCount);
}
/*
*
* SetOutputFileNameL
*
*/
void CTestStepActrl::SetWriteFileNameL( const TDesC& aPathNameAndExtn )
	{
	//[ append the filename relative to the default path ]
	User::LeaveIfError(iFs.Connect());
	TFileName fileName = GetSuite()->DefaultPath();
	fileName.Append(aPathNameAndExtn);
	TInt ret = iFs.Delete(fileName);
	if (ret != KErrNone && ret != KErrNotFound)
		User::Leave(ret);
	iFileConfigWrite().iPath = fileName ;
	
	Log( fileName );
	}
Exemplo n.º 4
0
void RunAllTests(void)
{
	//obtain tests of independent functions
	CuSuite_t* suite = GetSuite(CuStringGetSuite1);//CuSuiteNew();

	//*********************************
	//*** Test CuTestString			***
	//*********************************
		 //assert initialization of suite

    //run tests of independent functions
    printf("*** Running tests of independent functions...\n\n");
	if (testRunner(suite)){
        exit(-1);
	};

	CuSuiteDelete(suite);

	printf("*** Running tests of single dependent functions...\n\n");
	//obtain tests of dependent functions
	suite = GetSuite(CuStringGetSuite2);
    if (testRunner(suite)){
        exit(-1);
	};

    CuSuiteDelete(suite);

	printf("*** Running tests of multiple dependent functions...\n\n");
	//obtain tests of dependent functions
	suite = GetSuite(CuStringGetSuite3);
    if (testRunner(suite)){
        exit(-1);
	};

	CuSuiteDelete(suite);