-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
SDAN-722 Remove embeds from monitoring email (#1176)
- Loading branch information
1 parent
3cddb9f
commit 3f26da3
Showing
2 changed files
with
38 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -835,7 +835,14 @@ def test_send_immediate_email_alerts(client, app): | |
'products': [{'code': '12345'}], | ||
"versioncreated": utcnow(), | ||
'byline': 'Testy McTestface', | ||
'body_html': '<p>line 1 of the article text\nline 2 of the story\nand a bit more.</p>', | ||
'body_html': '<p>line 1 of the article text\nline 2 of the story\nand a bit more.</p>' | ||
'<!-- EMBED START Audio {id: "editor_2\"} -->' | ||
'<figure>' | ||
' <audio controls src="/assets.mp3"></audio>' | ||
' <figcaption>Assistant Treasurer</figcaption>' | ||
'</figure>' | ||
'<!-- EMBED END Audio {id: \"editor_2\"} -->' | ||
'<p>Something after the embed', | ||
'source': 'AAAA' | ||
}]) | ||
w = app.data.find_one('monitoring', None, _id='5db11ec55f627d8aa0b545fb') | ||
|
@@ -849,6 +856,8 @@ def test_send_immediate_email_alerts(client, app): | |
assert outbox[0].recipients == ['[email protected]', '[email protected]'] | ||
assert outbox[0].sender == 'newsroom@localhost' | ||
assert outbox[0].subject == 'Monitoring Subject' | ||
assert 'Something after the embed' in outbox[0].body | ||
assert 'Assistant Treasurer' not in outbox[0].body | ||
assert 'Newsroom Monitoring: W1' in outbox[0].body | ||
|
||
|
||
|