public interface UnsupportedTypedSelenium
| Modifier and Type | Method and Description |
|---|---|
void |
attachFile(ElementLocator<?> fieldLocator,
File fileLocator)
Sets a file input (upload) field to the file listed in fileLocator
|
void |
attachFile(ElementLocator<?> fieldLocator,
URL fileLocator)
Sets a file input (upload) field to the file listed in fileLocator
|
void |
captureEntirePageScreenshot(File filename)
Saves the entire contents of the current window canvas to a PNG file.
|
void |
captureScreenshot(File filename)
Captures a PNG screenshot to the specified file.
|
List<ElementLocator<?>> |
getAllButtons()
Returns the IDs of all buttons on the page.
|
List<ElementLocator<?>> |
getAllFields()
Returns the IDs of all input fields on the page.
|
List<ElementLocator<?>> |
getAllLinks()
Returns the IDs of all links on the page.
|
List<String> |
getAllWindowNames()
Returns the names of all windows that the browser knows about.
|
List<String> |
getAllWindowTitles()
Returns the titles of all windows that the browser knows about.
|
List<String> |
getAttributeFromAllWindows(Attribute attribute)
Returns every instance of some attribute from all known windows.
|
JavaScript |
getExpression(JavaScript expression)
Returns the specified expression.
|
boolean |
getWhetherThisFrameMatchFrameExpression(String currentFrameString,
String target)
Determine whether current/locator identify the frame containing this running code.
|
boolean |
getWhetherThisWindowMatchWindowExpression(String currentWindowString,
String target)
Determine whether currentWindowString plus target identify the window containing this running code.
|
void |
setExtensionJs(JavaScript extensionJs)
Sets the per-session extension Javascript
|
void attachFile(ElementLocator<?> fieldLocator, File fileLocator)
fieldLocator - an element locatorfileLocator - a URL pointing to the specified file. Before the file can be set in the input field (fieldLocator),
Selenium RC may need to transfer the file to the local machine before attaching the file in a web page form. This
is common in selenium grid configurations where the RC server driving the browser is not the same machine that
started the test. Supported Browsers: Firefox ("*chrome") only.void attachFile(ElementLocator<?> fieldLocator, URL fileLocator)
fieldLocator - an element locatorfileLocator - a URL pointing to the specified file. Before the file can be set in the input field (fieldLocator),
Selenium RC may need to transfer the file to the local machine before attaching the file in a web page form. This
is common in selenium grid configurations where the RC server driving the browser is not the same machine that
started the test. Supported Browsers: Firefox ("*chrome") only.void captureScreenshot(File filename)
filename - the absolute path to the file to be written, e.g. "c:\blah\screenshot.png"void captureEntirePageScreenshot(File filename)
filename - the path to the file to persist the screenshot as. No filename extension will be appended by default.
Directories will not be created if they do not exist, and an exception will be thrown, possibly by native code.List<ElementLocator<?>> getAllButtons()
If a given button has no ID, it will appear as "" in this array.
List<ElementLocator<?>> getAllLinks()
If a given link has no ID, it will appear as "" in this array.
List<ElementLocator<?>> getAllFields()
If a given field has no ID, it will appear as "" in this array.
List<String> getAllWindowNames()
List<String> getAllWindowTitles()
List<String> getAttributeFromAllWindows(Attribute attribute)
attribute - name of an attribute on the windowsJavaScript getExpression(JavaScript expression)
This is useful because of JavaScript preprocessing. It is used to generate commands like assertExpression and waitForExpression.
expression - the value to returnboolean getWhetherThisFrameMatchFrameExpression(String currentFrameString, String target)
This is useful in proxy injection mode, where this code runs in every browser frame and window, and sometimes the selenium server needs to identify the "current" frame. In this case, when the test calls selectFrame, this routine is called for each frame to figure out which one has been selected. The selected frame will return true, while all others will return false.
currentFrameString - starting frametarget - new frame (which might be relative to the current one)boolean getWhetherThisWindowMatchWindowExpression(String currentWindowString, String target)
This is useful in proxy injection mode, where this code runs in every browser frame and window, and sometimes the selenium server needs to identify the "current" window. In this case, when the test calls selectWindow, this routine is called for each window to figure out which one has been selected. The selected window will return true, while all others will return false.
currentWindowString - starting windowtarget - new window (which might be relative to the current one, e.g., "_parent")void setExtensionJs(JavaScript extensionJs)
extensionJs - Copyright © 2012 JBoss by Red Hat. All Rights Reserved.