Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

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
  • Loading branch information...
commit 9a5321fccfa95719732eec664f5d2f25e5e6cde4 1 parent f0a3397
@dhh dhh authored
Showing with 6 additions and 0 deletions.
  1. +6 −0 activerecord/test/mixin_test.rb
View
6 activerecord/test/mixin_test.rb
@@ -137,6 +137,12 @@ def test_with_string_based_scope
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
Please sign in to comment.
Something went wrong with that request. Please try again.