@Override protected void tearDown() throws Exception { rpc.logOut(); client.cleanUp(); serverStateManager = null; userHelper = null; suite = null; assertThat = null; super.tearDown(); }
@Override protected void tearDown() throws Exception { rpc.logIn(adminUser); rpc.setApplicationConfigProperty(ConfluenceAdminUiProperties.ALLOW_DAILY_BACKUP_KEY, "false"); rpc.logOut(); super.tearDown(); }
private Comment setupRpcComment() { String content = "I can't believe it's not butter"; Comment comment = new Comment(testPage, content); //add comment as test user rpc.logIn(defaultUser); rpc.createComment(comment); rpc.logOut(); return comment; }
private void setUserPermissions() { rpc.logIn(adminUser); rpc.grantPermission(GlobalPermission.UPDATE_STATUS, testUser); rpc.grantPermission(SpacePermission.COMMENT, testSpace, testUser); rpc.logOut(); }
@Override protected void tearDown() throws Exception { rpc.logIn(User.ADMIN); mailFacade.stop(); rpc.logOut(); editor = null; editorAutocomplete = null; super.tearDown(); } }
@Override protected void tearDown() throws Exception { rpc.logIn(adminUser); rpc.enableWebSudo(false); rpc.logOut(); super.tearDown(); }
@Override protected void setUp() throws Exception { super.setUp(); quickNavBox = new QuickSearch(client); rpc.logIn(adminUser); rpc.flushIndexQueue(); rpc.logOut(); }
@Override protected void setUp() throws Exception { super.setUp(); rpc.logIn(adminUser); rpc.enableWebSudo(false); rpc.logOut(); upm = new UPM(client); }
@Override protected void setUp() throws Exception { super.setUp(); rpc.logIn(adminUser); rpc.setApplicationConfigProperty(ConfluenceAdminUiProperties.ALLOW_DAILY_BACKUP_KEY, "true"); rpc.logOut(); suite.logIn(adminUser); }
private void setupUserPages() { rpc.logIn(testUser); testUserPage = new Page(testSpace, "Test Users Page", "Test Users Page"); // Extra logging added to figure out what's causing CONFDEV-1045 rpc.createPage(testUserPage); rpc.createPersonalSpace(testUser); rpc.logOut(); }
@Override protected void tearDown() throws Exception { rpc.logIn(adminUser); rpc.revokePermission(GlobalPermission.UPDATE_STATUS, testUser); rpc.revokePermission(GlobalPermission.CAN_USE, testUser); rpc.logOut(); super.tearDown(); }
@Override protected void setUp() throws Exception { super.setUp(); editor = new Editor(client, suite); tinyMce = editor.getTinyMce(); rpc.logIn(User.ADMIN); rpc.removeDrafts(testUser); rpc.logOut(); }
@Override protected void setUp() throws Exception { super.setUp(); rpc.logIn(adminUser); rpc.enableWebSudo(true); rpc.logOut(); suite.logIn(adminUser); client.open("/admin/console.action"); }
@Override protected void setUp() throws Exception { super.setUp(); this.userStatusDialog = new UserStatusDialog(client); rpc.logIn(testUser); rpc.createPersonalSpace(testUser); rpc.logIn(adminUser); rpc.grantPermission(GlobalPermission.CAN_USE, testUser); rpc.grantPermission(GlobalPermission.UPDATE_STATUS, testUser); rpc.logOut(); suite.logIn(testUser, testSpace.getHomePage()); }
public void testToolTips() { // This tests the links in the browse menu, which isn't shown in the default theme anymore rpc.logIn(adminUser); rpc.setThemeForSpace(testUserPage.getSpace(), BundledTheme.DOCUMENTATION); rpc.logOut(); suite.viewPage(testUserPage); testForToolTip("#space-pages-link", "Browse pages in the " + testSpace.getName() + " space (g , s)"); testForToolTip(".view .show-labels-editor", "Edit Labels (l)"); testForToolTip("#view-attachments-link", "View Attachments (t)"); testForToolTip("#link-to-page-link", "Link to this Page (k)"); testForToolTip("#editPageLink", "Edit (e)"); }
@Override protected void setUp() throws Exception { super.setUp(); editor = new Editor(client, suite); rpc.logIn(User.ADMIN); rpc.removeDrafts(testUser); otherSpace = new Space("OtherSpace", "OtherSpace"); rpc.createSpace(otherSpace); rpc.grantPermission(SpacePermission.VIEW, otherSpace, testUser); rpc.grantPermission(SpacePermission.PAGE_EDIT, otherSpace, testUser); pageAttachment = getAttachment(testPage); rpc.createAttachment(pageAttachment); rpc.logOut(); }
public void testLargeTree() { if (TestProperties.isOnDemandAlaCarte()) return; // create 500 pages rpc.logIn(adminUser); rpc.createPagesFromPrototype(new Page(testSpace, "Tree Page", "Some content"), 500); // flush the index queue to make sure the indexing is not done while loading the page tree rpc.flushIndexQueue(); rpc.logOut(); suite.logIn(testUser, testSpace.getPageTreeUrl(), 120000); // waits for the last node to appear 7 times the configured action wait time client.waitForCondition("$('#tree-div li > a').length >= 500", 9*ConfluenceSeleniumConfiguration.getInstance().getActionWait()); assertThat.linkVisibleWithText("Tree Page 500"); }
public void testDragToChild() { rpc.logIn(adminUser); Page homePage = testSpace.getHomePage(); final long homePageId = rpc.getPageId(homePage); homePage.setId(homePageId); Page page = createDummyPage(homePageId); rpc.logOut(); suite.logIn(testUser, testSpace.getPageTreeUrl()); assertThat.textPresent("List Pages - Tree View"); // wait for the test page node in the tree to appear first before dragging waitForPageTree(); movePageAsChild(testPage, homePage, page); client.open(testSpace.getHomePage().getUrl()); assertThat.linkPresentWithText(testPage.getTitle()); }
public void testCopyPasteEmoticons() { Page myPage = new Page(testSpace, "Emoticons in body", "Here's a sentence with a :-) emoticon"); rpc.logIn(adminUser); rpc.createPage(myPage); rpc.logOut(); suite.logIn(User.ADMIN); client.open(myPage.getUrl()); assertTrue("The test page has no emoticon on it.", client.isElementPresent("css=.wiki-content .emoticon")); String content = copyViewHtmlContent(); // Paste our copied content in to the editor client.open(myPage.getEditUrl()); editor.setContent(""); tinyMce.pasteContent(content); editor.save(); assertTrue("There is nothing that looks like an emoticon element on the page.", client.isElementPresent("css=.wiki-content .emoticon")); }
public void testHoverInComments() { rpc.logIn(adminUser); Comment adminComment = new Comment(testPage, "Comment me"); rpc.createComment(adminComment); rpc.grantPermission(SpacePermission.COMMENT, testSpace, testUser); rpc.logOut(); rpc.logIn(testUser); Comment testComment = new Comment(testPage, "Comment me"); rpc.createComment(testComment); suite.logIn(adminUser, testPage); adminUserHover.mouseOver("div[@id='comment-" + adminComment.getId() + "']"); adminUserHover.mouseOverLogo("div[@id='comment-" + adminComment.getId() + "']"); testUserHover.mouseOver("div[@id='comment-" + testComment.getId() + "']"); testUserHover.mouseOverLogo("div[@id='comment-" + testComment.getId() + "']"); }