Examples of postComment()


Examples of com.ourlinc.helloworld.model.Activity.postComment()

    if (null == act || null == content) {
      request.setAttribute("errorMsg", "找不到id=" + actId + "的活动");
      return "error";
    }
    content = Misc.escapeHTML(content);
    Comment com = act.postComment(user, content);
    com.flush();
    response.sendRedirect("../activity/activity.jspx?actId="
        + URLEncoder.encode(actId, "utf-8"));
    return null;
  }
View Full Code Here

Examples of org.xwiki.test.ui.framework.elements.CommentsTab.postComment()

    public void testPostCommentAsGuestNoJs()
    {
        getUtil().gotoPage(SPACE_NAME, DOC_NAME, "view", "xpage=xpart&vm=commentsinline.vm");
        CommentsTab commentsTab = new CommentsTab();

        commentsTab.postComment(COMMENT_CONTENT, false);
        // This opens with ?viewer=comments, don't explicitly load the comments tab
        new ViewPage().waitUntilPageIsLoaded();
        Assert.assertEquals(COMMENT_CONTENT,
            commentsTab.getCommentContentByID(commentsTab.getCommentID(COMMENT_CONTENT)));
        Assert.assertEquals(COMMENT_AUTHOR,
View Full Code Here

Examples of org.xwiki.test.ui.po.CommentsTab.postComment()

    public void testPostCommentAsGuestNoJs()
    {
        getUtil().gotoPage(getTestClassName(), getTestMethodName(), "view", "xpage=xpart&vm=commentsinline.vm");
        CommentsTab commentsTab = new CommentsTab();

        commentsTab.postComment(COMMENT_CONTENT, false);
        // This opens with ?viewer=comments, don't explicitly load the comments tab
        new ViewPage().waitUntilPageIsLoaded();
        Assert.assertEquals(COMMENT_CONTENT,
            commentsTab.getCommentContentByID(commentsTab.getCommentID(COMMENT_CONTENT)));
        Assert.assertEquals(COMMENT_AUTHOR,
View Full Code Here

Examples of org.xwiki.test.ui.po.CommentsTab.postComment()

        // Add comments.
        getUtil().createUserAndLogin("Alice", "ecila");
        testPage = getUtil().gotoPage(getTestClassName(), pageName);
        CommentsTab commentsTab = testPage.openCommentsDocExtraPane();
        commentsTab.postComment("first line\nsecond line", true);
        commentsTab.editCommentByID(0, "first line\nline in between\nsecond line");
        commentsTab.replyToCommentByID(0, "this is a reply");
        commentsTab.deleteCommentByID(1);
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.