@@ -72,6 +72,7 class AttachmentsControllerTest < ActionController::TestCase | |||||
72 | end |
|
72 | end | |
73 |
|
73 | |||
74 | def test_show_text_file_utf_8 |
|
74 | def test_show_text_file_utf_8 | |
|
75 | set_tmp_attachments_directory | |||
75 | a = Attachment.new(:container => Issue.find(1), |
|
76 | a = Attachment.new(:container => Issue.find(1), | |
76 | :file => uploaded_test_file("japanese-utf-8.txt", "text/plain"), |
|
77 | :file => uploaded_test_file("japanese-utf-8.txt", "text/plain"), | |
77 | :author => User.find(1)) |
|
78 | :author => User.find(1)) | |
@@ -92,6 +93,7 class AttachmentsControllerTest < ActionController::TestCase | |||||
92 | end |
|
93 | end | |
93 |
|
94 | |||
94 | def test_show_text_file_should_strip_non_utf8_content |
|
95 | def test_show_text_file_should_strip_non_utf8_content | |
|
96 | set_tmp_attachments_directory | |||
95 | a = Attachment.new(:container => Issue.find(1), |
|
97 | a = Attachment.new(:container => Issue.find(1), | |
96 | :file => uploaded_test_file("iso8859-1.txt", "text/plain"), |
|
98 | :file => uploaded_test_file("iso8859-1.txt", "text/plain"), | |
97 | :author => User.find(1)) |
|
99 | :author => User.find(1)) |
General Comments 0
You need to be logged in to leave comments.
Login now