共分三步:

1.selenium官网下载selenium-server-standalone.jar的最新版本号

2.启动selenium-server:::::
java
-jar "selenium-server-standalone-2.2.0.jar"

-Dwebdriver.firefox.bin="C:\FirefoxCollection\Mozilla
Firefox 36.0\firefox.exe"

3.java代码初始化webdriver对象时:

DesiredCapabilities
capabilities = new DesiredCapabilities("firefox", "", Platform.ANY);

driver=new RemoteWebDriver(new URL("http://127.0.0.1:4444/wd/hub/"),capabilities);

Ps:假设是调用本地的浏览器的话,

System.setProperty("webdriver.firefox.bin",
"F:\\InstalledFiles\\firefox\\firefox.exe");

WebDriver
driver = new FirefoxDriver(); 就可以

最新文章

  1. hadoop小试
  2. 【编程题目】在一个字符串中找到第一个只出现一次的字符。如输入 abaccdeff,则输出 b。
  3. Plugins
  4. SSH乱码解决
  5. djangoadmin导出csv
  6. Windows 7 的系统文件修复:sfc /scannow
  7. Contoso 大学 - 1 - 为 ASP.NET MVC 应用程序创建 EF 数据模型
  8. 【HDOJ】1494 跑跑卡丁车
  9. SAP HANA 中的决策表(Decision Table)
  10. Javascript Fromdata 与jQuery 实现Ajax文件上传以及文件的删除
  11. jQuery获取Select选择的Text和 Value(转,待测试确认)
  12. [1] Entity Framework / Code First
  13. C++11智能指针的深度理解
  14. Visual Studio Code Shortcuts
  15. py001
  16. CSS3动画与JS动画的优缺点?
  17. SharePoint如何配置Ipad跳转等问题
  18. python中使用os.path.join()
  19. 你应该掌握的C++ RAII手法:Scopegaurd
  20. vs2012添加自定义资源步骤

热门文章

  1. Java中ArrayList和LinkedList差别
  2. MongoDB学习笔记(六) MongoDB索引用法和效率分析
  3. hdu 4550 贪婪 思考题 权
  4. SAP自带的创建报表工具
  5. 使用gdb调试游戏服务器
  6. c# listview导出excel文件
  7. 14.3.3 Locks Set by Different SQL Statements in InnoDB 不同的SQL语句在InnoDB里的锁设置
  8. poj 2409+2154+2888(Burnside定理)
  9. remove()和直接使用system的一个差别
  10. 明晚8点,捷微团队QQ群公开课,解说jeewx2.0版本号maven环境的搭建入门!