Add ASSERT_{TRUE,FALSE} convenience macros

PUBLISHED_FROM=3cd6dd7f04b650ca637788d1017b6b5146c79569
This commit is contained in:
Deomid Ryabkov 2018-02-06 16:12:02 +00:00 committed by Cesanta Bot
parent 4afebdcb2b
commit 1ed99999bd

View File

@ -51,6 +51,8 @@ void _strfail(const char *a, const char *e, int len);
num_tests++; \
if (!(expr)) FAIL(#expr, __LINE__); \
} while (0)
#define ASSERT_TRUE(expr) ASSERT(expr)
#define ASSERT_FALSE(expr) ASSERT(!(expr))
/*
* Run test function, use its name as the test name to print