diff options
author | David Heinemeier Hansson <david@envy8.local> | 2008-04-28 13:27:52 -0500 |
---|---|---|
committer | David Heinemeier Hansson <david@envy8.local> | 2008-04-28 13:27:52 -0500 |
commit | 0a6980f2dc6ef8b211323e0655f41702a4ce3eae (patch) | |
tree | 8160d06eb90fc794449d8e78a5b280b4136dc4bd /activerecord/test/cases | |
parent | 850aba5473ce14edcd067f16badfa198e2070095 (diff) | |
download | rails-0a6980f2dc6ef8b211323e0655f41702a4ce3eae.tar.gz rails-0a6980f2dc6ef8b211323e0655f41702a4ce3eae.tar.bz2 rails-0a6980f2dc6ef8b211323e0655f41702a4ce3eae.zip |
Let Base.all use conditions etc like first/last
Diffstat (limited to 'activerecord/test/cases')
-rwxr-xr-x | activerecord/test/cases/base_test.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/activerecord/test/cases/base_test.rb b/activerecord/test/cases/base_test.rb index 45d47837a4..93719c710a 100755 --- a/activerecord/test/cases/base_test.rb +++ b/activerecord/test/cases/base_test.rb @@ -1630,6 +1630,10 @@ class BasicsTest < ActiveRecord::TestCase def test_last assert_equal Developer.find(:first, :order => 'id desc'), Developer.last end + + def test_all_with_conditions + assert_equal Developer.find(:all, :order => 'id desc'), Developer.all(:order => 'id desc') + end def test_find_ordered_last last = Developer.find :last, :order => 'developers.salary ASC' |