Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

test improved to consistency

  • Loading branch information...
commit 33fe81b4e1fd2977d5a10165f34c59241a28ba34 1 parent de34c81
unknown authored
Showing with 6 additions and 2 deletions.
  1. +6 −2 test/has_ancestry_test.rb
View
8 test/has_ancestry_test.rb
@@ -296,6 +296,10 @@ def test_orphan_rootify_strategy
end
end
end
+
+ def test_orphan_parentify_strategy
+
+ end
def test_orphan_destroy_strategy
AncestryTestDatabase.with_model :depth => 3, :width => 3 do |model, roots|
@@ -334,8 +338,8 @@ def test_orphan_parentify_strategy
n5 = model.create!(:parent => n4)
# delete a node with desecendants
n2.destroy
- assert_equal(model.find(3).parent,n1, "orphan's not parentified as excepted" )
- assert_equal(model.find(5).ancestor_ids,[n1.id,n4.id], "ancestry integrity not maintained")
+ assert_equal(model.find(n5.id).ancestor_ids,[n1.id,n4.id], "ancestry integrity not maintained")
+ assert_equal(model.find(n3.id).parent,n1, "orphan's not parentified" )
end
end
Please sign in to comment.
Something went wrong with that request. Please try again.