org.xwiki.test.ui.po
Class ViewPage

java.lang.Object
  extended by org.xwiki.test.ui.po.BaseElement
      extended by org.xwiki.test.ui.po.BasePage
          extended by org.xwiki.test.ui.po.ViewPage
Direct Known Subclasses:
CommentsTab, ComparePage, ConfirmationModal, ConfirmationPage, CopyConfirmationPage, CopyPage, CreatePagePage, CreateSpacePage, DeletePageOutcomePage, InlinePage, LoginPage

public class ViewPage
extends BasePage

Represents the common actions possible on all Pages when using the "view" action.

Since:
3.2M3
Version:
$Id: 7a8114717b03b1394d1a01cff1e89fdd4c895268 $

Constructor Summary
ViewPage()
           
 
Method Summary
 ViewPage clickBreadcrumbLink(String linkText)
          Clicks on the breadcrumb link with the given text.
 void clickWantedLink(String spaceName, String pageName, boolean waitForTemplateDisplay)
          Clicks on a wanted link in the page.
 WYSIWYGEditPage editSection(int sectionNumber)
           
 boolean exists()
           
 String getBreadcrumbContent()
           
 String getContent()
           
 boolean hasBreadcrumbContent(String breadcrumbItem, boolean isCurrent)
           
 boolean isInlinePage()
           
 AttachmentsPane openAttachmentsDocExtraPane()
           
 CommentsTab openCommentsDocExtraPane()
          Opens the comments tab.
 HistoryPane openHistoryDocExtraPane()
           
 void waitForDocExtraPaneActive(String paneId)
           
 void waitUntilContent(String expectedValue)
          Waits until the page has the passed content by refreshing the page
 
Methods inherited from class org.xwiki.test.ui.po.BasePage
canDelete, clickContentMenuEditSubMenuEntry, clickContentMenuTopEntry, copy, createInlinePage, createPage, createSpace, delete, edit, editClass, editInline, editObjects, editRights, editWiki, editWYSIWYG, getCurrentUser, getDocumentTitle, getEditURL, getMetaDataValue, getPageMenuLink, getPageTitle, getPageURL, hasLoginLink, isAuthenticated, isNewDocument, login, logout, register, sendKeys, waitUntilPageIsLoaded, watchDocument, watchSpace
 
Methods inherited from class org.xwiki.test.ui.po.BaseElement
executeJavascript, getDriver, getUtil, makeAlertDialogSilent, makeConfirmDialogSilent, makeElementVisible, makeElementVisible, setContext, waitForNotificationErrorMessage, waitForNotificationSuccessMessage, waitForNotificationWarningMessage, waitUntilElementDisappears, waitUntilElementEndsWithAttributeValue, waitUntilElementHasAttributeValue, waitUntilElementHasTextContent, waitUntilElementIsVisible, waitUntilElementsAreVisible
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ViewPage

public ViewPage()
Method Detail

openCommentsDocExtraPane

public CommentsTab openCommentsDocExtraPane()
Opens the comments tab.

Returns:
element for controlling the comments tab

openHistoryDocExtraPane

public HistoryPane openHistoryDocExtraPane()

openAttachmentsDocExtraPane

public AttachmentsPane openAttachmentsDocExtraPane()

exists

public boolean exists()
Returns:
does this page exist.

getContent

public String getContent()
Returns:
the page's main content as text (no HTML)

editSection

public WYSIWYGEditPage editSection(int sectionNumber)

clickWantedLink

public void clickWantedLink(String spaceName,
                            String pageName,
                            boolean waitForTemplateDisplay)
Clicks on a wanted link in the page.


getBreadcrumbContent

public String getBreadcrumbContent()

hasBreadcrumbContent

public boolean hasBreadcrumbContent(String breadcrumbItem,
                                    boolean isCurrent)

clickBreadcrumbLink

public ViewPage clickBreadcrumbLink(String linkText)
Clicks on the breadcrumb link with the given text.

Parameters:
linkText - the link text
Returns:
the target of the breadcrumb link

isInlinePage

public boolean isInlinePage()

waitForDocExtraPaneActive

public void waitForDocExtraPaneActive(String paneId)
Parameters:
paneId - valid values: "history", "comments", etc

waitUntilContent

public void waitUntilContent(String expectedValue)
Waits until the page has the passed content by refreshing the page

Parameters:
expectedValue - the content value to wait for (in regex format)
Since:
4.0M1


Copyright © 2004-2013 XWiki. All Rights Reserved.