org.specrunner.webdriver.assertions
Class PluginCompareTable
java.lang.Object
org.specrunner.parameters.core.ParameterHolder
org.specrunner.plugins.core.AbstractPlugin
org.specrunner.plugins.core.AbstractPluginNamed
org.specrunner.plugins.core.AbstractPluginScoped
org.specrunner.plugins.core.AbstractPluginValue
org.specrunner.webdriver.AbstractPluginBrowserAware
org.specrunner.webdriver.AbstractPluginFind
org.specrunner.webdriver.AbstractPluginFindSingle
org.specrunner.webdriver.assertions.PluginCompareTable
- All Implemented Interfaces:
- IParameterHolder, IActionType, IParalelPlugin, IPlugin, ISleepPlugin, ITestPlugin, ITimedPlugin, IWaitPlugin
public class PluginCompareTable
- extends AbstractPluginFindSingle
Compare tables.
- Author:
- Thiago Santos
|
Method Summary |
protected boolean |
compareTable(IContext context,
IResultSet result,
org.openqa.selenium.WebDriver client,
org.openqa.selenium.WebElement element,
nu.xom.Node node)
Compare a table. |
protected boolean |
compareTerminal(IPlugin plugin,
IContext context,
IResultSet result,
org.openqa.selenium.WebDriver client,
CellAdapter expected,
org.openqa.selenium.WebElement received)
Compare terminal nodes of tables. |
ActionType |
getActionType()
|
static boolean |
isTable(INodeHolder holder)
Return if a given element is a table. |
protected void |
process(IContext context,
IResultSet result,
org.openqa.selenium.WebDriver client,
org.openqa.selenium.WebElement element)
Method delegation which receives the selected element to be used by
subclasses. |
| Methods inherited from class org.specrunner.webdriver.AbstractPluginBrowserAware |
doEnd, getBrowserName, getDir, getDownload, getInterval, getMaxwait, getWaitCondition, getWaitfor, isWaitForClient, setDir, setDownload, setInterval, setMaxwait, setWaitfor, waitForClient |
| Methods inherited from class org.specrunner.plugins.core.AbstractPlugin |
copy, doStart, getCondition, getConditionModel, getNormalized, getNormalized, getParent, getSleep, getSleepModel, getThreadsafe, getTimeout, getTimeoutModel, getWait, getWaitModel, setCondition, setConditionModel, setNormalized, setParent, setSleep, setSleepModel, setThreadsafe, setTimeout, setTimeoutModel, setWait, setWaitModel, toString |
PluginCompareTable
public PluginCompareTable()
getActionType
public ActionType getActionType()
process
protected void process(IContext context,
IResultSet result,
org.openqa.selenium.WebDriver client,
org.openqa.selenium.WebElement element)
throws PluginException
- Description copied from class:
AbstractPluginFindSingle
- Method delegation which receives the selected element to be used by
subclasses.
- Specified by:
process in class AbstractPluginFindSingle
- Parameters:
context - The test context.result - A result set.client - The browser.element - The selected element.
- Throws:
PluginException - On execution errors.
compareTable
protected boolean compareTable(IContext context,
IResultSet result,
org.openqa.selenium.WebDriver client,
org.openqa.selenium.WebElement element,
nu.xom.Node node)
throws PluginException
- Compare a table.
- Parameters:
context - The context.result - The result.client - The client.element - The element.node - The node.
- Returns:
- The result of comparison.
- Throws:
PluginException - On evaluation error.
compareTerminal
protected boolean compareTerminal(IPlugin plugin,
IContext context,
IResultSet result,
org.openqa.selenium.WebDriver client,
CellAdapter expected,
org.openqa.selenium.WebElement received)
throws PluginException
- Compare terminal nodes of tables.
- Parameters:
plugin - The source plugin.context - The context.result - The result set.client - The web driver.expected - The expected value.received - The received value.
- Returns:
- true, if equals, false, otherwise.
- Throws:
PluginException - On comparison errors.
isTable
public static boolean isTable(INodeHolder holder)
- Return if a given element is a table.
- Parameters:
holder - The element type.
- Returns:
- true, if table, false otherwise.
Copyright © 2013. All rights reserved.