Permalink
Browse files

Mime::PNG is already defined.

  • Loading branch information...
1 parent bb8b214 commit 1bcde3a771474403e5909bb3be47c8c77fb7eee0 @zuhao zuhao committed Jun 5, 2014
Showing with 0 additions and 8 deletions.
  1. +0 −6 actionpack/test/controller/send_file_test.rb
  2. +0 −2 actionpack/test/dispatch/mime_type_test.rb
@@ -33,17 +33,11 @@ class SendFileTest < ActionController::TestCase
include TestFileUtils
def setup
- @mime_type_defined = defined? Mime::PNG
- Mime::Type.register "image/png", :png unless @mime_type_defined
@controller = SendFileController.new
@request = ActionController::TestRequest.new
@response = ActionController::TestResponse.new
end
- teardown do
- Mime::Type.unregister :png unless @mime_type_defined
- end
-
def test_file_nostream
@controller.options = { :stream => false }
response = nil
@@ -1,8 +1,6 @@
require 'abstract_unit'
class MimeTypeTest < ActiveSupport::TestCase
- Mime::Type.register "image/png", :png unless defined? Mime::PNG
- Mime::Type.register "application/pdf", :pdf unless defined? Mime::PDF
test "parse single" do
Mime::LOOKUP.keys.each do |mime_type|

0 comments on commit 1bcde3a

Please sign in to comment.