Next: , Previous: , Up: Top   [Contents][Index]


11 Debugging facilities

CCTests implements some facilities to print common debugging messages from test programs.

Macro: CCTESTS_DEBUGGING

Enables the debugging facilities when it is defined to ‘1’ before the inclusion of cctests.h. By default, or if this symbol is defined to ‘0’: the macros documented below will expand to the empty expression.

Preprocessor Macro: char const * cctests_debug_question (EXPR)

When debugging is enabled, expand to:

((EXPR)? "yes" : "no")
Preprocessor Macro: void cctests_debug_print (char const * template, …)

When debugging is enabled, expand to an expression that prints to cctests_log_stream a debugging message. The message is composed of the current position in the source code and the result of formatting template with the given, optional, arguments; formatting works like it does for printf().

Preprocessor Macro: void cctests_debug_mark (void)

When debugging is enabled, expand to:

cctests_debug_print("mark")

Next: , Previous: , Up: Top   [Contents][Index]

This document describes version 0.4.1-devel.1 of CCTests.