summaryrefslogtreecommitdiff
path: root/service/test/integration
diff options
context:
space:
mode:
authorFelix Hammerl <fhammerl@thoughtworks.com>2016-06-17 14:34:22 +0200
committerFelix Hammerl <fhammerl@thoughtworks.com>2016-06-17 14:34:22 +0200
commit61ba137986f5830abedd22d42ec3a3bb28c0abf0 (patch)
tree0ec86f65eee47834258bc5d2594bd5aaa57e7d5c /service/test/integration
parent18b0c6d8f71972be8bbe7e7ce08176c91a912080 (diff)
Issue #608: Add unit test for case-specific lookup
Diffstat (limited to 'service/test/integration')
-rw-r--r--service/test/integration/test_leap_mailstore.py12
1 files changed, 12 insertions, 0 deletions
diff --git a/service/test/integration/test_leap_mailstore.py b/service/test/integration/test_leap_mailstore.py
index 383ad6ea..c3d7b043 100644
--- a/service/test/integration/test_leap_mailstore.py
+++ b/service/test/integration/test_leap_mailstore.py
@@ -39,6 +39,18 @@ class LeapMailStoreTest(SoledadTestBase):
self.assertEqual(expected_mail_dict, result.as_dict())
@defer.inlineCallbacks
+ def test_get_mail_with_lowercase_attachment(self):
+ input_mail = MIMEMultipart()
+ input_mail.attach(MIMEText(u'a utf8 message', _charset='utf-8'))
+ attachment = MIMEApplication('pretend to be binary attachment data')
+ attachment.add_header('content-disposition', 'attachment', filename='filename.txt')
+ input_mail.attach(attachment)
+
+ mail = yield self.mail_store.add_mail('INBOX', input_mail.as_string())
+ fetched_mail = yield self.mail_store.get_mail(mail.ident, include_body=True)
+ self.assertTrue(fetched_mail.as_dict()['attachments'])
+
+ @defer.inlineCallbacks
def test_get_mail_with_attachment(self):
input_mail = MIMEMultipart()
input_mail.attach(MIMEText(u'a utf8 message', _charset='utf-8'))