summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/clientapitest.cpp10
-rw-r--r--tests/mailsynctest.cpp4
-rw-r--r--tests/mailtest.cpp6
-rw-r--r--tests/messagequeuetest.cpp4
4 files changed, 16 insertions, 8 deletions
diff --git a/tests/clientapitest.cpp b/tests/clientapitest.cpp
index 8c5866d..ec74cbd 100644
--- a/tests/clientapitest.cpp
+++ b/tests/clientapitest.cpp
@@ -9,6 +9,8 @@
9#include "resultprovider.h" 9#include "resultprovider.h"
10#include "facadefactory.h" 10#include "facadefactory.h"
11 11
12SINK_DEBUG_AREA("clientapitest")
13
12template <typename T> 14template <typename T>
13class TestDummyResourceFacade : public Sink::StoreFacade<T> 15class TestDummyResourceFacade : public Sink::StoreFacade<T>
14{ 16{
@@ -44,7 +46,7 @@ public:
44 { 46 {
45 auto resultProvider = new Sink::ResultProvider<typename T::Ptr>(); 47 auto resultProvider = new Sink::ResultProvider<typename T::Ptr>();
46 resultProvider->onDone([resultProvider]() { 48 resultProvider->onDone([resultProvider]() {
47 Trace() << "Result provider is done"; 49 SinkTrace() << "Result provider is done";
48 delete resultProvider; 50 delete resultProvider;
49 }); 51 });
50 // We have to do it this way, otherwise we're not setting the fetcher right 52 // We have to do it this way, otherwise we're not setting the fetcher right
@@ -52,11 +54,11 @@ public:
52 54
53 resultProvider->setFetcher([query, resultProvider, this](const typename T::Ptr &parent) { 55 resultProvider->setFetcher([query, resultProvider, this](const typename T::Ptr &parent) {
54 if (parent) { 56 if (parent) {
55 Trace() << "Running the fetcher " << parent->identifier(); 57 SinkTrace() << "Running the fetcher " << parent->identifier();
56 } else { 58 } else {
57 Trace() << "Running the fetcher."; 59 SinkTrace() << "Running the fetcher.";
58 } 60 }
59 Trace() << "-------------------------."; 61 SinkTrace() << "-------------------------.";
60 for (const auto &res : results) { 62 for (const auto &res : results) {
61 qDebug() << "Parent filter " << query.propertyFilter.value("parent").value.toByteArray() << res->identifier() << res->getProperty("parent").toByteArray(); 63 qDebug() << "Parent filter " << query.propertyFilter.value("parent").value.toByteArray() << res->identifier() << res->getProperty("parent").toByteArray();
62 auto parentProperty = res->getProperty("parent").toByteArray(); 64 auto parentProperty = res->getProperty("parent").toByteArray();
diff --git a/tests/mailsynctest.cpp b/tests/mailsynctest.cpp
index 953adbf..4401f27 100644
--- a/tests/mailsynctest.cpp
+++ b/tests/mailsynctest.cpp
@@ -31,6 +31,8 @@
31using namespace Sink; 31using namespace Sink;
32using namespace Sink::ApplicationDomain; 32using namespace Sink::ApplicationDomain;
33 33
34SINK_DEBUG_AREA("mailsynctest")
35
34void MailSyncTest::initTestCase() 36void MailSyncTest::initTestCase()
35{ 37{
36 Test::initTest(); 38 Test::initTest();
@@ -73,7 +75,7 @@ void MailSyncTest::testListFolders()
73 for (const auto &folder : folders) { 75 for (const auto &folder : folders) {
74 names << folder->getName(); 76 names << folder->getName();
75 } 77 }
76 Trace() << "base folder: " << names; 78 SinkTrace() << "base folder: " << names;
77 baseCount = folders.size(); 79 baseCount = folders.size();
78 }); 80 });
79 VERIFYEXEC(job); 81 VERIFYEXEC(job);
diff --git a/tests/mailtest.cpp b/tests/mailtest.cpp
index 8031cf1..0537175 100644
--- a/tests/mailtest.cpp
+++ b/tests/mailtest.cpp
@@ -31,6 +31,8 @@
31using namespace Sink; 31using namespace Sink;
32using namespace Sink::ApplicationDomain; 32using namespace Sink::ApplicationDomain;
33 33
34SINK_DEBUG_AREA("mailtest")
35
34void MailTest::initTestCase() 36void MailTest::initTestCase()
35{ 37{
36 Test::initTest(); 38 Test::initTest();
@@ -251,7 +253,7 @@ void MailTest::testMoveMail()
251 auto mail = *mails.first(); 253 auto mail = *mails.first();
252 modifiedMail = mail; 254 modifiedMail = mail;
253 QCOMPARE(mail.getFolder(), folder.identifier()); 255 QCOMPARE(mail.getFolder(), folder.identifier());
254 Warning() << "path: " << mail.getMimeMessagePath(); 256 SinkWarning() << "path: " << mail.getMimeMessagePath();
255 QVERIFY(QFile(mail.getMimeMessagePath()).exists()); 257 QVERIFY(QFile(mail.getMimeMessagePath()).exists());
256 }); 258 });
257 VERIFYEXEC(job); 259 VERIFYEXEC(job);
@@ -270,7 +272,7 @@ void MailTest::testMoveMail()
270 auto mail = *mails.first(); 272 auto mail = *mails.first();
271 QCOMPARE(mail.getFolder(), folder1.identifier()); 273 QCOMPARE(mail.getFolder(), folder1.identifier());
272 QVERIFY(QFile(mail.getMimeMessagePath()).exists()); 274 QVERIFY(QFile(mail.getMimeMessagePath()).exists());
273 Trace() << "Mime message path: " << mail.getMimeMessagePath(); 275 SinkTrace() << "Mime message path: " << mail.getMimeMessagePath();
274 }); 276 });
275 VERIFYEXEC(job); 277 VERIFYEXEC(job);
276 } 278 }
diff --git a/tests/messagequeuetest.cpp b/tests/messagequeuetest.cpp
index 484ff86..a8d0d4d 100644
--- a/tests/messagequeuetest.cpp
+++ b/tests/messagequeuetest.cpp
@@ -8,6 +8,8 @@
8#include "messagequeue.h" 8#include "messagequeue.h"
9#include "log.h" 9#include "log.h"
10 10
11SINK_DEBUG_AREA("messagequeuetest")
12
11/** 13/**
12 * Test of the messagequeue implementation. 14 * Test of the messagequeue implementation.
13 */ 15 */
@@ -80,7 +82,7 @@ private slots:
80 } 82 }
81 83
82 while (!queue.isEmpty()) { 84 while (!queue.isEmpty()) {
83 Log() << "start"; 85 SinkLog() << "start";
84 const auto expected = values.dequeue(); 86 const auto expected = values.dequeue();
85 bool gotValue = false; 87 bool gotValue = false;
86 bool gotError = false; 88 bool gotError = false;