Selenium IE6 Failed to load the library from temp directory: C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\IED1C1.tmp

项目中用到了使用Selenium打开IE浏览器。前期都是基于IE8+、Firefox、Chrome。项目后期开始现场测试时发现大部分客户还都是使用的Windows XP + IE6。结果可想而知,直接就挂了。报以下错误:

Failed to load the library from temp directory: C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\IED1C1.tmp

使用的Selenium版本为2.52版本。

在网上G来B去的也没有找到相关的解决办法。仅通过G找到一篇关于此问题的提问,但最终也未能解决此问题。猜想不会是版本的问题吧,但是此版本已经够新了,是2016年发布的,硬着头皮从官方下载了一个最新的2.53版本,果不其然,还是报此错误。

经过两天的折腾无意在看到G上有一个链接摘要中写着

The InternetExplorerDriver is a standalone server which implements WebDriver's wire protocol. This driver has been tested with IE 7, 8, 9, 10, and 11 on appropriate combinations of Vista, Windows 7, Windows 8, and Windows 8.1. As of 15 April 2014, IE 6 is no longer supported.

不对啊,之前搜索问题时都提到支持IE6,特别是国内的相关文章都写着支持IE6-11。怎么现在仅从IE7开始了,而且从2014年就已经不支持IE6了。打开链接原来是GITHUB上的说明。

到selenium的下载FTP上下载老版本的。下载地址:http://selenium-release.storage.googleapis.com/index.html?path=2.40/

前期测试,不需要更换jar包,仅需要将IEDriverServer.exe替换即可。

Selenium的相关网站需要自备梯子,没有梯子的可以从下面的地址下载。

下载地址:https://pan.baidu.com/s/1nuryipj

里面包含了2.53与2.40两个版本相关的jar包与IE驱动。

posted @ 2016-03-18 15:50  AUOONG  阅读(955)  评论(0编辑  收藏  举报