From 51f5bece0867316d035d5d8eeb3a2eb44cf89ad1 Mon Sep 17 00:00:00 2001 From: Yasuo Honda <yasuo.honda@gmail.com> Date: Thu, 6 Jun 2013 21:33:20 +0900 Subject: Support `columns_for_distinct` --- test/visitors/test_oracle.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'test') diff --git a/test/visitors/test_oracle.rb b/test/visitors/test_oracle.rb index 421e9951e6..bd22822bca 100644 --- a/test/visitors/test_oracle.rb +++ b/test/visitors/test_oracle.rb @@ -85,7 +85,8 @@ module Arel it 'creates a subquery when there is DISTINCT' do stmt = Nodes::SelectStatement.new - stmt.cores.first.projections << Nodes::SqlLiteral.new('DISTINCT id') + stmt.cores.first.set_quantifier = Arel::Nodes::Distinct.new + stmt.cores.first.projections << Nodes::SqlLiteral.new('id') stmt.limit = Arel::Nodes::Limit.new(10) sql = @visitor.accept stmt sql.must_be_like %{ -- cgit v1.2.3