13 lines
479 B
C++
13 lines
479 B
C++
#define TESTFAILED 0
|
|
#define TESTGOOD 1
|
|
|
|
#include <iostream>
|
|
|
|
#define TESTDATA "./tests/data/"
|
|
|
|
#define ASSERT(BED, ERR) if(!(BED)) { std::cout << __FILE__ << ":" << __LINE__ << " " << ERR << std::endl; return TESTFAILED; }
|
|
#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)();
|