diff options
author | Martin Little <mlittle@tempusfactor.com> | 2011-05-16 09:49:37 -0400 |
---|---|---|
committer | Martin Little <mlittle@tempusfactor.com> | 2011-05-16 09:49:37 -0400 |
commit | 0d39cbe523206c90f4a3eaf9279f882510f375c5 (patch) | |
tree | efe39b2a2843cfb5c233e8217ba93dca657d05b2 /test | |
parent | 157969a565606277575bd436f64434a2a5b1d4a2 (diff) | |
download | rails-0d39cbe523206c90f4a3eaf9279f882510f375c5.tar.gz rails-0d39cbe523206c90f4a3eaf9279f882510f375c5.tar.bz2 rails-0d39cbe523206c90f4a3eaf9279f882510f375c5.zip |
Added an additional test since skip/limit can not be used in reverse order
Diffstat (limited to 'test')
-rw-r--r-- | test/visitors/test_informix.rb | 8 |
1 files changed, 8 insertions, 0 deletions
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 |