diff options
author | Toshi MARUYAMA <marutosijp2@yahoo.co.jp> | 2017-01-28 06:25:03 +0000 |
---|---|---|
committer | Toshi MARUYAMA <marutosijp2@yahoo.co.jp> | 2017-01-28 06:25:03 +0000 |
commit | 3ac569c4d8c8b04a9cc33e3c2a05f8553d99827e (patch) | |
tree | 2368fefef5abaaf529cf349aa2c7c2d5ba452bf9 /test/unit/mail_handler_test.rb | |
parent | b2c0ea2c3e150f8ac666cd1ec0a81b943ee131c8 (diff) | |
download | redmine-3ac569c4d8c8b04a9cc33e3c2a05f8553d99827e.tar.gz redmine-3ac569c4d8c8b04a9cc33e3c2a05f8553d99827e.zip |
additional test for mail by Pavel Rosický (#24616)
git-svn-id: http://svn.redmine.org/redmine/trunk@16274 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/unit/mail_handler_test.rb')
-rw-r--r-- | test/unit/mail_handler_test.rb | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/test/unit/mail_handler_test.rb b/test/unit/mail_handler_test.rb index 898ccc918..562359a38 100644 --- a/test/unit/mail_handler_test.rb +++ b/test/unit/mail_handler_test.rb @@ -538,6 +538,16 @@ class MailHandlerTest < ActiveSupport::TestCase assert_equal 'd8e8fca2dc0f896fd7cb4cb0031ba249', attachment.digest end + def test_invalid_utf8 + issue = submit_email( + 'invalid_utf8.eml', + :issue => {:project => 'ecookbook'} + ) + assert_kind_of Issue, issue + description = "\xD0\x97\xD0\xB4\xD1\x80\xD0\xB0\xD0\xB2\xD1\x81\xD1\x82\xD0\xB2\xD1\x83\xD0\xB9\xD1\x82\xD0\xB5?".force_encoding('UTF-8') + assert_equal description, issue.description + end + def test_gmail_with_attachment_ja issue = submit_email( 'gmail_with_attachment_ja.eml', |