Commit 018e71a8 by Rocky Duan

don't really need depth

parent 5122a9a6
...@@ -91,13 +91,11 @@ describe "app" do ...@@ -91,13 +91,11 @@ describe "app" do
c["created_at"].should_not be_nil c["created_at"].should_not be_nil
c["updated_at"].should_not be_nil c["updated_at"].should_not be_nil
c["children"].length.should == 2 c["children"].length.should == 2
c["depth"].should == 1
children = c["children"].reject{|comment| comment["title"] != "comment title 0"}.first children = c["children"].reject{|comment| comment["title"] != "comment title 0"}.first
children.should_not be_nil children.should_not be_nil
children["id"].should == sub_comment[0].id children["id"].should == sub_comment[0].id
children["created_at"].should_not be_nil children["created_at"].should_not be_nil
children["updated_at"].should_not be_nil children["updated_at"].should_not be_nil
children["depth"].should == 2
end end
end end
describe "GET on /api/v1/comments/:comment_id" do describe "GET on /api/v1/comments/:comment_id" do
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment