Search in sources :

Example 31 with Actions

use of org.openqa.selenium.interactions.Actions in project ats-framework by Axway.

the class HiddenHtmlElement method rightClick.

/**
     * Simulate mouse right click action
     */
@Override
@PublicAtsApi
public void rightClick() {
    new HiddenHtmlElementState(this).waitToBecomeExisting();
    WebElement element = HiddenHtmlElementLocator.findElement(this);
    new Actions(htmlUnitDriver).contextClick(element).perform();
}
Also used : HiddenHtmlElementState(com.axway.ats.uiengine.utilities.hiddenbrowser.HiddenHtmlElementState) Actions(org.openqa.selenium.interactions.Actions) WebElement(org.openqa.selenium.WebElement) PublicAtsApi(com.axway.ats.common.PublicAtsApi)

Example 32 with Actions

use of org.openqa.selenium.interactions.Actions in project ats-framework by Axway.

the class HiddenHtmlElement method mouseOver.

/**
     * Simulate mouse over
     */
@Override
@PublicAtsApi
public void mouseOver() {
    new HiddenHtmlElementState(this).waitToBecomeExisting();
    WebElement element = HiddenHtmlElementLocator.findElement(this);
    new Actions(htmlUnitDriver).moveToElement(element).perform();
    UiEngineUtilities.sleep();
}
Also used : HiddenHtmlElementState(com.axway.ats.uiengine.utilities.hiddenbrowser.HiddenHtmlElementState) Actions(org.openqa.selenium.interactions.Actions) WebElement(org.openqa.selenium.WebElement) PublicAtsApi(com.axway.ats.common.PublicAtsApi)

Example 33 with Actions

use of org.openqa.selenium.interactions.Actions in project ats-framework by Axway.

the class HiddenHtmlElement method pressEscapeKey.

/**
     * Simulate Escape key
     */
@Override
@PublicAtsApi
public void pressEscapeKey() {
    new HiddenHtmlElementState(this).waitToBecomeExisting();
    WebElement element = HiddenHtmlElementLocator.findElement(this);
    new Actions(htmlUnitDriver).sendKeys(element, Keys.ESCAPE).perform();
}
Also used : HiddenHtmlElementState(com.axway.ats.uiengine.utilities.hiddenbrowser.HiddenHtmlElementState) Actions(org.openqa.selenium.interactions.Actions) WebElement(org.openqa.selenium.WebElement) PublicAtsApi(com.axway.ats.common.PublicAtsApi)

Example 34 with Actions

use of org.openqa.selenium.interactions.Actions in project ats-framework by Axway.

the class HiddenHtmlElement method pressSpaceKey.

/**
     * Simulate Space key
     */
@Override
@PublicAtsApi
public void pressSpaceKey() {
    new HiddenHtmlElementState(this).waitToBecomeExisting();
    WebElement element = HiddenHtmlElementLocator.findElement(this);
    new Actions(htmlUnitDriver).sendKeys(element, Keys.SPACE).perform();
}
Also used : HiddenHtmlElementState(com.axway.ats.uiengine.utilities.hiddenbrowser.HiddenHtmlElementState) Actions(org.openqa.selenium.interactions.Actions) WebElement(org.openqa.selenium.WebElement) PublicAtsApi(com.axway.ats.common.PublicAtsApi)

Example 35 with Actions

use of org.openqa.selenium.interactions.Actions in project Ebselen by Ardesco.

the class EbselenCore method startSelenium.

/**
     * Start the WebDriver Instance
     */
public void startSelenium() {
    if (driver != null) {
        logger.error("There appears to be an existing driver instance.. Details are: {}", driver);
        logger.error("Shutting down existing instance and starting up again...");
        stopSelenium(driver);
    }
    driver = setBrowser(driver);
    ebselen = new EbselenCommands(driver);
    builder = new Actions(driver);
}
Also used : Actions(org.openqa.selenium.interactions.Actions)

Aggregations

Actions (org.openqa.selenium.interactions.Actions)100 WebElement (org.openqa.selenium.WebElement)59 WebDriver (org.openqa.selenium.WebDriver)26 FirefoxDriver (org.openqa.selenium.firefox.FirefoxDriver)18 PublicAtsApi (com.axway.ats.common.PublicAtsApi)16 Test (org.junit.Test)16 HiddenHtmlElementState (com.axway.ats.uiengine.utilities.hiddenbrowser.HiddenHtmlElementState)9 WebDriverWait (org.openqa.selenium.support.ui.WebDriverWait)6 RealHtmlElementState (com.axway.ats.uiengine.utilities.realbrowser.html.RealHtmlElementState)4 List (java.util.List)3 Action (org.openqa.selenium.interactions.Action)3 MobileOperationException (com.axway.ats.uiengine.exceptions.MobileOperationException)2 VerificationException (com.axway.ats.uiengine.exceptions.VerificationException)2 MobileElementState (com.axway.ats.uiengine.utilities.mobile.MobileElementState)2 AndroidDriver (io.appium.java_client.android.AndroidDriver)2 File (java.io.File)2 DecimalFormat (java.text.DecimalFormat)2 JavascriptExecutor (org.openqa.selenium.JavascriptExecutor)2 SystemException (com.github.bordertech.wcomponents.util.SystemException)1 JavascriptActions (com.wikia.webdriver.common.core.elemnt.JavascriptActions)1