summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorDylan Baker <dylan@pnwbakers.com>2017-09-06 10:52:45 -0700
committerDylan Baker <dylan@pnwbakers.com>2017-09-06 14:30:13 -0700
commitd4ea14c7f58e2a7c1981f15aec513517d9268918 (patch)
tree39a3a3eb3bce20bb40dcf4b69abfa092b865463e /tests
parented48c4550427bbcf6d2e64258c4724091c29fa01 (diff)
db/message: Don't set sender to ''
If the message doesn't have a sender, try to come up with one. If the message has the draft tag we known that the user is the sender, just use the default account as the from if we can't find one another way. If it doesn't have the draft tag just set the sending to 'Unknown'.
Diffstat (limited to 'tests')
-rw-r--r--tests/db/message_test.py2
1 files changed, 0 insertions, 2 deletions
diff --git a/tests/db/message_test.py b/tests/db/message_test.py
index 2f198759..a50d943e 100644
--- a/tests/db/message_test.py
+++ b/tests/db/message_test.py
@@ -88,7 +88,6 @@ class TestMessage(unittest.TestCase):
MockNotmuchMessage({'Sender': '"User Name" <user@example.com>'}))
self.assertEqual(msg.get_author(), ('User Name', 'user@example.com'))
- @unittest.expectedFailure
def test_get_author_no_name_draft(self):
"""Message._from is populated from the default account if the draft tag
is present.
@@ -102,7 +101,6 @@ class TestMessage(unittest.TestCase):
mock.Mock(), MockNotmuchMessage(tags=['draft']))
self.assertEqual(msg.get_author(), ('User Name', 'user@example.com'))
- @unittest.expectedFailure
def test_get_author_no_name(self):
"""Message._from is set to 'Unkown' if there is no relavent header and
the message is not a draft.