diff options
author | Eric Davis <edavis@littlestreamsoftware.com> | 2010-09-20 23:17:51 +0000 |
---|---|---|
committer | Eric Davis <edavis@littlestreamsoftware.com> | 2010-09-20 23:17:51 +0000 |
commit | 51359704a0a4a4af49fa8724059bc292649bb1da (patch) | |
tree | e732a512f3d9012c9aba394614066607f97db32a /test | |
parent | 55fbf6836be16f4776449e6bcdc8e029d67bcb66 (diff) | |
download | redmine-51359704a0a4a4af49fa8724059bc292649bb1da.tar.gz redmine-51359704a0a4a4af49fa8724059bc292649bb1da.zip |
Added a users options to the reminders email
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@4167 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test')
-rw-r--r-- | test/unit/mailer_test.rb | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/test/unit/mailer_test.rb b/test/unit/mailer_test.rb index a5932d325..77bcb36f6 100644 --- a/test/unit/mailer_test.rb +++ b/test/unit/mailer_test.rb @@ -355,6 +355,16 @@ class MailerTest < ActiveSupport::TestCase assert_equal '1 issue(s) due in the next 42 days', mail.subject end + def test_reminders_for_users + Mailer.reminders(:days => 42, :users => ['5']) + assert_equal 0, ActionMailer::Base.deliveries.size # No mail for dlopper + Mailer.reminders(:days => 42, :users => ['3']) + assert_equal 1, ActionMailer::Base.deliveries.size # No mail for dlopper + mail = ActionMailer::Base.deliveries.last + assert mail.bcc.include?('dlopper@somenet.foo') + assert mail.body.include?('Bug #3: Error 281 when updating a recipe') + end + def last_email mail = ActionMailer::Base.deliveries.last assert_not_nil mail |