changeset 743d4bcb3873 in modules/notification_email:default
details:
https://hg.tryton.org/modules/notification_email?cmd=changeset;node=743d4bcb3873
description:
Update tests for new report name scheme
issue9509
diffstat:
tests/test_notification_email.py | 9 ++++++---
1 files changed, 6 insertions(+), 3 deletions(-)
diffs (33 lines):
diff -r b818ce5257dc -r 743d4bcb3873 tests/test_notification_email.py
--- a/tests/test_notification_email.py Thu Sep 17 17:18:02 2020 +0200
+++ b/tests/test_notification_email.py Thu Sep 24 18:28:44 2020 +0200
@@ -107,7 +107,8 @@
datamanager=ANY)
_, _, msg = sendmail.call_args[0]
self.assertEqual(msg['From'], FROM)
- self.assertEqual(msg['Subject'], 'Notification Email')
+ self.assertEqual(
+ msg['Subject'], 'Notification Email-Michael Scott')
self.assertEqual(msg['To'], 'Administrator <[email protected]>')
self.assertEqual(msg['Auto-Submitted'], 'auto-generated')
self.assertEqual(msg.get_content_type(), 'multipart/alternative')
@@ -154,7 +155,8 @@
user, FROM, ['Administrator <[email protected]>'], [], [], [en])
self.assertEqual(msg['From'], FROM)
- self.assertEqual(msg['Subject'], 'Notification Email')
+ self.assertEqual(
+ msg['Subject'], 'Notification Email-Michael Scott')
self.assertEqual(msg['To'], 'Administrator <[email protected]>')
self.assertEqual(msg.get_content_type(), 'multipart/mixed')
self.assertEqual(
@@ -166,7 +168,8 @@
b'attachment for Michael Scott')
self.assertEqual(
attachment.get_content_type(), 'text/plain')
- self.assertEqual(attachment.get_filename(), "Attachment.txt")
+ self.assertEqual(
+ attachment.get_filename(), "Attachment-Michael Scott.txt")
@with_transaction()
def test_notification_email_subject(self):