From c09aa177953deb27e28179f55844ced0489613b4 Mon Sep 17 00:00:00 2001 From: Jon Atack Date: Sat, 18 Apr 2015 21:15:27 +0530 Subject: [PATCH] Fix RSpec `its` method deprecation warning Deprecation Warnings: Use of rspec-core's `its` method is deprecated. Use the rspec-its gem instead. --- spec/ransack/adapters/active_record/context_spec.rb | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/spec/ransack/adapters/active_record/context_spec.rb b/spec/ransack/adapters/active_record/context_spec.rb index 3d9fb418d..cb21bc532 100644 --- a/spec/ransack/adapters/active_record/context_spec.rb +++ b/spec/ransack/adapters/active_record/context_spec.rb @@ -9,10 +9,11 @@ module ActiveRecord describe Context do subject { Context.new(Person) } - if AR_version >= "3.1" - its(:alias_tracker) { - should be_a ::ActiveRecord::Associations::AliasTracker - } + if AR_version >= '3.1' + it 'has an Active Record alias tracker method' do + expect(subject.alias_tracker) + .to be_an ::ActiveRecord::Associations::AliasTracker + end end describe '#relation_for' do