diff --git a/spec/associations/active_record_extensions_spec.rb b/spec/associations/active_record_extensions_spec.rb index 400d9a06..a1a11982 100644 --- a/spec/associations/active_record_extensions_spec.rb +++ b/spec/associations/active_record_extensions_spec.rb @@ -180,7 +180,7 @@ class Book < ActiveRecord::Base it "doesn't raise any exception when the belongs_to association class can't be autoloaded" do # Simulate autoloader allow_any_instance_of(String).to receive(:constantize).and_raise(LoadError, "Unable to autoload constant NonExistent") - expect { School.belongs_to :city, {class_name: 'NonExistent'} }.not_to raise_error + expect { School.belongs_to :city, class_name: 'NonExistent' }.not_to raise_error end end