0.9.8.10
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
Macros | Functions
test-helper.h File Reference
#include <sys/time.h>
Include dependency graph for test-helper.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define HT_MEASURE(_t_, _code_)
 
#define HT_CHECK(e)   ((void)((e) ? 0 : HT_CHECK_FAIL(#e)))
 
#define HT_CHECK_FAIL(e)
 

Functions

static double ht_time_d ()
 

Macro Definition Documentation

#define HT_CHECK (   e)    ((void)((e) ? 0 : HT_CHECK_FAIL(#e)))

Definition at line 40 of file test-helper.h.

#define HT_CHECK_FAIL (   e)
Value:
((void)printf("%s:%u: %s: bad assertion: `%s'\n", \
__FILE__, __LINE__, __FUNCTION__, e), abort(), 0)

Definition at line 43 of file test-helper.h.

#define HT_MEASURE (   _t_,
  _code_ 
)
Value:
do { \
double t0 = ht_time_d(); _code_; _t_ = ht_time_d() - t0; \
} while (0)
static double ht_time_d()
Definition: test-helper.h:32

Definition at line 27 of file test-helper.h.

Function Documentation

static double ht_time_d ( )
inlinestatic

Definition at line 32 of file test-helper.h.