diff options
author | Bharat Mediratta <bharat@menalto.com> | 2008-12-07 08:46:44 +0000 |
---|---|---|
committer | Bharat Mediratta <bharat@menalto.com> | 2008-12-07 08:46:44 +0000 |
commit | bf7ab8904aa9ccbb201b1ef9634a8b13834e5f6d (patch) | |
tree | d62ae674a2a81696420ef293b0a033605c84da02 /core/tests/Access_Helper_Test.php | |
parent | e40b54a4689f1565e0f76c536d0d4b05b23afc1e (diff) |
Change ORM_MPTT::add_to_parent() to take an ORM instead of an id so
that it's consistent with ORM_MPTT::move_to()
Diffstat (limited to 'core/tests/Access_Helper_Test.php')
-rw-r--r-- | core/tests/Access_Helper_Test.php | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/core/tests/Access_Helper_Test.php b/core/tests/Access_Helper_Test.php index 0f453f15..c924575d 100644 --- a/core/tests/Access_Helper_Test.php +++ b/core/tests/Access_Helper_Test.php @@ -50,7 +50,8 @@ class Access_Helper_Test extends Unit_Test_Case { } public function adding_and_removing_items_adds_ands_removes_rows_test() { - $item = ORM::factory("item")->add_to_parent(1); + $root = ORM::factory("item", 1); + $item = ORM::factory("item")->add_to_parent($root); // Simulate an event access::add_item($item); @@ -70,7 +71,8 @@ class Access_Helper_Test extends Unit_Test_Case { } public function can_allow_deny_and_reset_intent_test() { - $item = ORM::factory("item")->add_to_parent(1); + $root = ORM::factory("item", 1); + $item = ORM::factory("item")->add_to_parent($root); access::add_item($item); $intent = ORM::factory("access_intent")->where("item_id", $item->id)->find(); |