diff options
-rw-r--r-- | examples/maildirresource/maildirresource.cpp | 2 | ||||
-rw-r--r-- | tests/maildirresourcetest.cpp | 3 |
2 files changed, 3 insertions, 2 deletions
diff --git a/examples/maildirresource/maildirresource.cpp b/examples/maildirresource/maildirresource.cpp index 90b4e55..68eb099 100644 --- a/examples/maildirresource/maildirresource.cpp +++ b/examples/maildirresource/maildirresource.cpp | |||
@@ -299,7 +299,7 @@ void MaildirResource::synchronizeMails(Akonadi2::Storage::Transaction &transacti | |||
299 | mail.setProperty("subject", msg->subject(true)->asUnicodeString()); | 299 | mail.setProperty("subject", msg->subject(true)->asUnicodeString()); |
300 | mail.setProperty("sender", msg->from(true)->asUnicodeString()); | 300 | mail.setProperty("sender", msg->from(true)->asUnicodeString()); |
301 | mail.setProperty("senderName", msg->from(true)->asUnicodeString()); | 301 | mail.setProperty("senderName", msg->from(true)->asUnicodeString()); |
302 | mail.setProperty("date", msg->date(true)->dateTime().toString()); | 302 | mail.setProperty("date", msg->date(true)->dateTime()); |
303 | mail.setProperty("folder", resolveRemoteId(ENTITY_TYPE_FOLDER, path, synchronizationTransaction)); | 303 | mail.setProperty("folder", resolveRemoteId(ENTITY_TYPE_FOLDER, path, synchronizationTransaction)); |
304 | mail.setProperty("mimeMessage", filepath); | 304 | mail.setProperty("mimeMessage", filepath); |
305 | mail.setProperty("unread", !flags.testFlag(KPIM::Maildir::Seen)); | 305 | mail.setProperty("unread", !flags.testFlag(KPIM::Maildir::Seen)); |
diff --git a/tests/maildirresourcetest.cpp b/tests/maildirresourcetest.cpp index 620ff04..c415a54 100644 --- a/tests/maildirresourcetest.cpp +++ b/tests/maildirresourcetest.cpp | |||
@@ -153,7 +153,7 @@ private Q_SLOTS: | |||
153 | { | 153 | { |
154 | Akonadi2::Query query; | 154 | Akonadi2::Query query; |
155 | query.resources << "org.kde.maildir.instance1"; | 155 | query.resources << "org.kde.maildir.instance1"; |
156 | query.requestedProperties << "folder" << "subject" << "mimeMessage"; | 156 | query.requestedProperties << "folder" << "subject" << "mimeMessage" << "date"; |
157 | query.syncOnDemand = true; | 157 | query.syncOnDemand = true; |
158 | query.processAll = true; | 158 | query.processAll = true; |
159 | 159 | ||
@@ -166,6 +166,7 @@ private Q_SLOTS: | |||
166 | auto mail = mailModel->index(0, 0, QModelIndex()).data(Akonadi2::Store::DomainObjectRole).value<Akonadi2::ApplicationDomain::Mail::Ptr>(); | 166 | auto mail = mailModel->index(0, 0, QModelIndex()).data(Akonadi2::Store::DomainObjectRole).value<Akonadi2::ApplicationDomain::Mail::Ptr>(); |
167 | QVERIFY(!mail->getProperty("subject").toString().isEmpty()); | 167 | QVERIFY(!mail->getProperty("subject").toString().isEmpty()); |
168 | QVERIFY(!mail->getProperty("mimeMessage").toString().isEmpty()); | 168 | QVERIFY(!mail->getProperty("mimeMessage").toString().isEmpty()); |
169 | QVERIFY(mail->getProperty("date").toDateTime().isValid()); | ||
169 | } | 170 | } |
170 | 171 | ||
171 | 172 | ||