diff options
author | Aaron Patterson <aaron.patterson@gmail.com> | 2010-10-20 17:17:22 -0700 |
---|---|---|
committer | Aaron Patterson <aaron.patterson@gmail.com> | 2010-10-20 17:17:22 -0700 |
commit | 410114e85ac0048de3fd932a5aaac2a11b45be86 (patch) | |
tree | 6696f03a9fce592f2dd1054a789c8a0ded678a81 /activerecord/test | |
parent | 828bb94d5a41695d30cb46ccafb152c98cdeae0a (diff) | |
download | rails-410114e85ac0048de3fd932a5aaac2a11b45be86.tar.gz rails-410114e85ac0048de3fd932a5aaac2a11b45be86.tar.bz2 rails-410114e85ac0048de3fd932a5aaac2a11b45be86.zip |
adding a test to ensure offsets with no limits will work [#5316 state:resolved]
Diffstat (limited to 'activerecord/test')
-rw-r--r-- | activerecord/test/cases/base_test.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/activerecord/test/cases/base_test.rb b/activerecord/test/cases/base_test.rb index 21bd61c096..e63e1fbe09 100644 --- a/activerecord/test/cases/base_test.rb +++ b/activerecord/test/cases/base_test.rb @@ -1150,6 +1150,12 @@ class BasicsTest < ActiveRecord::TestCase assert_equal 3, scoped_developers.size end + def test_no_limit_offset + assert_nothing_raised do + Developer.find(:all, :offset => 2) + end + end + def test_scoped_find_limit_offset scoped_developers = Developer.send(:with_scope, :find => { :limit => 3, :offset => 2 }) do Developer.find(:all, :order => 'id') |