diff options
author | Christian Mollekopf <chrigi_1@fastmail.fm> | 2017-07-28 18:41:22 -0600 |
---|---|---|
committer | Christian Mollekopf <chrigi_1@fastmail.fm> | 2017-08-02 13:05:27 -0600 |
commit | c206c1966e8e99d50ffbd08f45b01e99e140d498 (patch) | |
tree | aff1df2b1290581bfb060dbbee4295a5f0a3a14d /tests/mailtest.cpp | |
parent | 9e6952baf64b51fa7ddb6ac91d4ce79ebfd2b2df (diff) | |
download | sink-c206c1966e8e99d50ffbd08f45b01e99e140d498.tar.gz sink-c206c1966e8e99d50ffbd08f45b01e99e140d498.zip |
Ensure marking as unread works as well
Diffstat (limited to 'tests/mailtest.cpp')
-rw-r--r-- | tests/mailtest.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/mailtest.cpp b/tests/mailtest.cpp index cbb56d5..93d3ce3 100644 --- a/tests/mailtest.cpp +++ b/tests/mailtest.cpp | |||
@@ -328,6 +328,15 @@ void MailTest::testMarkMailAsRead() | |||
328 | return KAsync::null<void>(); | 328 | return KAsync::null<void>(); |
329 | }); | 329 | }); |
330 | VERIFYEXEC(job2); | 330 | VERIFYEXEC(job2); |
331 | |||
332 | //Verify we can mark the mail as unread again | ||
333 | { | ||
334 | auto readMail = Store::readOne<Mail>(Query{mail}); | ||
335 | readMail.setUnread(true); | ||
336 | VERIFYEXEC(Store::modify(readMail)); | ||
337 | VERIFYEXEC(ResourceControl::flushReplayQueue(mResourceInstanceIdentifier)); | ||
338 | VERIFYEXEC(ResourceControl::inspect<Mail>(ResourceControl::Inspection::PropertyInspection(readMail, Mail::Unread::name, true))); | ||
339 | } | ||
331 | } | 340 | } |
332 | 341 | ||
333 | void MailTest::testCreateDraft() | 342 | void MailTest::testCreateDraft() |