From e4613c97c3760c5298ab19ec5120f93ac83f03b2 Mon Sep 17 00:00:00 2001 From: claudiob Date: Sun, 11 Jan 2015 11:50:29 -0800 Subject: Fix assertion that was never run In order to run whether the `welcome` method of the ActionMailer::Base subclass raises an error, `message` must be called, otherwise the method is not executed at all. You could just replace with `def welcome; raise StandardError; end` and you would still see a passing test. This commit fixes the test so the assertion is actually executed, just like any other tests in the file, where `.message` is called. --- actionmailer/test/base_test.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'actionmailer/test') diff --git a/actionmailer/test/base_test.rb b/actionmailer/test/base_test.rb index 5d9eda2555..b218d923e5 100644 --- a/actionmailer/test/base_test.rb +++ b/actionmailer/test/base_test.rb @@ -287,7 +287,7 @@ class BaseTest < ActiveSupport::TestCase end end - assert_nothing_raised { LateAttachmentAccessorMailer.welcome } + assert_nothing_raised { LateAttachmentAccessorMailer.welcome.message } end # Implicit multipart -- cgit v1.2.3