コード例 #1
0
ファイル: SuperUserTest.php プロジェクト: Benjen/red_test
 /**
  * Make sure that superuser is able to delete his own comment.
  */
 public function testCommentDelete()
 {
     $commentDeleteForm = new CommentConfirmDelete(self::$articleCommentObject->getId());
     $commentDeleteForm->submit()->verify($this);
     $articleCommentObject = new ArticleComment(self::$articleCommentObject->getId());
     $this->assertFalse($articleCommentObject->getInitialized(), "Superuser is not able to delete his own comment.");
 }
コード例 #2
0
ファイル: AnonymousUserTest.php プロジェクト: Benjen/red_test
 /**
  * Make sure that anonymous user is not able to delete a comment.
  */
 public function testCommentDeleteAccess()
 {
     $path = new Path('comment/' . self::$articleCommentObject->getId() . '/delete');
     $this->assertFalse($path->hasAccess(), "Authenticated user is able to delete a comment.");
 }