Rajesh Yadav
Rajesh Yadav

Reputation: 21

mouseover/action class methods not workign with selenium3

I am trying to click on a link using moveToElement in actions class in selenium3.. But its not working.. I have tried other methods from actions class (doubleclick, draganddrop) but none seems to be working..

package Advanced.Actions;

import org.openqa.selenium.By;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.WebElement;
import org.openqa.selenium.firefox.FirefoxDriver;
import org.openqa.selenium.interactions.Actions;

public class z_clickEvent {

    public static void main(String[] args) {
        // TODO Auto-generated method stub
        String url = "https://www.myhcl.com/Login/home.aspx";
        System.setProperty("webdriver.gecko.driver", "C:\\code\\lib\\browser drivers\\geckodriver.exe");

        WebDriver driver = new FirefoxDriver();
        driver.manage().window().maximize();

        driver.get(url);

        WebElement loginHelp = driver.findElement(By.linkText("Login Help"));

        Actions action = new Actions(driver);
        action.moveToElement(loginHelp).build().perform();
        action.click().build().perform();

    }

}

selenium: 3.1 ff:50.1

Is there an issue in the actions class in selenium 3.

The error that i am getting is Exception in thread "main" org.openqa.selenium.UnsupportedCommandException: POST /session/9988ddc4-ea82-41c2-86d8-3a3815609d0e/moveto did not match a known command Build info: version: 'unknown', revision: '1969d75', time: '2016-10-18 09:43:45 -0700'

Upvotes: 0

Views: 1042

Answers (1)

acikojevic
acikojevic

Reputation: 945

Yes, it's not working because Actions API is not implemented yet in geckodriver/marionette.

https://github.com/mozilla/geckodriver/issues/233

Upvotes: 1

Related Questions