mirror of
https://github.com/meineerde/redmine.git
synced 2025-12-27 10:51:15 +00:00
use with_settings at AttachmentsControllerTest#test_show_text_file_should_send_if_too_big
git-svn-id: http://svn.redmine.org/redmine/trunk@13173 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
parent
be33ac6fc0
commit
ebb1a0092f
@ -193,12 +193,12 @@ class AttachmentsControllerTest < ActionController::TestCase
|
||||
end
|
||||
|
||||
def test_show_text_file_should_send_if_too_big
|
||||
Setting.file_max_size_displayed = 512
|
||||
Attachment.find(4).update_attribute :filesize, 754.kilobyte
|
||||
|
||||
get :show, :id => 4
|
||||
assert_response :success
|
||||
assert_equal 'application/x-ruby', @response.content_type
|
||||
with_settings :file_max_size_displayed => 512 do
|
||||
Attachment.find(4).update_attribute :filesize, 754.kilobyte
|
||||
get :show, :id => 4
|
||||
assert_response :success
|
||||
assert_equal 'application/x-ruby', @response.content_type
|
||||
end
|
||||
set_tmp_attachments_directory
|
||||
end
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user