@@ -193,12 +193,12 class AttachmentsControllerTest < ActionController::TestCase | |||||
193 | end |
|
193 | end | |
194 |
|
194 | |||
195 | def test_show_text_file_should_send_if_too_big |
|
195 | def test_show_text_file_should_send_if_too_big | |
196 |
|
|
196 | with_settings :file_max_size_displayed => 512 do | |
197 | Attachment.find(4).update_attribute :filesize, 754.kilobyte |
|
197 | Attachment.find(4).update_attribute :filesize, 754.kilobyte | |
198 |
|
198 | get :show, :id => 4 | ||
199 | get :show, :id => 4 |
|
199 | assert_response :success | |
200 | assert_response :success |
|
200 | assert_equal 'application/x-ruby', @response.content_type | |
201 | assert_equal 'application/x-ruby', @response.content_type |
|
201 | end | |
202 | set_tmp_attachments_directory |
|
202 | set_tmp_attachments_directory | |
203 | end |
|
203 | end | |
204 |
|
204 |
General Comments 0
You need to be logged in to leave comments.
Login now