Skip to content
Permalink
Browse files

updated pending message for ancestors to reflect that it is a bug. This

closes #3;
  • Loading branch information...
dhoss committed Nov 3, 2014
1 parent 001b901 commit 38ca2786948e6c9636b65616a20c9a77f3c2512e
Showing with 1 addition and 2 deletions.
  1. +0 −1 lib/treeify.rb
  2. +1 −1 spec/treeify_spec.rb
@@ -18,7 +18,6 @@ module Treeify
scope :roots, -> { where(parent_id: nil) }
scope :tree_for, ->(instance) { self.find_by_sql self.tree_sql_for(instance) }
scope :tree_for_ancestors, ->(instance) { self.find_by_sql self.tree_sql_for_ancestors(instance) }

end

module ClassMethods
@@ -98,9 +98,9 @@
end

it "has the correct tree after subchildren are added" do
pending "This is a bug"
tree = Node.roots.first.self_and_descendents
tree.each do |node|
pending "Ancestor count for parent nodes doesn't work yet"
if node.parent_id.nil?
expect(node.ancestors.count).to eq(0)
end

0 comments on commit 38ca278

Please sign in to comment.
You can’t perform that action at this time.