Saleor Core: the high performance, composable, headless commerce API.
Python cartcheckoutcommercecomposablee-commerceecommercegraphqlheadlessheadless-commercemultichannelomsorder-managementpaymentspimpythonshopshopping-cartstore
Fix failing e-mail tests
Anna Siwik011a58e159ac
diff --git a/tests/test_emails.py b/tests/test_emails.pyindex 93a9cea4c4..578f476a0f 100644--- a/tests/test_emails.py+++ b/tests/test_emails.py@@ -5,6 +5,7 @@ from django.conf import settingsimport saleor.order.emails as emailsEMAIL = "[email protected]"+DOMAIN = 'mirumee.com'SITE_NAME = 'mirumee.com'URL = 'wooba/looba'EMAIL_FROM = settings.ORDER_FROM_EMAIL@@ -14,7 +15,12 @@ EMAIL_FROM = settings.ORDER_FROM_EMAILdef test_send_confirmation_using_templated_email(mocked_templated_email, order):emails.send_order_confirmation(EMAIL, URL, order.pk)- context = {'site_name': SITE_NAME, 'url': URL, 'order': order}+ context = {+ 'protocol': 'http',+ 'domain': DOMAIN,+ 'site_name': SITE_NAME,+ 'url': URL,+ 'order': order}mocked_templated_email.assert_called_once_with(recipient_list=[EMAIL],context=context,@@ -25,7 +31,11 @@ def test_send_confirmation_using_templated_email(@mock.patch('saleor.order.emails.send_templated_mail')def test_send_order_payment_confirmation(mocked_templated_email):emails.send_payment_confirmation(EMAIL, URL)- context = {'site_name': SITE_NAME, 'url': URL}+ context = {+ 'protocol': 'http',+ 'domain': DOMAIN,+ 'site_name': SITE_NAME,+ 'url': URL}mocked_templated_email.assert_called_once_with(recipient_list=[EMAIL],context=context,@@ -36,7 +46,11 @@ def test_send_order_payment_confirmation(mocked_templated_email):@mock.patch('saleor.order.emails.send_templated_mail')def test_send_note_confirmation(mocked_templated_email):emails.send_note_confirmation(EMAIL, URL)- context = {'site_name': SITE_NAME, 'url': URL}+ context = {+ 'protocol': 'http',+ 'domain': DOMAIN,+ 'site_name': SITE_NAME,+ 'url': URL}mocked_templated_email.assert_called_once_with(recipient_list=[EMAIL],context=context,