aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVipul A M <vipulnsward@gmail.com>2016-04-11 22:36:52 +0530
committerVipul A M <vipulnsward@gmail.com>2016-04-11 22:36:52 +0530
commit91b593dc19e8700540e78927e42a876730165f2b (patch)
tree9c2480056b2290d87bb50f6360c579b5ce09c49b
parent7a5faf5fee02accd6d96963444ad5c386613b91f (diff)
downloadrails-91b593dc19e8700540e78927e42a876730165f2b.tar.gz
rails-91b593dc19e8700540e78927e42a876730165f2b.tar.bz2
rails-91b593dc19e8700540e78927e42a876730165f2b.zip
Fix warnings from test_to_sql test
-rw-r--r--test/visitors/test_to_sql.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/visitors/test_to_sql.rb b/test/visitors/test_to_sql.rb
index 6da86c2dee..6833d4e8f5 100644
--- a/test/visitors/test_to_sql.rb
+++ b/test/visitors/test_to_sql.rb
@@ -695,7 +695,7 @@ module Arel
it 'supports #when with two arguments and no #then' do
node = Arel::Nodes::Case.new @table[:name]
- { foo: 1, bar: 0 }.reduce(node) { |node, pair| node.when *pair }
+ { foo: 1, bar: 0 }.reduce(node) { |_node, pair| _node.when(*pair) }
compile(node).must_be_like %{
CASE "users"."name" WHEN 'foo' THEN 1 WHEN 'bar' THEN 0 END