mirror of
https://github.com/pacnpal/django-anymail.git
synced 2025-12-20 11:51:05 -05:00
Mailgun: update integration tests
Track change to Mailgun's events API, which no longer includes message recipients. (Only affected check for successful send in the integration tests; Anymail doesn't use the events API outside test code.) Fixes #58
This commit is contained in:
@@ -137,9 +137,8 @@ class MailgunBackendIntegrationTests(SimpleTestCase, AnymailTestMixin):
|
|||||||
{"meta1": "simple string", "meta2": "2"}) # all metadata values become strings
|
{"meta1": "simple string", "meta2": "2"}) # all metadata values become strings
|
||||||
|
|
||||||
self.assertEqual(event["message"]["scheduled-for"], send_at_timestamp)
|
self.assertEqual(event["message"]["scheduled-for"], send_at_timestamp)
|
||||||
self.assertCountEqual(event["message"]["recipients"],
|
self.assertIn(event["recipient"], ['to1@example.com', 'to2@example.com', 'cc1@example.com',
|
||||||
['to1@example.com', 'to2@example.com', 'cc1@example.com', 'cc2@example.com',
|
'cc2@example.com', 'bcc1@example.com', 'bcc2@example.com'])
|
||||||
'bcc1@example.com', 'bcc2@example.com']) # don't care about order
|
|
||||||
|
|
||||||
headers = event["message"]["headers"]
|
headers = event["message"]["headers"]
|
||||||
self.assertEqual(headers["from"], "Test From <from@example.com>")
|
self.assertEqual(headers["from"], "Test From <from@example.com>")
|
||||||
|
|||||||
Reference in New Issue
Block a user