Package org.xwiki.flamingo.test.po
Class PreviewBox
- java.lang.Object
-
- org.xwiki.test.ui.po.BaseElement
-
- org.xwiki.test.ui.po.BasePage
-
- org.xwiki.test.ui.po.ViewPage
-
- org.xwiki.flamingo.test.po.PreviewBox
-
public class PreviewBox extends ViewPage
Represents the preview iframe of when customizing a theme. Be careful when using it: the context is switched to be inside the iframe when the box is created. You need to call explicitelyswitchToDefaultContent()
to come back on the main frame.- Version:
- $Id: fc5065b5a236f3b7ab1e7f78f20a42045764e00f $
-
-
Constructor Summary
Constructors Constructor Description PreviewBox()
Default constructor: it switches automatically inside the iframe (seeswitchToPreviewBox()
).
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
hasError()
boolean
hasError(boolean switchBack)
void
switchToDefaultContent()
Switch to the main frame.void
switchToPreviewBox()
Switch the selenium context inside the iframe.-
Methods inherited from class org.xwiki.test.ui.po.ViewPage
clickBreadcrumbLink, clickWantedLink, clickWantedLink, contentContainsElement, editSection, exists, getBreadcrumb, getBreadcrumbContent, getContent, getLastModifiedText, getPageBackgroundColor, getTitleColor, getTitleFontFamily, getTranslateButton, hasBreadcrumbContent, hasBreadcrumbContent, hasTranslateButton, isInlinePage, openCommentsDocExtraPane, openHistoryDocExtraPane, openInformationDocExtraPane, scrollToTop, useShortcutForDocExtraPane, useShortcutKeyForCommentPane, useShortcutKeyForHistoryPane, useShortcutKeyForInformationPane, waitForDocExtraPaneActive, waitUntilContent
-
Methods inherited from class org.xwiki.test.ui.po.BasePage
canDelete, clickAdminActionsSubMenuEntry, clickEditSubMenuEntry, clickLocale, clickMoreActionsSubMenuEntry, copy, createInlinePage, createPage, delete, deletePage, edit, editClass, editInline, editObjects, editRights, editWiki, editWYSIWYG, getCurrentUser, getDocumentTitle, getDrawerMenu, getEditURL, getErrorContent, getHTMLMetaDataValue, getLocales, getMetaDataValue, getPageTitle, getPageURL, getXWikiMessageContent, hasLeftPanel, hasLoginLink, hasNotificationsMenu, hasRenderingError, isAuthenticated, isForbidden, isNewDocument, isNotificationsMenuOpen, login, logout, register, reloadPage, rename, sendKeys, toggleActionMenu, toggleNotificationsMenu, useShortcutKeyForClassEditing, useShortcutKeyForEditing, useShortcutKeyForInlineEditing, useShortcutKeyForObjectEditing, useShortcutKeyForPageDeletion, useShortcutKeyForPageRenaming, useShortcutKeyForRightsEditing, useShortcutKeyForSourceViewer, useShortcutKeyForWikiEditing, useShortcutKeyForWysiwygEditing, validateWCAG, validateWCAG, validateWCAG, viewChildren, watchDocument, watchSpace, watchWiki
-
Methods inherited from class org.xwiki.test.ui.po.BaseElement
getDriver, getUtil, isElementVisible, setContext, waitForNotificationErrorMessage, waitForNotificationInProgressMessage, waitForNotificationSuccessMessage, waitForNotificationWarningMessage, waitUntilPageIsReady
-
-
-
-
Constructor Detail
-
PreviewBox
public PreviewBox()
Default constructor: it switches automatically inside the iframe (seeswitchToPreviewBox()
).
-
-
Method Detail
-
switchToPreviewBox
public void switchToPreviewBox()
Switch the selenium context inside the iframe. CallswitchToDefaultContent()
to switch out.
-
switchToDefaultContent
public void switchToDefaultContent()
Switch to the main frame.
-
hasError
public boolean hasError()
-
hasError
public boolean hasError(boolean switchBack)
- Parameters:
switchBack
- set to true to automatically callswitchToDefaultContent()
after the return.- Returns:
true
if the box contain less errors.
-
-