mirror of
https://github.com/falk-werner/webfuse-provider
synced 2024-10-27 20:44:10 +00:00
32 lines
511 B
C
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
|
||
|
|