summaryrefslogtreecommitdiff
path: root/modules/gallery/tests/Access_Helper_Test.php
diff options
context:
space:
mode:
authorBharat Mediratta <bharat@menalto.com>2009-12-17 21:32:53 -0800
committerBharat Mediratta <bharat@menalto.com>2009-12-17 21:32:53 -0800
commit0736cf203b37534848482e47c3afde9b58d6ce27 (patch)
tree846d748802eefe7cb641ae9a2f24e80a4707e0ee /modules/gallery/tests/Access_Helper_Test.php
parent9d19e272d672ffc224dfed2799f8e480ecb583e4 (diff)
In Kohana 2.4, ORM no longer does the find_all() call for us when we
retrieve related ORMs. If we tack a find_all() on the end, it breaks the User_Definition interface so create User_Model::groups() and Groups_Model::users() as glue.
Diffstat (limited to 'modules/gallery/tests/Access_Helper_Test.php')
-rw-r--r--modules/gallery/tests/Access_Helper_Test.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/modules/gallery/tests/Access_Helper_Test.php b/modules/gallery/tests/Access_Helper_Test.php
index 771c6a85..799d5e44 100644
--- a/modules/gallery/tests/Access_Helper_Test.php
+++ b/modules/gallery/tests/Access_Helper_Test.php
@@ -76,7 +76,7 @@ class Access_Helper_Test extends Unit_Test_Case {
access::deny(identity::registered_users(), "view", $item);
$user = identity::create_user("access_test", "Access Test", "");
- foreach ($user->groups as $group) {
+ foreach ($user->groups() as $group) {
$user->remove($group);
}
$user->add($access_test);
@@ -93,7 +93,7 @@ class Access_Helper_Test extends Unit_Test_Case {
access::deny(identity::registered_users(), "view", $item);
$user = identity::create_user("access_test", "Access Test", "");
- foreach ($user->groups as $group) {
+ foreach ($user->groups() as $group) {
$user->remove($group);
}
$user->save();
@@ -288,7 +288,7 @@ class Access_Helper_Test extends Unit_Test_Case {
public function i_can_edit_test() {
// Create a new user that belongs to no groups
$user = identity::create_user("access_test", "Access Test", "");
- foreach ($user->groups as $group) {
+ foreach ($user->groups() as $group) {
$user->remove($group);
}
$user->save();