Browse Source

Test that List-Id header field does not include display name and extra angle brackets (#14792).

Patch by Go MAEDA.


git-svn-id: http://svn.redmine.org/redmine/trunk@17873 e93f8b46-1217-0410-a6f0-8f06a7374b81
tags/4.1.0
Go MAEDA 5 years ago
parent
commit
675b0c641d
1 changed files with 5 additions and 2 deletions
  1. 5
    2
      test/unit/mailer_test.rb

+ 5
- 2
test/unit/mailer_test.rb View File

@@ -198,11 +198,14 @@ class MailerTest < ActiveSupport::TestCase
end

def test_email_headers
issue = Issue.find(1)
Mailer.deliver_issue_add(issue)
with_settings :mail_from => 'Redmine <redmine@example.net>' do
issue = Issue.find(1)
Mailer.deliver_issue_add(issue)
end
mail = last_email
assert_equal 'All', mail.header['X-Auto-Response-Suppress'].to_s
assert_equal 'auto-generated', mail.header['Auto-Submitted'].to_s
# List-Id should not include the display name "Redmine"
assert_equal '<redmine.example.net>', mail.header['List-Id'].to_s
end


Loading…
Cancel
Save