diff options
author | David Heinemeier Hansson <david@loudthinking.com> | 2004-12-31 16:58:50 +0000 |
---|---|---|
committer | David Heinemeier Hansson <david@loudthinking.com> | 2004-12-31 16:58:50 +0000 |
commit | 9a5321fccfa95719732eec664f5d2f25e5e6cde4 (patch) | |
tree | 974d15fcd62c3c89bf3d29af310a49605999f6ee | |
parent | f0a3397c47c557b80be516f4236a13afc7b7f65e (diff) | |
download | rails-9a5321fccfa95719732eec664f5d2f25e5e6cde4.tar.gz rails-9a5321fccfa95719732eec664f5d2f25e5e6cde4.tar.bz2 rails-9a5321fccfa95719732eec664f5d2f25e5e6cde4.zip |
Added tests for acts_as_list with scope is null #378 [Tim Bates]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@292 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
-rw-r--r-- | activerecord/test/mixin_test.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/activerecord/test/mixin_test.rb b/activerecord/test/mixin_test.rb index db9695930e..c58607f86c 100644 --- a/activerecord/test/mixin_test.rb +++ b/activerecord/test/mixin_test.rb @@ -137,6 +137,12 @@ class ListTest < Test::Unit::TestCase assert new.first? assert new.last? end + + def test_nil_scope + new1, new2, new3 = ListMixin.create, ListMixin.create, ListMixin.create + new2.move_higher + assert_equal [new2, new1, new3], ListMixin.find_all("parent_id IS NULL", "pos") + end end class TreeTest < Test::Unit::TestCase |