From 1f5ed8eb20231644525bdad9a94a91e810191186 Mon Sep 17 00:00:00 2001 From: Ernie Miller Date: Fri, 29 Apr 2011 14:27:45 -0400 Subject: Stop calling to_s on aliases, require them to be strings already. --- test/visitors/test_depth_first.rb | 6 +++--- test/visitors/test_dot.rb | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'test') diff --git a/test/visitors/test_depth_first.rb b/test/visitors/test_depth_first.rb index e078d4add5..5bbdf57697 100644 --- a/test/visitors/test_depth_first.rb +++ b/test/visitors/test_depth_first.rb @@ -50,14 +50,14 @@ module Arel Arel::Nodes::Sum, ].each do |klass| define_method("test_#{klass.name.gsub('::', '_')}") do - func = klass.new(:a, :b) + func = klass.new(:a, "b") @visitor.accept func assert_equal [:a, "b", false, func], @collector.calls end end def test_named_function - func = Arel::Nodes::NamedFunction.new(:a, :b, :c) + func = Arel::Nodes::NamedFunction.new(:a, :b, "c") @visitor.accept func assert_equal [:a, :b, false, "c", func], @collector.calls end @@ -69,7 +69,7 @@ module Arel end def test_count - count = Nodes::Count.new :a, :b, :c + count = Nodes::Count.new :a, :b, "c" @visitor.accept count assert_equal [:a, "c", :b, count], @collector.calls end diff --git a/test/visitors/test_dot.rb b/test/visitors/test_dot.rb index 2909d87799..b311246436 100644 --- a/test/visitors/test_dot.rb +++ b/test/visitors/test_dot.rb @@ -16,7 +16,7 @@ module Arel Nodes::Avg, ].each do |klass| define_method("test_#{klass.name.gsub('::', '_')}") do - op = klass.new(:a, :z) + op = klass.new(:a, "z") @visitor.accept op end end -- cgit v1.2.3