From 0d39cbe523206c90f4a3eaf9279f882510f375c5 Mon Sep 17 00:00:00 2001 From: Martin Little Date: Mon, 16 May 2011 09:49:37 -0400 Subject: Added an additional test since skip/limit can not be used in reverse order --- test/visitors/test_informix.rb | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/test/visitors/test_informix.rb b/test/visitors/test_informix.rb index db5e52b8a4..a8a52a0160 100644 --- a/test/visitors/test_informix.rb +++ b/test/visitors/test_informix.rb @@ -29,6 +29,14 @@ module Arel sql.must_be_like "SELECT SKIP 10" end + it 'uses SKIP before LIMIT' do + stmt = Nodes::SelectStatement.new + stmt.limit = Nodes::Limit.new(1) + stmt.offset = Nodes::Offset.new(1) + sql = @visitor.accept(stmt) + sql.must_be_like "SELECT SKIP 1 LIMIT 1" + end + end end end -- cgit v1.2.3