summaryrefslogtreecommitdiff
path: root/service/test/adapter/pixelated_mail_test.py
diff options
context:
space:
mode:
Diffstat (limited to 'service/test/adapter/pixelated_mail_test.py')
-rw-r--r--service/test/adapter/pixelated_mail_test.py18
1 files changed, 14 insertions, 4 deletions
diff --git a/service/test/adapter/pixelated_mail_test.py b/service/test/adapter/pixelated_mail_test.py
index 923398ed..ae444098 100644
--- a/service/test/adapter/pixelated_mail_test.py
+++ b/service/test/adapter/pixelated_mail_test.py
@@ -8,15 +8,24 @@ import test_helper
class TestPixelatedMail(unittest.TestCase):
- def test_leap_flags_that_are_tags_are_handled(self):
- pixelated_mail = PixelatedMail(test_helper.leap_mail())
+ def test_leap_recent_flag_is_translated_to_inbox_tag(self):
+ pixelated_mail = PixelatedMail(test_helper.leap_mail(leap_flags=['\\Recent']))
self.assertIn(Tag('inbox'), pixelated_mail.tags)
+
+ def test_leap_deleted_flag_is_translated_to_trash_tag(self):
+ pixelated_mail = PixelatedMail(test_helper.leap_mail(leap_flags=['\\Deleted']))
self.assertIn(Tag('trash'), pixelated_mail.tags)
+
+ def test_leap_draft_flag_is_translated_to_draft_tag(self):
+ pixelated_mail = PixelatedMail(test_helper.leap_mail(leap_flags=['\\Draft']))
self.assertIn(Tag('drafts'), pixelated_mail.tags)
- def test_leap_flags_that_are_status_are_handled(self):
- pixelated_mail = PixelatedMail(test_helper.leap_mail())
+ def test_leap_seen_flag_is_translated_to_read_status(self):
+ pixelated_mail = PixelatedMail(test_helper.leap_mail(leap_flags=['\\Seen']))
self.assertIn('read', pixelated_mail.status)
+
+ def test_leap_answered_flag_is_translated_to_replied_status(self):
+ pixelated_mail = PixelatedMail(test_helper.leap_mail(leap_flags=['\\Answered']))
self.assertIn('replied', pixelated_mail.status)
def test_leap_flags_that_are_custom_tags_are_handled(self):
@@ -26,3 +35,4 @@ class TestPixelatedMail(unittest.TestCase):
def test_custom_tags_containing_our_prefix_are_handled(self):
pixelated_mail = PixelatedMail(test_helper.leap_mail(extra_flags=['tag_tag_work_tag_']))
self.assertIn(Tag('tag_work_tag_'), pixelated_mail.tags)
+