aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/test/cases
diff options
context:
space:
mode:
authorLauro Caetano <laurocaetano1@gmail.com>2013-12-12 20:19:04 -0200
committerLauro Caetano <laurocaetano1@gmail.com>2013-12-12 20:19:04 -0200
commit1244aa7c5f871da5e907a39242b63a7aee3308a3 (patch)
tree4098cb84c5aba3aa4b8f791f6248ff2dced3b115 /activerecord/test/cases
parentaa85bdba68eb981588cecfef9dea0c0fa3e1c673 (diff)
downloadrails-1244aa7c5f871da5e907a39242b63a7aee3308a3.tar.gz
rails-1244aa7c5f871da5e907a39242b63a7aee3308a3.tar.bz2
rails-1244aa7c5f871da5e907a39242b63a7aee3308a3.zip
Use `public_send` instead of just use `send`.
Diffstat (limited to 'activerecord/test/cases')
-rw-r--r--activerecord/test/cases/relation/delegation_test.rb8
1 files changed, 4 insertions, 4 deletions
diff --git a/activerecord/test/cases/relation/delegation_test.rb b/activerecord/test/cases/relation/delegation_test.rb
index c5ad1e8976..b56dd5e5db 100644
--- a/activerecord/test/cases/relation/delegation_test.rb
+++ b/activerecord/test/cases/relation/delegation_test.rb
@@ -10,15 +10,15 @@ module ActiveRecord
method_arity = target.to_a.method(method).arity
if method_arity.zero?
- target.send(method)
+ target.public_send(method)
elsif method_arity < 0
if method == :shuffle!
- target.send(method)
+ target.public_send(method)
else
- target.send(method, 1)
+ target.public_send(method, 1)
end
elsif method_arity == 1
- target.send(method, 1)
+ target.public_send(method, 1)
else
raise NotImplementedError
end