diff options
author | David Heinemeier Hansson <david@loudthinking.com> | 2015-01-08 07:15:39 -0800 |
---|---|---|
committer | David Heinemeier Hansson <david@loudthinking.com> | 2015-01-08 07:15:39 -0800 |
commit | 0e8c7ff7f7988e9b0bfae91ca4f27b200f8f6541 (patch) | |
tree | fa56fcc84dee2a958c01bcd300fea756c6296e35 /actionmailer/CHANGELOG.md | |
parent | a22a653c293cc5d378d0bfdd595ad60603c5608d (diff) | |
parent | 3f17fbd68d17e9e51fbd39be772cec9f176ac08f (diff) | |
download | rails-0e8c7ff7f7988e9b0bfae91ca4f27b200f8f6541.tar.gz rails-0e8c7ff7f7988e9b0bfae91ca4f27b200f8f6541.tar.bz2 rails-0e8c7ff7f7988e9b0bfae91ca4f27b200f8f6541.zip |
Merge pull request #18403 from georgeclaghorn/enqueued-email-assertions
Enqueued email assertions
Diffstat (limited to 'actionmailer/CHANGELOG.md')
-rw-r--r-- | actionmailer/CHANGELOG.md | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/actionmailer/CHANGELOG.md b/actionmailer/CHANGELOG.md index 79cf09c0db..008760f2fc 100644 --- a/actionmailer/CHANGELOG.md +++ b/actionmailer/CHANGELOG.md @@ -1,3 +1,20 @@ +* Add `assert_enqueued_emails` and `assert_no_enqueued_emails`. + + def test_emails + assert_enqueued_emails 2 do + ContactMailer.welcome.deliver_later + ContactMailer.welcome.deliver_later + end + end + + def test_no_emails + assert_no_enqueued_emails do + # No emails enqueued here + end + end + + *George Claghorn* + * Add `_mailer` suffix to mailers created via generator, following the same naming convention used in controllers and jobs. |