1、安装pythonhttps://www.python.org/2、安装setuptools(python的基础包工具)下载地址:https://pypi.python.org/pypi/setuptools下载ez_setup.py文件打开cmd,进入到存放ez_setup.py文件的目录,执行...
分类:
编程语言 时间:
2015-05-04 19:57:21
阅读次数:
124
Protractor是为Angular JS应用量身打造的端到端测试框架。它可以真实的驱动浏览器,自动完成对web应用的测试。Protractor驱动浏览器使用的是WebDriver标准,所以使用起来与其他语言实现的WebDriver库大体相同。当然,我说大体相同那肯定还是有不同的地方。一旦不注意这...
分类:
其他好文 时间:
2015-05-04 19:53:18
阅读次数:
1591
安装eclipse 安装java jre 设置java环境变量 打开Eclipse,新建一个java project。 创建成功后到project properties->Java Build Path->Libraries->Add Library->JUnit...
分类:
其他好文 时间:
2015-05-04 18:23:35
阅读次数:
112
在写文件上传脚本的时候,遇到了很多问题,包括元素定位,以及上传操作,现在总结下来以下几点:1. 上传的控件定位要准确,必要时要进行等待WebElement adFileUpload = driver.findElement(By.xpath("//input[@type='file']"));2. ...
分类:
编程语言 时间:
2015-05-04 15:06:34
阅读次数:
193
CssSelector是我最喜欢的元素定位方法,Selenium官网的Document里极力推荐使用CSS locator,而不是XPath来定位元素,原因是CSS locator比XPath locator速度快,特别是在IE下面(IE没有自己的XPath 解析器(Parser))他比xpath更...
分类:
Web程序 时间:
2015-05-04 11:50:38
阅读次数:
364
https://pypi.python.org/pypi/seleniumfrom selenium import webdriverfrom selenium.webdriver.common.keys import Keysbrowser = webdriver.Firefox()browser...
分类:
Web程序 时间:
2015-05-03 20:17:20
阅读次数:
1190
These days most of the web apps are using AJAX techniques. When a page is loaded to browser, the elements within that page may load at different time ...
分类:
其他好文 时间:
2015-05-03 11:56:12
阅读次数:
143
There are vaious strategies to locate elements in a page. You can use the most appropriate one for your case. Selenium provides the following methods ...
分类:
其他好文 时间:
2015-05-03 11:55:26
阅读次数:
137
The first thing you’ll want to do with WebDriver is navigate to a link. The normal way to do this is by callinggetmethod:driver.get("http://www.google...
分类:
其他好文 时间:
2015-05-03 11:53:05
阅读次数:
216
1.1. Simple UsageIf you have installed Selenium Python bindings, you can start using it from Python like this.from selenium import webdriverfrom selen...
分类:
其他好文 时间:
2015-05-03 11:50:36
阅读次数:
179