From f72989de5b3b3cfb6e6e639b57c3a3bebb2de8f2 Mon Sep 17 00:00:00 2001 From: Aaron Patterson Date: Thu, 21 Apr 2011 15:50:19 -0500 Subject: raising not implemented exceptions for distinct on where it is not supported --- test/visitors/test_to_sql.rb | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'test/visitors') diff --git a/test/visitors/test_to_sql.rb b/test/visitors/test_to_sql.rb index 25ff7be3e2..1d5f89280b 100644 --- a/test/visitors/test_to_sql.rb +++ b/test/visitors/test_to_sql.rb @@ -299,6 +299,17 @@ module Arel } end end + + describe 'distinct on' do + it 'raises not implemented error' do + core = Arel::Nodes::SelectCore.new + core.set_quantifier = Arel::Nodes::DistinctOn.new(Arel.sql('aaron')) + + assert_raises(NotImplementedError) do + @visitor.accept(core) + end + end + end end end end -- cgit v1.2.3