test.h: fix unused variable warning when not enabled

Signed-off-by: Yuxuan Shui <yshuiv7@gmail.com>
This commit is contained in:
Yuxuan Shui 2019-03-18 21:52:30 +00:00
parent 7034883fbc
commit d9e628fb53
1 changed files with 2 additions and 2 deletions

4
test.h
View File

@ -122,8 +122,8 @@ static inline bool __attribute__((unused)) run_tests(int argc, char *const *argv
#define TEST_CASE(name) static void __attribute__((unused)) __test_h_##name(void)
#define TEST_EQUAL(a, b)
#define TEST_TRUE(a)
#define TEST_EQUAL(a, b) (void)(a); (void)(b)
#define TEST_TRUE(a) (void)(a)
static inline bool __attribute__((unused)) run_tests(int argc, char *const *argv) {
return true;