little test-helper cosmetics
This commit is contained in:
parent
dc5ae73626
commit
87465ff69b
1 changed files with 9 additions and 9 deletions
|
|
@ -129,15 +129,15 @@ namespace test{
|
||||||
* an assertion failure. In case of an exception, the #lumiera_error
|
* an assertion failure. In case of an exception, the #lumiera_error
|
||||||
* state is checked, cleared and verified.
|
* state is checked, cleared and verified.
|
||||||
*/
|
*/
|
||||||
#define VERIFY_ERROR(ERROR_ID, ERRONEOUS_STATEMENT) \
|
#define VERIFY_ERROR(ERROR_ID, ERRONEOUS_STATEMENT) \
|
||||||
try \
|
try \
|
||||||
{ \
|
{ \
|
||||||
ERRONEOUS_STATEMENT ; \
|
ERRONEOUS_STATEMENT ; \
|
||||||
NOTREACHED(); \
|
NOTREACHED("'%s' resisted to fail", #ERRONEOUS_STATEMENT); \
|
||||||
} \
|
} \
|
||||||
catch (...) \
|
catch (...) \
|
||||||
{ \
|
{ \
|
||||||
ASSERT (lumiera_error () == LUMIERA_ERROR_##ERROR_ID ); \
|
CHECK (lumiera_error_expect (LUMIERA_ERROR_##ERROR_ID)); \
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue