public class FinderWebDriverSubStepImplementations extends AbstractWebDriverSubStepImplementations
| Constructor and Description |
|---|
FinderWebDriverSubStepImplementations() |
| Modifier and Type | Method and Description |
|---|---|
void |
checkElements(String msg,
List<org.openqa.selenium.WebElement> tagElems) |
org.openqa.selenium.WebElement |
findById(String id)
Find an element by it's ID
|
org.openqa.selenium.WebElement |
findById(String id,
String timeout)
Find an element by it's ID with the specified timeout
|
void |
findByIdAndText(String id,
String expected)
Find the element with id that has the text ....
|
org.openqa.selenium.WebElement |
findByName(String name)
Find an element using the name attribute of the element
|
org.openqa.selenium.WebElement |
findByTagAndAttributes(String tag,
String attributeString)
Find an element by tag name and a set of attributes and corresponding
values
|
org.openqa.selenium.WebElement |
findByTagAndAttributesWithText(String tag,
String attributeString,
String text)
Find an element by tag name and a set of attributes and corresponding
values
|
void |
findByXpath(String xpath)
Find an id by xpath
|
org.openqa.selenium.WebElement |
findCheckBox(String tag,
String label)
Finds a checkbox that is a child of the specified tag, that contains the
specified text; eg.
|
org.openqa.selenium.WebElement |
findChildByName(String name)
Finds an element that is a child of the current element using the name
attribute, another Find method should be used first
|
org.openqa.selenium.WebElement |
findChildByTagAndAttributes(String tag,
String attributeString)
Finds an element that is a child of the current element using the tag
name and specified attributes, another Find method should be used first
|
org.openqa.selenium.WebElement |
findChildByTagAndAttributesWithText(String tag,
String attributeString,
String text)
Finds an element that is a child of the current element using the tag
name, specified attributes and text, another Find method should be used first
|
void |
findChildElementContainingText(String xpath,
String text)
From the current element, apply the xpath selecting the first child that
has the text ...
|
org.openqa.selenium.WebElement |
findElementWithText(String type,
String text)
Gets the element with text.
|
org.openqa.selenium.WebElement |
findFirstByTagAndAttributes(String tag,
String attributeString)
Finds the first element by tag name and a set of attributes and
corresponding values
|
org.openqa.selenium.WebElement |
findFirstChildByTagAndAttributes(String tag,
String attributeString)
Finds the first child element of the 'current' element using the tag name
and specified attributes, another Find method should be used first
|
void |
findFirstTagElementContainingText(String tag,
String text)
Finds an element on the page with the specified tag and containing the specified text
|
void |
findFirstTagElementStartingWithText(String tag,
String text)
Finds the first html tag that starts with the specified text
|
org.openqa.selenium.WebElement |
findInputInsideTag(String label,
String tag,
String inputType) |
org.openqa.selenium.WebElement |
findNthByTagAndAttributes(Integer nth,
String tag,
String attributeString)
Finds the n th element by tag name and a set of attributes and
corresponding values
|
org.openqa.selenium.WebElement |
findParentByTagAndAttributesThatHasChildWithTagAndAttributes(String tag,
String attributeString,
String childTag,
String childAttributeString)
Finds an element by tag name and a set of attributes and corresponding
values, that has a child tag element of the specified type that has the
specified attributes..
|
org.openqa.selenium.WebElement |
findParentByTagAndAttributesThatHasChildWithTagAndText(String tag,
String attributeString,
String childTag,
String childText)
Finds an element by tag name and a set of attributes and corresponding
values, that has a child tag element of the specified type and having the
specified text
|
org.openqa.selenium.WebElement |
findRadioButton(String tag,
String label)
Finds a radiobutton that is a child of the specified tag, that contains
the specified text; eg.
|
void |
findTagElementWithExactText(String tag,
String text)
Finds an element on the page with the specified tag and text
|
elementHasExpectedAttributes, getScreenshotBytes, webDriver, webDriverContextpublic FinderWebDriverSubStepImplementations()
public org.openqa.selenium.WebElement findById(String id)
id - the idpublic org.openqa.selenium.WebElement findById(String id, String timeout)
id - the idtimeout - the timeoutpublic void findByXpath(String xpath)
xpath - the xpathpublic org.openqa.selenium.WebElement findByName(String name)
name - the namepublic void findFirstTagElementContainingText(String tag, String text)
tag - the tagtext - the textpublic void findTagElementWithExactText(String tag, String text)
tag - the tagtext - the textpublic org.openqa.selenium.WebElement findChildByName(String name)
name - the namepublic org.openqa.selenium.WebElement findChildByTagAndAttributes(String tag, String attributeString)
tag - the tagattributeString - the attribute stringpublic org.openqa.selenium.WebElement findChildByTagAndAttributesWithText(String tag, String attributeString, String text)
tag - the tagattributeString - the attribute stringtext - the text to look forpublic org.openqa.selenium.WebElement findFirstChildByTagAndAttributes(String tag, String attributeString)
tag - the tagattributeString - the attribute stringpublic org.openqa.selenium.WebElement findCheckBox(String tag, String label)
tag - the taglabel - the checkbox labelpublic org.openqa.selenium.WebElement findRadioButton(String tag, String label)
tag - the taglabel - the radio button labelpublic org.openqa.selenium.WebElement findInputInsideTag(String label, String tag, String inputType)
label - the label of the inputtag - the taginputType - the input typepublic void checkElements(String msg, List<org.openqa.selenium.WebElement> tagElems)
msg - the assertion messagetagElems - the element list to be checked for empty or nullpublic org.openqa.selenium.WebElement findByTagAndAttributes(String tag, String attributeString)
tag - the tagattributeString - the attribute stringpublic org.openqa.selenium.WebElement findFirstByTagAndAttributes(String tag, String attributeString)
tag - the tagattributeString - the attribute stringpublic org.openqa.selenium.WebElement findNthByTagAndAttributes(Integer nth, String tag, String attributeString)
nth - the nth matching element we wish to findtag - the tagattributeString - the attribute stringpublic org.openqa.selenium.WebElement findParentByTagAndAttributesThatHasChildWithTagAndText(String tag, String attributeString, String childTag, String childText)
tag - the parent tagattributeString - the parent attribute stringchildTag - the child tagchildText - the child's textpublic org.openqa.selenium.WebElement findParentByTagAndAttributesThatHasChildWithTagAndAttributes(String tag, String attributeString, String childTag, String childAttributeString)
tag - the parent tagattributeString - the parent attribute stringchildTag - the child tagchildAttributeString - the child's attribute stringpublic org.openqa.selenium.WebElement findElementWithText(String type, String text)
type - the typetext - the textpublic void findByIdAndText(String id, String expected)
id - the idexpected - the expectedpublic void findChildElementContainingText(String xpath, String text)
xpath - the xpathtext - the textpublic void findFirstTagElementStartingWithText(String tag, String text)
tag - the tagtext - the textpublic org.openqa.selenium.WebElement findByTagAndAttributesWithText(String tag, String attributeString, String text)
tag - the tagattributeString - the attribute stringtext - the expected textCopyright © 2016 Substeps. All rights reserved.