[ CCUnit project page ] [ CCUnit home page ]
Modules | Functions

_ReadSuite
[MakeSuite]

Read test func definitions from test source code. More...

Collaboration diagram for _ReadSuite:

Modules

 _Line
 

Read one line module.


Functions

void ccunit_readSuite (const char *fname, _CCUnitTestSuiteDef *parent)
 read test unit suite from specified stream.
static void destroyTestDef (_CCUnitTestDef *test)
 destroy test def.
static _CCUnitTestDefinitTestDef (_CCUnitTestDef *test, CCUnitTestType_t type, const char *name)
 init test def.
static void deleteTestDef (_CCUnitTestDef *test)
 delete test def.
static void destroyTestSuiteDef (_CCUnitTestSuiteDef *suite)
 destroy test suite def.
_CCUnitTestSuiteDefccunit_newTestSuiteDef (const char *name)
 create new test suite def.
void ccunit_deleteTestSuiteDef (_CCUnitTestSuiteDef *suite)
 delete test suite def.
static _CCUnitTestDefaddTestDef (_CCUnitTestSuiteDef *suite, _CCUnitTestDef *test)
 add test to test suite.
static _CCUnitTestDefaddTestSuiteDef (_CCUnitTestSuiteDef *suite, _CCUnitTestSuiteDef *test)
 add test suite to test suite.
static _CCUnitTestDefaddTestCaseDef (_CCUnitTestSuiteDef *suite, _CCUnitTestCaseDef *test)
 add test case to test suite.
static _CCUnitFuncDefnewFuncDef (const char *scope, const char *type, const char *name, const char *desc)
 create new test func.
static void deleteFuncDef (_CCUnitFuncDef *func)
 delete test func def.
static void destroyTestCaseDef (_CCUnitTestCaseDef *testCase)
 destroy test case def.
static _CCUnitTestCaseDefnewTestCaseDef (const char *name)
 create new test case def.

Detailed Description

Read test func definitions from test source code.


Function Documentation

static _CCUnitTestDef* addTestCaseDef ( _CCUnitTestSuiteDef suite,
_CCUnitTestCaseDef test 
) [inline, static]

add test case to test suite.

Parameters:
suite test suite to add.
test test case.
Returns:
added test.

References addTestDef(), ccunit_log(), _CCUnitTestDef::name, and _CCUnitTestCaseDef::testdef.

Referenced by readTestCase().

Here is the call graph for this function:

Here is the caller graph for this function:

static _CCUnitTestDef* addTestDef ( _CCUnitTestSuiteDef suite,
_CCUnitTestDef test 
) [static]

add test to test suite.

Parameters:
suite test suite to add.
test test group.
Returns:
added test.

References ccunit_addList(), and _CCUnitTestSuiteDef::testdefs.

Referenced by addTestCaseDef(), and addTestSuiteDef().

Here is the call graph for this function:

Here is the caller graph for this function:

static _CCUnitTestDef* addTestSuiteDef ( _CCUnitTestSuiteDef suite,
_CCUnitTestSuiteDef test 
) [inline, static]

add test suite to test suite.

Parameters:
suite test suite to add.
test test suite.
Returns:
added test.

References addTestDef(), ccunit_log(), _CCUnitTestDef::name, and _CCUnitTestSuiteDef::testdef.

Referenced by readSuite().

Here is the call graph for this function:

Here is the caller graph for this function:

void ccunit_deleteTestSuiteDef ( _CCUnitTestSuiteDef suite  )  [inline]

delete test suite def.

Parameters:
suite test suite def.

References deleteTestDef(), and _CCUnitTestSuiteDef::testdef.

Here is the call graph for this function:

_CCUnitTestSuiteDef* ccunit_newTestSuiteDef ( const char *  name  ) 

create new test suite def.

Parameters:
name suite name.
Returns:
created testdef.

