I have code which used to work recently but not any more
String xpath = "//*[name()='svg']//*[name()='path' and @class='zone priceDesc_0']";
By path = By.xpath(xpath);
WebElement el = driver.findElement(path);
WebDriverWait wait = new WebDriverWait(driver, 10);
wait.until(ExpectedConditions.elementToBeClickable(el);
Actions actions = new Actions(driver);
actions.click(el).build().perform();
Now I receive an error:
<path>...</path> is not clickable at point (466.316650390625, 667.25). Other element would receive the click: <tspan x="" y="" class=""></tspan>
According to what I have found in other topics here I have changed part which clicks to:
JavascriptExecutor executor = (JavascriptExecutor) driver;
executor.executeScript("arguments[0].click();", el);
and now I receive:
Exception in thread "main" org.openqa.selenium.JavascriptException: arguments[0].click is not a function
What is wrong ?