Commit graph

11 commits

Author SHA1 Message Date
Michael Gratton
0ae633d88f Update existing tests to work with ValaUnit 2020-06-30 17:31:07 +10:00
Chris Heywood
4ff783b231 Merge branch 'mainline' into remove-old-msgs-beyond-storage-pref 2020-04-30 18:08:19 +10:00
Michael Gratton
196f05e595 test/test-case.vala: Rename TestCase async calls to match AsyncCallWaiter's 2020-04-10 12:58:09 +10:00
Chris Heywood
01e114f09a Fix detach_emails_before_timestamp test case
That's ImapDB.Folder::detach_emails_before_timestamp, fixed
and enabled.
2020-02-10 16:04:13 +01:00
Chris Heywood
e7d3b46b37 Temporarily disable test 2020-01-22 12:19:16 +01:00
Chris Heywood
150417727e Test case for detach_emails_before_timestamp
ie. ImapDB.Folder::detach_emails_before_timestamp.
2020-01-22 10:23:13 +01:00
Rico Tzschichholz
5c909334b7 Add missing generic arguments in engine tests to fix valac criticals
See https://gitlab.gnome.org/GNOME/vala/issues/835
2019-08-15 08:36:46 +02:00
Michael Gratton
66a664f98d Clean up ImapDB.Account ctor/open API a bit
Move args from open_async to ctor and use these to determine and store
DB file and attachment paths as properties. This allows constructing
the DB instance up front and markig it as non-nullable, simplifies
calling patterns and hence allows removing one use of the deprecated
Engine singleton, and by moving in the local data deletion
implementation from ImapEngine.GenericAccount, also allows removing a
static helper method.
2019-06-13 16:55:23 +10:00
Michael Gratton
03b5fcee8a Pass email to a contact harvester instance when persisting it
Add a ContactHarvester arg to ImapDB.Folder.create_or_merge_email and
call it on the resulting email. Add and update a new harvester
property to MinimalFolder and pass that in as needed.
2019-06-13 16:33:44 +10:00
Michael Gratton
744cde0c2f Don't update a folder's unread email count during normalisation
Updating the unread count after opening a folder and finding email that
has an unexpected unread status messes up the count obtained from the
server, which has already taken these messages into account.

Here, both the main normalisation process and the email flag updater are
prevented from adjusting the unread count for a folder when they
encounter email that are new and unread, or have an unread status
different from what was last seen by the engine.

See #213
2019-02-15 13:40:04 +11:00
Michael Gratton
539893fb72 Add some unit tests for setting email flags 2019-02-13 18:41:49 +11:00