aboutsummaryrefslogtreecommitdiffstats
path: root/actionmailer/test
diff options
context:
space:
mode:
authorYves Senn <yves.senn@gmail.com>2014-05-13 08:21:13 +0200
committerYves Senn <yves.senn@gmail.com>2014-05-13 08:21:13 +0200
commit55b1f21ae361b585e3ff0e991703a47ab4887dd0 (patch)
tree352752893f218c48056a5700d4756aa59d26d77a /actionmailer/test
parent84908bbde97ef70b09aca4937793052422bc06ed (diff)
parent275d20ca01d6ed642677aec55cc9d92d49785d35 (diff)
downloadrails-55b1f21ae361b585e3ff0e991703a47ab4887dd0.tar.gz
rails-55b1f21ae361b585e3ff0e991703a47ab4887dd0.tar.bz2
rails-55b1f21ae361b585e3ff0e991703a47ab4887dd0.zip
Merge pull request #15085 from zuhao/refactor_actionmailer_log_subscriber_test
A minor stylistic fix and cleanup of mail deliveries.
Diffstat (limited to 'actionmailer/test')
-rw-r--r--actionmailer/test/log_subscriber_test.rb8
1 files changed, 5 insertions, 3 deletions
diff --git a/actionmailer/test/log_subscriber_test.rb b/actionmailer/test/log_subscriber_test.rb
index 5f0bee88fd..e7a73d6c8e 100644
--- a/actionmailer/test/log_subscriber_test.rb
+++ b/actionmailer/test/log_subscriber_test.rb
@@ -1,7 +1,7 @@
-require "abstract_unit"
+require 'abstract_unit'
require 'mailers/base_mailer'
-require "active_support/log_subscriber/test_helper"
-require "action_mailer/log_subscriber"
+require 'active_support/log_subscriber/test_helper'
+require 'action_mailer/log_subscriber'
class AMLogSubscriberTest < ActionMailer::TestCase
include ActiveSupport::LogSubscriber::TestHelper
@@ -31,6 +31,8 @@ class AMLogSubscriberTest < ActionMailer::TestCase
assert_equal(2, @logger.logged(:debug).size)
assert_match(/BaseMailer#welcome: processed outbound mail in [\d.]+ms/, @logger.logged(:debug).first)
assert_match(/Welcome/, @logger.logged(:debug).second)
+ ensure
+ BaseMailer.deliveries.clear
end
def test_receive_is_notified