The testing module seems deprecated and unmaintained. It also can't compile:
cc -O2 -DDAO_WITH_NUMARRAY -DDAO_WITH_THREAD -DDAO_WITH_CONCURRENT -DDAO_WITH_RESTART -DTARGET_PLAT=\"linux\" -DLINUX=2 -DUNIX=1 -I../../../kernel/ -I../../auxlib/ -fPIC -c dao_test_base.c -o DaoMake.Objs/dao_test_base.c.D8B1.o
dao_test_base.c: In function ‘TEST_Run’:
dao_test_base.c:48:38: error: ‘DaoNamespace {aka struct DaoNamespace}’ has no member named ‘definedRoutines’; did you mean ‘mainRoutine’?
DList *funcs = proc->activeNamespace->definedRoutines;
^~
dao_test_base.c:60:28: error: ‘DAO_ROUT_DECORATOR’ undeclared (first use in this function)
if ( !( rout->attribs & DAO_ROUT_DECORATOR ) && rout->parCount == 0 ){
^~~~~~~~~~~~~~~~~~
dao_test_base.c:60:28: note: each undeclared identifier is reported only once for each function it appears in
dao_test_base.c: In function ‘TEST_AssertEq’:
dao_test_base.c:92:7: warning: implicit declaration of function ‘DaoValue_ComparePro’ [-Wimplicit-function-declaration]
if ( DaoValue_ComparePro( p[0], p[1], proc ) != 0 ){
^~~~~~~~~~~~~~~~~~~
dao_test_base.c: At top level:
dao_test_base.c:219:8: error: unknown type name ‘DaoFuncItem’
static DaoFuncItem testFuncs[] =
^~~~~~~~~~~
dao_test_base.c:222:2: warning: braces around scalar initializer
{ TEST_Run, "runTests(namePrefix = '')" },
^
dao_test_base.c:222:2: note: (near initialization for ‘testFuncs[0]’)
dao_test_base.c:222:4: warning: initialization makes integer from pointer without a cast [-Wint-conversion]
{ TEST_Run, "runTests(namePrefix = '')" },
^~~~~~~~
<snip>
dao_test_base.c:250:16: note: (near initialization for ‘baseFuncs[2]’)
dao_test_base.c:251:2: warning: braces around scalar initializer
{ TEST_Skip, "testSkipped()" },
^
dao_test_base.c:251:2: note: (near initialization for ‘baseFuncs[3]’)
dao_test_base.c:251:4: warning: initialization makes integer from pointer without a cast [-Wint-conversion]
{ TEST_Skip, "testSkipped()" },
^~~~~~~~~
dao_test_base.c:251:4: note: (near initialization for ‘baseFuncs[3]’)
dao_test_base.c:251:4: error: initializer element is not computable at load time
dao_test_base.c:251:4: note: (near initialization for ‘baseFuncs[3]’)
dao_test_base.c:251:16: warning: excess elements in scalar initializer
{ TEST_Skip, "testSkipped()" },
^~~~~~~~~~~~~~~
dao_test_base.c:251:16: note: (near initialization for ‘baseFuncs[3]’)
dao_test_base.c:252:2: warning: braces around scalar initializer
{ NULL, NULL }
^
dao_test_base.c:252:2: note: (near initialization for ‘baseFuncs[4]’)
dao_test_base.c:252:4: warning: initialization makes integer from pointer without a cast [-Wint-conversion]
{ NULL, NULL }
^~~~
dao_test_base.c:252:4: note: (near initialization for ‘baseFuncs[4]’)
dao_test_base.c: In function ‘DaoBase_OnLoad’:
dao_test_base.c:259:38: warning: passing argument 2 of ‘DaoNamespace_WrapFunctions’ from incompatible pointer type [-Wincompatible-pointer-types]
DaoNamespace_WrapFunctions( testns, testFuncs );
^~~~~~~~~
In file included from dao_test_base.c:33:0:
../../../kernel/dao.h:1138:13: note: expected ‘DaoFunctionEntry * {aka struct DaoFunctionEntry *}’ but argument is of type ‘int *’
DAO_DLL int DaoNamespace_WrapFunctions( DaoNamespace *self, DaoFunctionEntry fd[] );
^~~~~~~~~~~~~~~~~~~~~~~~~~
dao_test_base.c:260:38: warning: passing argument 2 of ‘DaoNamespace_WrapFunctions’ from incompatible pointer type [-Wincompatible-pointer-types]
DaoNamespace_WrapFunctions( basens, baseFuncs );
^~~~~~~~~
In file included from dao_test_base.c:33:0:
../../../kernel/dao.h:1138:13: note: expected ‘DaoFunctionEntry * {aka struct DaoFunctionEntry *}’ but argument is of type ‘int *’
DAO_DLL int DaoNamespace_WrapFunctions( DaoNamespace *self, DaoFunctionEntry fd[] );
^~~~~~~~~~~~~~~~~~~~~~~~~~
We should update it to the latest Dao or abandon it.
The
testing
module seems deprecated and unmaintained. It also can't compile:We should update it to the latest Dao or abandon it.