diff options
Diffstat (limited to 'test/visitors/test_sqlite.rb')
-rw-r--r-- | test/visitors/test_sqlite.rb | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/test/visitors/test_sqlite.rb b/test/visitors/test_sqlite.rb new file mode 100644 index 0000000000..fb8392c504 --- /dev/null +++ b/test/visitors/test_sqlite.rb @@ -0,0 +1,18 @@ +require 'helper' + +module Arel + module Visitors + describe 'the sqlite visitor' do + before do + @visitor = SQLite.new Table.engine + end + + it 'defaults limit to -1' do + stmt = Nodes::SelectStatement.new + stmt.offset = Nodes::Offset.new(1) + sql = @visitor.accept(stmt) + sql.must_be_like "SELECT LIMIT -1 OFFSET 1" + end + end + end +end |