0
在硒IDE
在selenium2
driver.findElement(By.cssSelector("#" + tid +"_title > li.deleteTitle.listDelete")).click();
它给出了一个错误in webdriver
junit.framework.AssertionFailedError: timeout
at junit.framework.Assert.fail(Assert.java:50)
很抱歉,如果这是一个愚蠢的问题
我只能说,那字符串连接是正确的。问题出在你以前的步骤。如果这是下拉菜单中的项目,则应首先扩展此下拉菜单 – 2012-04-25 20:19:08
不,它不是下拉列表。我正试图记录删除标题。我将鼠标悬停在操作栏 - 一旦我看到删除图标,我点击它。
你可能想尝试'driver.manage()超时()implicitlyWait();'[该文档。(HTTP ://selenium.googlecode.com/svn/trunk/docs/api/java/org/openqa/selenium/WebDriver.Timeouts.html#implicitlyWait%28long,%20java.util.concurrent.TimeUnit%29) – 2012-04-25 21:56:16