summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorcweiske <cweiske@b3834d28-1941-0410-a4f8-b48e95affb8f>2009-11-19 19:22:21 +0000
committercweiske <cweiske@b3834d28-1941-0410-a4f8-b48e95affb8f>2009-11-19 19:22:21 +0000
commit563df90c75d6615ea491cba6cb0b97010bac3af0 (patch)
treede5419ee89d3586b20c1788513c2f12eb4fbea14 /tests
parentc93455201a37961cdf978c8505e21dbfc64b5974 (diff)
downloadsemanticscuttle-563df90c75d6615ea491cba6cb0b97010bac3af0.tar.gz
semanticscuttle-563df90c75d6615ea491cba6cb0b97010bac3af0.tar.bz2
fix notice when passing an invalid array to editAllowed()
git-svn-id: https://semanticscuttle.svn.sourceforge.net/svnroot/semanticscuttle/trunk@558 b3834d28-1941-0410-a4f8-b48e95affb8f
Diffstat (limited to 'tests')
-rw-r--r--tests/BookmarkTest.php54
1 files changed, 54 insertions, 0 deletions
diff --git a/tests/BookmarkTest.php b/tests/BookmarkTest.php
index 9f02ae6..b99dfd7 100644
--- a/tests/BookmarkTest.php
+++ b/tests/BookmarkTest.php
@@ -270,6 +270,60 @@ class BookmarkTest extends TestBase
/**
+ * Test if editAllowed() returns false when the bookmark
+ * id is invalid.
+ *
+ * @return void
+ */
+ public function testEditAllowedInvalidBookmarkId()
+ {
+ $this->assertFalse($this->bs->editAllowed('invalid'));
+ $this->assertFalse($this->bs->editAllowed(array()));
+ $this->assertFalse($this->bs->editAllowed(array('some', 'where')));
+ $this->assertFalse($this->bs->editAllowed(array('bId' => false)));
+ $this->assertFalse($this->bs->editAllowed(array('bId' => 'foo')));
+ }
+
+
+
+ /**
+ * Test if editAllowed() works when passing the ID of
+ * an existing bookmark.
+ *
+ * @return void
+ */
+ public function testEditAllowedBookmarkId()
+ {
+ }
+
+
+
+ /**
+ * Test if editAllowed() works when passing a bookmark
+ * row.
+ *
+ * @return void
+ */
+ public function testEditAllowedBookmarkRow()
+ {
+ }
+
+
+
+ /**
+ * Test if editAllowed() returns false when the bookmark
+ * specified by the ID does not exist.
+ *
+ * @return void
+ */
+ public function testEditAllowedIdNotFound()
+ {
+ $this->assertFalse($this->bs->editAllowed(98765));
+ }
+
+
+
+ /**
* Verify that getBookmark() returns false when the
* bookmark cannot be found.
*