1
0
mirror of https://github.com/falk-werner/webfuse-provider synced 2024-10-27 20:44:10 +00:00
falk-werner_webfuse-provider/test-src/test_util.h
2019-01-27 03:45:03 +01:00

32 lines
511 B
C

#ifndef _WSFS_TEST_UTIL_H
#define _WSFS_TEST_UTIL_H
#define ASSERT_EQ(expected, actual) \
do \
{ \
if ((expected) != (actual)) \
{ \
fail(__FILE__, __LINE__, "expected " #expected ", but was " #actual); \
} \
} \
while (0)
#define ASSERT_NE(expected, actual) \
do \
{ \
if ((expected) == (actual)) \
{ \
fail(__FILE__, __LINE__, "expected " #expected ", but was " #actual); \
} \
} \
while (0)
extern void fail(
char const * file_name,
int line,
char const * message
);
#endif