Fixed: TMail 1.2.7 malforms To header when number of recipients more then 8 (#8751).
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@7863 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
parent
e7a043c551
commit
e39d7a0ca8
@ -86,14 +86,21 @@ end
|
|||||||
|
|
||||||
ActionMailer::Base.send :include, AsynchronousMailer
|
ActionMailer::Base.send :include, AsynchronousMailer
|
||||||
|
|
||||||
# TMail::Unquoter.convert_to_with_fallback_on_iso_8859_1 introduced in TMail 1.2.7
|
|
||||||
# triggers a test failure in test_add_issue_with_japanese_keywords(MailHandlerTest)
|
|
||||||
module TMail
|
module TMail
|
||||||
|
# TMail::Unquoter.convert_to_with_fallback_on_iso_8859_1 introduced in TMail 1.2.7
|
||||||
|
# triggers a test failure in test_add_issue_with_japanese_keywords(MailHandlerTest)
|
||||||
class Unquoter
|
class Unquoter
|
||||||
class << self
|
class << self
|
||||||
alias_method :convert_to, :convert_to_without_fallback_on_iso_8859_1
|
alias_method :convert_to, :convert_to_without_fallback_on_iso_8859_1
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
# Patch for TMail 1.2.7. See http://www.redmine.org/issues/8751
|
||||||
|
class Encoder
|
||||||
|
def puts_meta(str)
|
||||||
|
add_text str
|
||||||
|
end
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
module ActionController
|
module ActionController
|
||||||
|
@ -472,6 +472,14 @@ class MailerTest < ActiveSupport::TestCase
|
|||||||
# should restore perform_deliveries
|
# should restore perform_deliveries
|
||||||
assert ActionMailer::Base.perform_deliveries
|
assert ActionMailer::Base.perform_deliveries
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def test_tmail_to_header_field_should_not_include_blank_lines
|
||||||
|
mail = TMail::Mail.new
|
||||||
|
mail.to = ["a.user@example.com", "v.user2@example.com", "e.smith@example.com", "info@example.com", "v.pupkin@example.com",
|
||||||
|
"b.user@example.com", "w.user2@example.com", "f.smith@example.com", "info2@example.com", "w.pupkin@example.com"]
|
||||||
|
|
||||||
|
assert !mail.encoded.strip.split("\r\n").detect(&:blank?), "#{mail.encoded} malformed"
|
||||||
|
end
|
||||||
|
|
||||||
context "layout" do
|
context "layout" do
|
||||||
should "include the emails_header" do
|
should "include the emails_header" do
|
||||||
|
Loading…
x
Reference in New Issue
Block a user