[FIX] mass_mailing: add attachment in mass mailing test

When testing the mass mailing, with the 'Test Mailing'
button, the attachments were just not attached.

Closes #2981
This commit is contained in:
Denis Baranov 2015-08-14 17:35:23 +02:00 committed by Denis Ledoux
parent b8f177ddeb
commit c0c272c4a8
1 changed files with 1 additions and 0 deletions

View File

@ -33,6 +33,7 @@ class TestMassMailing(osv.TransientModel):
'body_html': '',
'notification': True,
'mailing_id': mailing.id,
'attachment_ids': [(4, attachment.id) for attachment in mailing.attachment_ids],
}
mail_mail_obj = Mail.browse(cr, uid, Mail.create(cr, uid, mail_values, context=context), context=context)
unsubscribe_url = Mail._get_unsubscribe_url(cr, uid, mail_mail_obj, test_mail, context=context)