From 31a830e1ba19d4f97c7503158662a944a4fca598 Mon Sep 17 00:00:00 2001 From: MrBesen Date: Tue, 1 Jun 2021 10:48:28 +0200 Subject: [PATCH] neue test defines --- tests/test.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/test.h b/tests/test.h index 890d25b..fb492f1 100644 --- a/tests/test.h +++ b/tests/test.h @@ -6,6 +6,7 @@ #define TESTDATA "./tests/data/" #define ASSERT(BED, ERR) if(!(BED)) { std::cout << __FILE__ << ":" << __LINE__ << " " << ERR << std::endl; return TESTFAILED; } -// #define ASSERT(BED) ASSERT(BED, "") +#define CMPASSERTE(A, B, ERR) if( !((A) == (B))) { std::cout << __FILE__ << ":" << __LINE__ << " is: \"" << (A) << "\" should: \"" << (B) << "\""<< std::endl; return TESTFAILED; } +#define CMPASSERT(A, B) CMPASSERTE(A, B, "") typedef int (*test_t)();