| Modifier and Type | Field and Description |
|---|---|
static org.openqa.selenium.WebDriver |
driver |
| Constructor and Description |
|---|
InBrowserSinglton() |
| Modifier and Type | Method and Description |
|---|---|
static org.openqa.selenium.WebElement |
clickAt(Path el)
Click on the location of the element that corresponds to the given path.
|
static org.openqa.selenium.WebElement |
clickOn(Path el)
Click on the element that corresponds to the given path.
|
static void |
doubleClickOn(Path el)
Doubleclick on the element that corresponds to the given path.
|
static Operations.DragAndDrop |
dragAndDrop(Path path)
Drag and drop in the browser.
|
static org.openqa.selenium.WebElement |
find(Path el)
Equivalent to WebDriver.findElement().
|
static List<org.openqa.selenium.WebElement> |
findAll(Path el)
Equivalent to WebDriver.findElements().
|
static org.openqa.selenium.WebElement |
hoverOver(Path el)
Hover over on the location of the element that corresponds to the given path.
|
static boolean |
isDisplayed(Path el)
Relies on Selenium WebElement::isDisplayed, thus non-atomic.
|
static boolean |
isEnabled(Path el)
Relies on Selenium WebElement::isEnabled, thus non-atomic.
|
static boolean |
isPresent(Path el) |
static boolean |
isSelected(Path el)
Relies on Selenium WebElement::isSelected, thus non-atomic.
|
static Integer |
numberOfAppearances(Path el)
Typically should not be used directly.
|
static Operations.KeysDown |
pressKeyDown(CharSequence thekey)
Press key down in the browser, or on a specific element.
|
static Operations.ReleaseKey |
releaseKey(CharSequence thekey)
Release key in the browser, or on a specific element.
|
static Operations.Scroll |
scroll()
scroll the browser.
|
static Operations.ScrollElement |
scrollElement(Path el)
scroll within the given element.
|
static org.openqa.selenium.WebElement |
scrollTo(Path el)
scroll to the location of the element that corresponds to the given path.
|
static Operations.KeysSender |
sendKeys(CharSequence... charsToSend)
send keys to the browser, or to a specific element.
|
public static org.openqa.selenium.WebElement find(Path el)
el - a Path instancepublic static List<org.openqa.selenium.WebElement> findAll(Path el)
el - a Path instancepublic static Integer numberOfAppearances(Path el)
el - a Path instancepublic static boolean isPresent(Path el)
el - a Path instancepublic static boolean isEnabled(Path el)
el - the path of the element to findpublic static boolean isSelected(Path el)
el - the path of the element to findpublic static boolean isDisplayed(Path el)
el - the path of the element to findpublic static org.openqa.selenium.WebElement clickOn(Path el)
el - a Path instancepublic static org.openqa.selenium.WebElement clickAt(Path el)
el - a Path instancepublic static org.openqa.selenium.WebElement hoverOver(Path el)
el - a Path instancepublic static org.openqa.selenium.WebElement scrollTo(Path el)
el - a Path instancepublic static Operations.Scroll scroll()
browser.scroll().to(path);
browser.scroll().left(50);
browser.scroll().right(50);
browser.scroll().up(50);
browser.scroll().down(50);
public static Operations.ScrollElement scrollElement(Path el)
el - a Path instancepublic static void doubleClickOn(Path el)
el - a Path instancepublic static Operations.KeysSender sendKeys(CharSequence... charsToSend)
sendKeys("abc").toBrowser();
sendKeys("abc").to(path);
charsToSend - the keys to send. Can be "abc", or "a", "b", "c"public static Operations.KeysDown pressKeyDown(CharSequence thekey)
pressKeyDown(Keys.TAB).inBrowser();
pressKeyDown(Keys.TAB).on(path);
thekey - the key to presspublic static Operations.ReleaseKey releaseKey(CharSequence thekey)
releaseKey(Keys.TAB).inBrowser();
releaseKey(Keys.TAB).on(path);
thekey - the key to releasepublic static Operations.DragAndDrop dragAndDrop(Path path)
dragAndDrop(source).to(target);
dragAndDrop(source).to(xCor, yCor);
path - the path of the element to drag and dropCopyright © 2018. All rights reserved.