} while (0)
#define test_true_hint test_true_got
-#define test_skip(A,B) \
+#define test_skip(__expected, __actual) \
do \
{ \
- if ((A) != (B)) \
+ if (libtest::_compare(__FILE__, __LINE__, __func__, ((__expected)), ((__actual)), false) == false) \
+ { \
+ return TEST_SKIPPED; \
+ } \
+} while (0)
+
+#define test_skip_hint(__expected, __actual, __hint) \
+do \
+{ \
+ if (libtest::_compare_hint(__FILE__, __LINE__, __func__, (__expected), (__actual), (__hint)) == false) \
+ { \
+ return TEST_SKIPPED; \
+ } \
+} while (0)
+
+#define test_skip_valgrind() \
+do \
+{ \
+ if (libtest::_in_valgrind(__FILE__, __LINE__, __func__)) \
{ \
return TEST_SKIPPED; \
} \
} \
} while (0)
+#define test_ne_compare(__expected, __actual) \
+do \
+{ \
+ if (libtest::_ne_compare_hint(__FILE__, __LINE__, __func__, ((__expected)), ((__actual)), true) == false) \
+ { \
+ libtest::create_core(); \
+ return TEST_FAILURE; \
+ } \
+} while (0)
+
#define test_compare(__expected, __actual) \
do \
{ \
- if (not libtest::_compare(__FILE__, __LINE__, __func__, ((__expected)), ((__actual)))) \
+ if (libtest::_compare(__FILE__, __LINE__, __func__, ((__expected)), ((__actual)), true) == false) \
{ \
libtest::create_core(); \
return TEST_FAILURE; \
#define test_compare_warn(__expected, __actual) \
do \
{ \
- void(libtest::_compare(__FILE__, __LINE__, __func__, (__expected), (__actual))); \
+ void(libtest::_compare(__FILE__, __LINE__, __func__, (__expected), (__actual)), true); \
} while (0)
#define test_compare_warn_hint(__expected, __actual, __hint) \