diff options
Diffstat (limited to 'modules/gallery/tests/Access_Helper_Test.php')
-rw-r--r-- | modules/gallery/tests/Access_Helper_Test.php | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/modules/gallery/tests/Access_Helper_Test.php b/modules/gallery/tests/Access_Helper_Test.php index d90d7ed6..771c6a85 100644 --- a/modules/gallery/tests/Access_Helper_Test.php +++ b/modules/gallery/tests/Access_Helper_Test.php @@ -106,15 +106,15 @@ class Access_Helper_Test extends Unit_Test_Case { $item = album::create($root, rand(), "test album"); // New rows exist - $this->assert_true(ORM::factory("access_cache")->where("item_id", $item->id)->find()->loaded()); - $this->assert_true(ORM::factory("access_intent")->where("item_id", $item->id)->find()->loaded()); + $this->assert_true(ORM::factory("access_cache")->where("item_id", "=", $item->id)->find()->loaded()); + $this->assert_true(ORM::factory("access_intent")->where("item_id", "=", $item->id)->find()->loaded()); // Delete the item $item->delete(); // Rows are gone - $this->assert_false(ORM::factory("access_cache")->where("item_id", $item->id)->find()->loaded()); - $this->assert_false(ORM::factory("access_intent")->where("item_id", $item->id)->find()->loaded()); + $this->assert_false(ORM::factory("access_cache")->where("item_id", "=", $item->id)->find()->loaded()); + $this->assert_false(ORM::factory("access_intent")->where("item_id", "=", $item->id)->find()->loaded()); } public function new_photos_inherit_parent_permissions_test() { @@ -131,7 +131,7 @@ class Access_Helper_Test extends Unit_Test_Case { public function can_allow_deny_and_reset_intent_test() { $root = ORM::factory("item", 1); $album = album::create($root, rand(), "test album"); - $intent = ORM::factory("access_intent")->where("item_id", $album)->find(); + $intent = ORM::factory("access_intent")->where("item_id", "=", $album)->find(); // Allow access::allow(identity::everybody(), "view", $album); @@ -141,19 +141,19 @@ class Access_Helper_Test extends Unit_Test_Case { access::deny(identity::everybody(), "view", $album); $this->assert_same( access::DENY, - ORM::factory("access_intent")->where("item_id", $album)->find()->view_1); + ORM::factory("access_intent")->where("item_id", "=", $album)->find()->view_1); // Allow again. If the initial value was allow, then the first Allow clause above may not // have actually changed any values. access::allow(identity::everybody(), "view", $album); $this->assert_same( access::ALLOW, - ORM::factory("access_intent")->where("item_id", $album)->find()->view_1); + ORM::factory("access_intent")->where("item_id", "=", $album)->find()->view_1); access::reset(identity::everybody(), "view", $album); $this->assert_same( null, - ORM::factory("access_intent")->where("item_id", $album)->find()->view_1); + ORM::factory("access_intent")->where("item_id", "=", $album)->find()->view_1); } public function cant_reset_root_item_test() { |