Skip to content

Commit

Permalink
Remove old fixture_path support
Browse files Browse the repository at this point in the history
  • Loading branch information
JonRowe committed Aug 7, 2020
1 parent 7643f3b commit 64e965b
Showing 1 changed file with 0 additions and 12 deletions.
12 changes: 0 additions & 12 deletions lib/rspec/rails/fixture_file_upload_support.rb
Expand Up @@ -22,22 +22,10 @@ class RailsFixtureFileWrapper
include ActionDispatch::TestProcess if defined?(ActionDispatch::TestProcess)

class << self
attr_reader :fixture_path

# Get instance of wrapper
def instance
@instance ||= new
end

# Override fixture_path set
# to support Rails 3.0->3.1 using ActionController::TestCase class to resolve fixture_path
# see https://apidock.com/rails/v3.0.0/ActionDispatch/TestProcess/fixture_file_upload
def fixture_path=(value)
if ActionController::TestCase.respond_to?(:fixture_path)
ActionController::TestCase.fixture_path = value
end
@fixture_path = value
end
end
end
end
Expand Down

0 comments on commit 64e965b

Please sign in to comment.