
webdriver
我爱测试
I am who am I.
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
webdriver下定位frame和alert
将webdriver脚本调试中遇到问题总结分享一下,共同学习。 一.Junit中如何定位frame: SeleniumIDE中录制的selectFrame、selectWindow命令在Junit中不支持,那么只能使用webdriver自带的命令,如下列: 1.定位到一个frame driver.switchTo().frame("menuFrame"); 2.从一个frame原创 2012-06-28 13:08:47 · 5369 阅读 · 0 评论 -
webdriver 右键action.contextClick(element)
webdriver下 如何模拟右键菜单操作?action.contextClick(element)命令可实现鼠标右键点击操作,例如: Actions action = new Actions(driver) ; action.contextClick(driver.findElement(By.xpath("//div/li/div/a/span"))).perform(); PS: .p原创 2012-07-13 13:11:42 · 4575 阅读 · 3 评论 -
在线安装maven插件问题:Cannot complete the install because one or more required items could not be found.
使用Eclipse在线安装的方式:Help-->Install New Software 地址输入:http://m2eclipse.sonatype.org/sites/m2e/,列表中打勾勾上后点击Next 安装maven插件时遇到了如下的错误: Cannot complete the install because one or more required items could n原创 2012-07-13 13:14:44 · 54891 阅读 · 4 评论 -
webdriver中引入selenium对象
public static WebDriver driver=new FirefoxDriver(); public static String baseUrl="http://192.168.0.11:8080"; public static Selenium selenium=new WebDriverBackedSelenium(driver,baseUrl);原创 2012-07-26 17:21:36 · 1319 阅读 · 0 评论 -
webdriver 鼠标操作
注:driver为一个WebDriver的实例,xpath为一个元素的xpath字符串,在本文中一律采用xpath的方式定位元素 1、鼠标右键点击操作: Actions action = new Actions(driver) ; action.contextClick(driver.findElement(By.xpath(xpath))) ; 2、鼠标左键双击操作: Actions转载 2012-08-21 13:18:04 · 5257 阅读 · 1 评论