aboutsummaryrefslogtreecommitdiffstats
path: root/spec/arel/visitors
diff options
context:
space:
mode:
Diffstat (limited to 'spec/arel/visitors')
-rw-r--r--spec/arel/visitors/to_sql_spec.rb9
1 files changed, 9 insertions, 0 deletions
diff --git a/spec/arel/visitors/to_sql_spec.rb b/spec/arel/visitors/to_sql_spec.rb
index a266e87d22..1d78395b2f 100644
--- a/spec/arel/visitors/to_sql_spec.rb
+++ b/spec/arel/visitors/to_sql_spec.rb
@@ -13,6 +13,15 @@ module Arel
@visitor.accept attr
end
+ describe "Nodes::In" do
+ it "should know how to visit" do
+ node = @attr.in [1, 2, 3]
+ @visitor.accept(node).should be_like %{
+ "users"."id" IN (1, 2, 3)
+ }
+ end
+ end
+
describe 'Equality' do
it "should escape strings" do
test = @attr.eq 'Aaron Patterson'