#include <QObject>
#include <QString>
#include <QSharedPointer>
#include <QTextStream>
Go to the source code of this file.
|
#define | TEST_CONCATENATE_DETAIL(x, y) x##y |
| Copyright 2011-2013 - Reliable Bits Software by Blommers IT. More...
|
|
#define | TEST_CONCATENATE(x, y) TEST_CONCATENATE_DETAIL(x, y) |
|
#define | TEST_MAKE_UNIQUE(x) TEST_CONCATENATE(x, __COUNTER__) |
|
#define | DECLARE_TEST(className) static edbee::test::Test<className> TEST_MAKE_UNIQUE(t)(#className) |
|
#define | DECLARE_NAMED_TEST(name, className) static edbee::test::Test<className> TEST_MAKE_UNIQUE(name)(#className) |
|
#define | GET_3TH_ARG(arg1, arg2, arg3, ...) arg3 |
|
#define | GET_4TH_ARG(arg1, arg2, arg3, arg4, ...) arg4 |
|
#define | testTrue_1(statement) testTrueImpl( ( statement ) ? true : false, #statement, "", __FILE__, __LINE__) |
|
#define | testTrue_2(statement, message) testTrueImpl( ( statement ) ? true : false, #statement, (message), __FILE__, __LINE__ ) |
|
#define | testTrue_MACRO_CHOOSER(...) GET_3TH_ARG(__VA_ARGS__, testTrue_2, testTrue_1, ) |
|
#define | testTrue(...) testTrue_MACRO_CHOOSER(__VA_ARGS__)(__VA_ARGS__) |
|
#define | testFalse(statement) testTrue( !statement ) |
|
#define | testEqual_1(actual, expected) |
|
#define | testEqual_2(actual, expected, message) |
|
#define | testEqual_MACRO_CHOOSER(...) GET_4TH_ARG(__VA_ARGS__, testEqual_2, testEqual_1, ) |
|
#define | testEqual(...) testEqual_MACRO_CHOOSER(__VA_ARGS__)(__VA_ARGS__) |
|
#define | testSkip(msg) testSkipImpl( msg, __FILE__, __LINE__) |
|
◆ DECLARE_NAMED_TEST
◆ DECLARE_TEST
◆ GET_3TH_ARG
#define GET_3TH_ARG |
( |
|
arg1, |
|
|
|
arg2, |
|
|
|
arg3, |
|
|
|
... |
|
) |
| arg3 |
◆ GET_4TH_ARG
#define GET_4TH_ARG |
( |
|
arg1, |
|
|
|
arg2, |
|
|
|
arg3, |
|
|
|
arg4, |
|
|
|
... |
|
) |
| arg4 |
◆ TEST_CONCATENATE
◆ TEST_CONCATENATE_DETAIL
#define TEST_CONCATENATE_DETAIL |
( |
|
x, |
|
|
|
y |
|
) |
| x##y |
Copyright 2011-2013 - Reliable Bits Software by Blommers IT.
All Rights Reserved. Author Rick Blommers: Replace these tests with the standard Qt testing framework
◆ TEST_MAKE_UNIQUE
◆ testEqual
◆ testEqual_1
#define testEqual_1 |
( |
|
actual, |
|
|
|
expected |
|
) |
| |
Value:do { \
testEqualImpl( ( actualStr ) == ( expectedStr ), actualStr, expectedStr, #actual, #expected, "", __FILE__, __LINE__ ); \
} while( false )
QString toQString(const T &obj)
Definition: test.h:40
◆ testEqual_2
#define testEqual_2 |
( |
|
actual, |
|
|
|
expected, |
|
|
|
message |
|
) |
| |
Value:do \
testEqualImpl( ( actualStr ) == ( expectedStr ), actualStr, expectedStr, #actual, #expected, (message), __FILE__, __LINE__ ); \
} while( false )
QString toQString(const T &obj)
Definition: test.h:40
◆ testEqual_MACRO_CHOOSER
◆ testFalse
#define testFalse |
( |
|
statement | ) |
testTrue( !statement ) |
◆ testSkip
#define testSkip |
( |
|
msg | ) |
testSkipImpl( msg, __FILE__, __LINE__) |
◆ testTrue
◆ testTrue_1
#define testTrue_1 |
( |
|
statement | ) |
testTrueImpl( ( statement ) ? true : false, #statement, "", __FILE__, __LINE__) |
◆ testTrue_2
#define testTrue_2 |
( |
|
statement, |
|
|
|
message |
|
) |
| testTrueImpl( ( statement ) ? true : false, #statement, (message), __FILE__, __LINE__ ) |
◆ testTrue_MACRO_CHOOSER