move unit mailer test last_email method to the bottom and change to private
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@9635 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
parent
5ce2987ea9
commit
6e7eadf9fb
|
@ -497,12 +497,6 @@ class MailerTest < ActiveSupport::TestCase
|
||||||
assert_mail_body_match 'Bug #3: Error 281 when updating a recipe', mail
|
assert_mail_body_match 'Bug #3: Error 281 when updating a recipe', mail
|
||||||
end
|
end
|
||||||
|
|
||||||
def last_email
|
|
||||||
mail = ActionMailer::Base.deliveries.last
|
|
||||||
assert_not_nil mail
|
|
||||||
mail
|
|
||||||
end
|
|
||||||
|
|
||||||
def test_mailer_should_not_change_locale
|
def test_mailer_should_not_change_locale
|
||||||
Setting.default_language = 'en'
|
Setting.default_language = 'en'
|
||||||
# Set current language to italian
|
# Set current language to italian
|
||||||
|
@ -536,4 +530,11 @@ class MailerTest < ActiveSupport::TestCase
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
private
|
||||||
|
def last_email
|
||||||
|
mail = ActionMailer::Base.deliveries.last
|
||||||
|
assert_not_nil mail
|
||||||
|
mail
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue