Rails3: test: add .to_s for mail's bodies check at unit/repository_test.rb

On Rails3, mail's bodies must be checked calling 'encoded'.
'to_s' is alias of 'encoded' of Mail::Message of Rails3.

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@9035 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Toshi MARUYAMA 2012-03-01 08:09:35 +00:00
parent e70f7ba75c
commit 7cdce2aeac

View File

@ -176,7 +176,7 @@ class RepositoryTest < ActiveSupport::TestCase
assert_not_nil mail
assert mail.subject.starts_with?(
"[#{fixed_issue.project.name} - #{fixed_issue.tracker.name} ##{fixed_issue.id}]")
assert mail.body.include?(
assert mail.body.to_s.include?(
"Status changed from #{old_status} to #{fixed_issue.status}")
# ignoring commits referencing an issue of another project