diff options
Diffstat (limited to 'test/functional/attachments_controller_test.rb')
-rw-r--r-- | test/functional/attachments_controller_test.rb | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/test/functional/attachments_controller_test.rb b/test/functional/attachments_controller_test.rb index 4d6b23f26..8ef46013c 100644 --- a/test/functional/attachments_controller_test.rb +++ b/test/functional/attachments_controller_test.rb @@ -358,6 +358,16 @@ class AttachmentsControllerTest < Redmine::ControllerTest set_tmp_attachments_directory end + def test_download_should_assign_application_octet_stream_if_content_type_is_not_determined + get :download, :params => { + :id => 23 + } + assert_response :success + assert_nil Redmine::MimeType.of(attachments(:attachments_023).filename) + assert_equal 'application/octet-stream', @response.content_type + set_tmp_attachments_directory + end + def test_download_missing_file get :download, :params => { :id => 2 |