5 * Copyright (c) 2001 Samuel A. Falvo II, William D. Tanksley
6 * See CUT-LICENSE.TXT for details.
8 * Based on WDT's "TestAssert" package.
11 * Revision 1.4 2003/03/18 05:53:50 sfalvo
12 * ADD: cutgen.c: cut_exit() -- common exit point; returns proper error code
15 * FIX: cutgen.c: Factored all instances of exit() to invoke cut_exit()
16 * instead. This fixes the bug #703793.
18 * Revision 1.3 2003/03/13 04:27:54 sfalvo
19 * ADD: LICENSE.TXT -- zlib license
21 * ADD: README cut.h cutgen.c -- Changelog token for CVS
23 * FIX: test/bringup-failure -- reflects new usage for bringups and
24 * teardowns in CUT 2.2.
28 #ifndef CUT_CUT_H_INCLUDED
29 #define CUT_CUT_H_INCLUDED
31 typedef void(*cut_fn
)(void);
33 void cut_init(const char *, int);
36 #define cut_run(G, T) __cut_run("group-" #G, \
37 __CUT_BRINGUP__ ## G, \
38 __CUT_TAKEDOWN__ ## G, \
44 #define ASSERT(X,msg) __cut_assert(__FILE__,__LINE__,msg,#X,X)
46 #define STATIC_ASSERT(X) extern bool __static_ASSERT_at_line_##__LINE__##__[ (0!=(X))*2-1 ];
49 * These functions are not officially "public". They exist here because they
50 * need to be for proper operation of CUT. Please use the aforementioned
54 void __cut_run(char *, cut_fn
, cut_fn
, char *, cut_fn
, char *, int);
55 void __cut_assert( char *, int, char *, char *, int );