diff options
author | Jamis Buck <jamis@37signals.com> | 2005-06-06 16:12:38 +0000 |
---|---|---|
committer | Jamis Buck <jamis@37signals.com> | 2005-06-06 16:12:38 +0000 |
commit | 481d579734ac077f69fcd2db69c3dffdfd6f260a (patch) | |
tree | 00e79637081b5cd7e0c16ae73f8638bcb99d6628 /actionmailer/test/mail_service_test.rb | |
parent | cf1e2a84fff32ab1cf2a736bb99c53e830d92db3 (diff) | |
download | rails-481d579734ac077f69fcd2db69c3dffdfd6f260a.tar.gz rails-481d579734ac077f69fcd2db69c3dffdfd6f260a.tar.bz2 rails-481d579734ac077f69fcd2db69c3dffdfd6f260a.zip |
Don't error while processing encoded attachment names #1340 [lon@speedymac.com]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1390 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'actionmailer/test/mail_service_test.rb')
-rwxr-xr-x | actionmailer/test/mail_service_test.rb | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/actionmailer/test/mail_service_test.rb b/actionmailer/test/mail_service_test.rb index 9f0e51716f..48fe0941bb 100755 --- a/actionmailer/test/mail_service_test.rb +++ b/actionmailer/test/mail_service_test.rb @@ -503,5 +503,12 @@ EOF mail = TMail::Mail.parse(fixture) assert_equal "This is the first part.\n\nAttachment: test.pdf\n\n\nAttachment: smime.p7s\n", mail.body end + + def test_decode_encoded_attachment_filename + fixture = File.read(File.dirname(__FILE__) + "/fixtures/raw_email8") + mail = TMail::Mail.parse(fixture) + attachment = mail.attachments.last + assert_equal "01QuienTeDijat.Pitbull.mp3", attachment.original_filename + end end |