Package org.xwiki.test.ui.po
Class EntityTreeElement
- java.lang.Object
-
- org.xwiki.test.ui.po.BaseElement
-
- org.xwiki.test.ui.po.EntityTreeElement
-
public class EntityTreeElement extends BaseElement
Represents the actions possible on the XWiki Explorer Tree.- Since:
- 5.1M1
- Version:
- $Id: 8df661e0f5597a6fd0d5de24023c99af44fbe075 $
-
-
Constructor Summary
Constructors Constructor Description EntityTreeElement()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
hasAttachment(String spaceName, String pageName, String fileName)
boolean
hasPage(String spaceName, String pageName)
boolean
hasPage(String spaceName, String pageName, String pageTitle)
boolean
hasSpace(String spaceName)
void
lookupEntity(String entityReference)
Types the given text in the input box below the tree.EntityTreeElement
waitForAttachment(String spaceName, String pageName, String fileName)
Waits for the node corresponding to the specified attachments to be present but not selected.EntityTreeElement
waitForAttachment(String spaceName, String pageName, String fileName, boolean selected)
Waits for the node corresponding to the specified attachment to be present.EntityTreeElement
waitForPage(String spaceName, String pageName)
Waits for the node corresponding to the specified page to be present but not selected.EntityTreeElement
waitForPage(String spaceName, String pageName, boolean selected)
Waits for the node corresponding to the specified page to be present.EntityTreeElement
waitForPage(String spaceName, String pageName, String pageTitle)
Waits for the node corresponding to the specified page to be present but not selected.EntityTreeElement
waitForPage(String spaceName, String pageName, String pageTitle, boolean selected)
Waits for the node corresponding to the specified page to be present.EntityTreeElement
waitForSpace(String spaceName)
Waits for the node corresponding to the specified space to be present but not selected.EntityTreeElement
waitForSpace(String spaceName, boolean selected)
Waits for the node corresponding to the specified space to be present.-
Methods inherited from class org.xwiki.test.ui.po.BaseElement
getDriver, getUtil, isElementVisible, setContext, waitForNotificationErrorMessage, waitForNotificationInProgressMessage, waitForNotificationSuccessMessage, waitForNotificationWarningMessage, waitUntilPageIsReady
-
-
-
-
Method Detail
-
waitForSpace
public EntityTreeElement waitForSpace(String spaceName)
Waits for the node corresponding to the specified space to be present but not selected.- Parameters:
spaceName
- the space name- Returns:
- this
-
waitForSpace
public EntityTreeElement waitForSpace(String spaceName, boolean selected)
Waits for the node corresponding to the specified space to be present.- Parameters:
spaceName
- the space nameselected
-true
if the space node should be selected,false
otherwise- Returns:
- this
-
hasSpace
public boolean hasSpace(String spaceName)
- Parameters:
spaceName
- the space name- Returns:
true
if the node corresponding to the specified space is present (selected or not),false
otherwise
-
waitForPage
public EntityTreeElement waitForPage(String spaceName, String pageName)
Waits for the node corresponding to the specified page to be present but not selected. We assume the page title equals the page name.- Parameters:
spaceName
- the space containing the pagepageName
- the page name- Returns:
- this
-
waitForPage
public EntityTreeElement waitForPage(String spaceName, String pageName, String pageTitle)
Waits for the node corresponding to the specified page to be present but not selected.- Parameters:
spaceName
- the space containing the pagepageName
- the page name (used as the node tool tip)pageTitle
- the page title (used as the node label)- Returns:
- this
-
waitForPage
public EntityTreeElement waitForPage(String spaceName, String pageName, boolean selected)
Waits for the node corresponding to the specified page to be present. We assume the page title equals the page name.- Parameters:
spaceName
- the space containing the pagepageName
- the page nameselected
-true
if the page node should be selected,false
otherwise- Returns:
- this
-
waitForPage
public EntityTreeElement waitForPage(String spaceName, String pageName, String pageTitle, boolean selected)
Waits for the node corresponding to the specified page to be present.- Parameters:
spaceName
- the space containing the pagepageName
- the page name (used as the node hint)pageTitle
- the page title (used as the node label)selected
-true
if the page node should be selected,false
otherwise- Returns:
- this
-
hasPage
public boolean hasPage(String spaceName, String pageName)
- Parameters:
spaceName
- the space containing the pagepageName
- the page name- Returns:
true
if the specified page node is present, selected or not,false
otherwise; we assume the page title equals the page name
-
hasPage
public boolean hasPage(String spaceName, String pageName, String pageTitle)
- Parameters:
spaceName
- the space containing the pagepageName
- the page name (used as the node hint)pageTitle
- the page title (used as the node label)- Returns:
true
if the specified page node is present, selected or not,false
otherwise
-
waitForAttachment
public EntityTreeElement waitForAttachment(String spaceName, String pageName, String fileName)
Waits for the node corresponding to the specified attachments to be present but not selected.- Parameters:
spaceName
- the space containing the pagepageName
- the page that holds the attachmentfileName
- the attachment file name- Returns:
- this
-
waitForAttachment
public EntityTreeElement waitForAttachment(String spaceName, String pageName, String fileName, boolean selected)
Waits for the node corresponding to the specified attachment to be present.- Parameters:
spaceName
- the space containing the pagepageName
- the page that holds the attachmentfileName
- the attachment file nameselected
-true
if the attachment node should be selected,false
otherwise- Returns:
- this
-
hasAttachment
public boolean hasAttachment(String spaceName, String pageName, String fileName)
- Parameters:
spaceName
- the space containing the pagepageName
- the page that holds the attachmentfileName
- the attachment file name- Returns:
true
if the specified attachment node is present, selected or not,false
otherwise
-
lookupEntity
public void lookupEntity(String entityReference)
Types the given text in the input box below the tree. As a result the tree will lookup an entity among its nodes (e.g. page, attachment) that matches the given reference.- Parameters:
entityReference
- the text to be typed in the input box below the tree, usually an entity reference
-
-