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


8 Condition object types

CCTests uses the external library CCExceptions to signal exceptional conditions and errors through non–local exits; See CCExceptions in CCExceptions.

The functions will raise exceptional conditions with cce_raise() and expect the caller to intercept them using the cce_location_t mechanics. The basic code template is:

#include <cctests.h>

cce_location_t  L[1];

if (cce_location(L)) {
  /* Handle errors here. */
  cce_run_catch_handlers_final(L);
} else {
  /* Do something useful here. */
  cce_run_body_handlers(L);
}

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

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