mirror of
https://github.com/ditkrg/active_model_serializers.git
synced 2026-01-25 07:16:49 +00:00
Configure sqlite3 to use ~> 1.4 for rails 6+
This commit is contained in:
16
test/support/ruby_2_6_rails_4_2_patch.rb
Normal file
16
test/support/ruby_2_6_rails_4_2_patch.rb
Normal file
@@ -0,0 +1,16 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
if RUBY_VERSION >= '2.6.0'
|
||||
if Rails::VERSION::MAJOR < 5
|
||||
class ActionController::TestResponse < ActionDispatch::TestResponse
|
||||
def recycle!
|
||||
# hack to avoid MonitorMixin double-initialize error:
|
||||
@mon_mutex_owner_object_id = nil
|
||||
@mon_mutex = nil
|
||||
initialize
|
||||
end
|
||||
end
|
||||
else
|
||||
puts "Monkeypatch for ActionController::TestResponse no longer needed"
|
||||
end
|
||||
end
|
||||
@@ -56,6 +56,8 @@ end
|
||||
|
||||
require 'support/rails_app'
|
||||
|
||||
require 'support/ruby_2_6_rails_4_2_patch'
|
||||
|
||||
# require "rails/test_help"
|
||||
|
||||
require 'support/serialization_testing'
|
||||
|
||||
Reference in New Issue
Block a user