From 3fb1e130b9428235e73a7b530761b9cd438d7f80 Mon Sep 17 00:00:00 2001 From: hukl Date: Wed, 9 Sep 2009 12:34:19 +0200 Subject: uhm yeah - well it was finally time to validate the uniqueness of slugs scoped to the parent_id. Who though it wasn't there already? --- test/unit/node_test.rb | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'test/unit/node_test.rb') diff --git a/test/unit/node_test.rb b/test/unit/node_test.rb index 50c2dd2..ee4d71f 100644 --- a/test/unit/node_test.rb +++ b/test/unit/node_test.rb @@ -98,14 +98,14 @@ class NodeTest < ActiveSupport::TestCase end def test_create_new_draft_of_published_page - node = Node.create :slug => "third_child" + node = Node.create :slug => "xyz" node.move_to_child_of @root assert node.publish_draft! end def test_find_or_create_draft_if_no_draft_exists - node = Node.create :slug => "third_child" + node = Node.create :slug => "xyz" node.move_to_child_of @root node.publish_draft! @@ -113,7 +113,7 @@ class NodeTest < ActiveSupport::TestCase end def test_find_or_create_draft_if_draft_exists_and_is_owned_by_user - node = Node.create :slug => "third_child" + node = Node.create :slug => "xyz" node.move_to_child_of @root node.publish_draft! @@ -122,7 +122,7 @@ class NodeTest < ActiveSupport::TestCase end def test_exception_if_draft_exists_but_locked_by_another_user - node = Node.create :slug => "third_child" + node = Node.create :slug => "xyz" node.move_to_child_of @root node.publish_draft! node.find_or_create_draft @user1 -- cgit v1.3