我尝试验证工具提示文本,所以我使用“操作”,我的代码是:
WebDriverWait wait = new WebDriverWait(driver, 20);
WebElement infoTooltip = wait.until(ExpectedConditions.presenceOfElementLocated(By.xpath("//button[@id='tooltip-btn']")));
Actions mouseMove = new Actions(driver);
mouseMove.moveToElement(infoTooltip).perform();
但是以下错误始终显示在控制台中: “ org.openqa.selenium.JavascriptException:JavaScript错误:无法在'Document'上执行'elementsFromPoint':提供的double值是非限定的。”