Replace old date to not crash Apple Mail

This commit is contained in:
Michal Horejsek
2020-12-07 13:22:09 +01:00
parent 2de202ca02
commit 40db822450
7 changed files with 69 additions and 1 deletions

View File

@ -60,3 +60,17 @@ Feature: IMAP fetch messages
When IMAP client fetches by UID "1:*"
Then IMAP response is "OK"
And IMAP response has 2 message
Scenario: Fetch of very old message sent from the moon succeeds with modified date
Given there are messages in mailbox "Folders/mbox" for "user"
| from | to | subject | time |
| john.doe@mail.com | user@pm.me | foo | 1969-07-20T00:00:00 |
And there is IMAP client logged in as "user"
And there is IMAP client selected in "Folders/mbox"
When IMAP client sends command "FETCH 1:* rfc822"
Then IMAP response is "OK"
And IMAP response contains "Date: Fri, 13 Aug 1982"
And IMAP response contains "X-Original-Date: Sun, 20 Jul 1969"
# We had bug to incorectly set empty date, so let's make sure
# there is no reference anywhere in the response.
And IMAP response does not contain "Date: Thu, 01 Jan 1970"