summaryrefslogtreecommitdiff
path: root/addons
diff options
context:
space:
mode:
authorChristophe Simonis <chs@odoo.com>2019-02-11 18:35:50 +0100
committerChristophe Simonis <chs@odoo.com>2019-02-11 18:35:50 +0100
commit1738fbb67e284b9c65fe6685fe6d28fc46b95021 (patch)
tree93ddc1c975b44f3735b814e17704e80b0ca72062 /addons
parent8c29df10e02e6777840ffd7a318472de29f77dd1 (diff)
[FIX] test_mail: only patch message_track for test model
Diffstat (limited to 'addons')
-rw-r--r--addons/test_mail/tests/test_mail_template.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/addons/test_mail/tests/test_mail_template.py b/addons/test_mail/tests/test_mail_template.py
index e1b14d57a20..bcaa1366ac5 100644
--- a/addons/test_mail/tests/test_mail_template.py
+++ b/addons/test_mail/tests/test_mail_template.py
@@ -223,7 +223,8 @@ class TestMailTemplate(BaseFunctionalTest, MockEmails, TestRecipients):
})
def patched_message_track_post_template(*args, **kwargs):
- args[0].message_post_with_template(template.id)
+ if args[0]._name == "mail.test.track":
+ args[0].message_post_with_template(template.id)
return True
with patch('odoo.addons.mail.models.mail_thread.MailThread._message_track_post_template', patched_message_track_post_template):