您的位置:首页 > 其它

Actions 动作集

2015-06-15 15:09 211 查看
--> 移动鼠标到指定位置(先触发onMouseOver动作)
Actions action = new Actions(driver);
WebElement theRow = page.getInvisibleElement();
action.moveToElement(theRow).perform();
page.getInvisibleElement().click();

--> Ctrl + LeftClick(组合动作)
Actions action = new Actions(driver);
action.keyDown(Keys.CONTROL).perform();
input.click();// WebElement
action.keyUp(Keys.CONTROL).perform();
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: