summaryrefslogtreecommitdiffstats
path: root/tests/mailtest.h
diff options
context:
space:
mode:
Diffstat (limited to 'tests/mailtest.h')
-rw-r--r--tests/mailtest.h21
1 files changed, 1 insertions, 20 deletions
diff --git a/tests/mailtest.h b/tests/mailtest.h
index 16d5d73..362e044 100644
--- a/tests/mailtest.h
+++ b/tests/mailtest.h
@@ -22,26 +22,7 @@
22#include <QByteArray> 22#include <QByteArray>
23 23
24#include <applicationdomaintype.h> 24#include <applicationdomaintype.h>
25 25#include "testutils.h"
26#define ASYNCCOMPARE(actual, expected) \
27do {\
28 if (!QTest::qCompare(actual, expected, #actual, #expected, __FILE__, __LINE__))\
29 return KAsync::error<void>(1, "Comparison failed.");\
30} while (0)
31
32#define ASYNCVERIFY(statement) \
33do {\
34 if (!QTest::qVerify((statement), #statement, "", __FILE__, __LINE__))\
35 return KAsync::error<void>(1, "Verify failed.");\
36} while (0)
37
38#define VERIFYEXEC(statement) \
39do {\
40 auto result = statement.exec(); \
41 result.waitForFinished(); \
42 if (!QTest::qVerify(!result.errorCode(), #statement, "", __FILE__, __LINE__))\
43 return;\
44} while (0)
45 26
46namespace Sink { 27namespace Sink {
47 28