Drew Fisher wrote:
> You could always write a quick test in the test case startup function to
> check for the binary and call cti_deleteall() if it fails:
>
>
> startup () {
> if [[ ! -x $file ]] ; then
> cti_deleteall()
> fi
> }
That works quite nicely, except I had to use an argument for
cti_deleteall() otherwise it wouldn't work.
Still, it is not the optimal solution because I'd rather have run_test
terminated immediately when first call to tet_startup() is made. With
cti_deleteall() in tet_startup() it goes through all tests and marks
them UNINITIATED which is ok functionality-wise but waste of time:
$ run_test nc lflag
Validating Arguments...
New TET_ROOT for this run : /var/tmp/tessier_2088
...
##################################################
TC /tests/lflag
TP 1 lflag UNINITIATED
TP 2 lflag UNINITIATED
TP 3 lflag UNINITIATED
...
TP 13 lflag UNINITIATED
TP 14 lflag UNINITIATED
TP 15 lflag UNINITIATED
TP 16 lflag UNINITIATED
If I call exit() after cti_deleteall() then run_test does not run the
tests but I get a complaint from report_writer.
Anyway, not a big deal so I will stick with the current solution.
Thanks,
v.