References ccunit_initList(), ccunitTypeSuite, _CCUnitTestDef::dtor, initTestDef(), _CCUnitTestSuiteDef::testdef, and _CCUnitTestSuiteDef::testdefs.

Referenced by readSuite().

Here is the call graph for this function:

Here is the caller graph for this function:

void ccunit_readSuite ( const char *  fname,
_CCUnitTestSuiteDef parent 
)

read test unit suite from specified stream.

Parameters:
fname test unit source code file.
parent [out] test suite to adding read test.

References ccunit_err(), _CCUnitLine::fname, _CCUnitLine::ifp, line, readSuite(), safe_free, and _CCUnitLine::str.

Here is the call graph for this function:

static void deleteFuncDef ( _CCUnitFuncDef func  )  [static]

delete test func def.

Parameters:
func test func def to delete.

References _CCUnitFuncDef::desc, _CCUnitFuncDef::name, safe_free, _CCUnitFuncDef::scope, and _CCUnitFuncDef::type.

Referenced by destroyTestCaseDef(), and readSuite().

Here is the caller graph for this function:

static void deleteTestDef ( _CCUnitTestDef test  )  [static]

delete test def.

Parameters:
test testdef to delete.

References _CCUnitTestDef::dtor, and safe_free.

Referenced by ccunit_deleteTestSuiteDef(), and destroyTestSuiteDef().

Here is the caller graph for this function:

static void destroyTestCaseDef ( _CCUnitTestCaseDef testCase  )  [static]

destroy test case def.

Parameters:
testCase test case def to destroy.

References ccunit_deleteList(), deleteFuncDef(), destroyTestDef(), _CCUnitTestCaseDef::testdef, and _CCUnitTestCaseDef::testFuncs.

Here is the call graph for this function:

static void destroyTestDef ( _CCUnitTestDef test  )  [static]

destroy test def.

Parameters:
test testdef to destroy.

References _CCUnitTestDef::idname, _CCUnitTestDef::name, and safe_free.

Referenced by destroyTestCaseDef(), and destroyTestSuiteDef().

Here is the caller graph for this function:

static void destroyTestSuiteDef ( _CCUnitTestSuiteDef suite  )  [static]

destroy test suite def.

Parameters:
suite test suite def.

References ccunit_deleteList(), deleteTestDef(), destroyTestDef(), _CCUnitTestSuiteDef::testdef, and _CCUnitTestSuiteDef::testdefs.

Here is the call graph for this function:

static _CCUnitTestDef* initTestDef ( _CCUnitTestDef test,
CCUnitTestType_t  type,
const char *  name 
) [static]

init test def.

Parameters:
test testdef.
type test type.
name test name.

References _CCUnitTestDef::idname, _CCUnitTestDef::name, safe_strdup, and _CCUnitTestDef::type.

Referenced by ccunit_newTestSuiteDef(), and newTestCaseDef().

Here is the caller graph for this function:

static _CCUnitFuncDef* newFuncDef ( const char *  scope,
const char *  type,
const char *  name,
const char *  desc 
) [static]

create new test func.

Parameters:
scope scope.
type return type of func.
name func name.
desc description.
Returns:
new test func def.

References ccunit_log(), _CCUnitFuncDef::desc, _CCUnitFuncDef::name, safe_strdup, _CCUnitFuncDef::scope, and _CCUnitFuncDef::type.

Referenced by readTestFunc().

Here is the call graph for this function:

Here is the caller graph for this function:

static _CCUnitTestCaseDef* newTestCaseDef ( const char *  name  )  [static]

create new test case def.

Parameters:
name test case name.

References ccunit_initList(), ccunit_log(), ccunitTypeTestCase, _CCUnitTestDef::dtor, initTestDef(), _CCUnitTestCaseDef::testdef, and _CCUnitTestCaseDef::testFuncs.

Referenced by readTestCase().

Here is the call graph for this function:

Here is the caller graph for this function:

SourceForge.jp hosts this site. Send comments to: CCUnit Developer