@@ -81,6 +81,13 class AdminControllerTest < ActionController::TestCase | |||||
81 | assert_equal [user.mail], mail.bcc |
|
81 | assert_equal [user.mail], mail.bcc | |
82 | end |
|
82 | end | |
83 |
|
83 | |||
|
84 | def test_test_email_failure_should_display_the_error | |||
|
85 | Mailer.stubs(:deliver_test).raises(Exception, 'Some error message') | |||
|
86 | get :test_email | |||
|
87 | assert_redirected_to '/settings/edit?tab=notifications' | |||
|
88 | assert_match /Some error message/, flash[:error] | |||
|
89 | end | |||
|
90 | ||||
84 | def test_no_plugins |
|
91 | def test_no_plugins | |
85 | Redmine::Plugin.clear |
|
92 | Redmine::Plugin.clear | |
86 |
|
93 |
General Comments 0
You need to be logged in to leave comments.
Login now