What is the correct IEDriverServer version to use with IE 11 through Selenium

て烟熏妆下的殇ゞ 提交于 2020-05-28 05:23:12

问题


I just got updated to Windows 10 (x64). My old desktop had IE 11 but a lower version, as it was running Windows 7. I now have the following IE version:

Version: 11.648.17134.0
Update Versions: 11.0.115

I downloaded the latest IEDriverServer.exe that Selenium gave me (3.14). When I run it, when I do the get(url) (various urls), afterwards it fails to find elements. I looked and noticed that before the get(), driver.getWindowHandles() had one entry, but after the get() it had zero entries. This is the latest version. I tried setting compatibility mode but that did not do any good (set or not set). The tests will work fine with Chrome but someone else wrote the test and did not verify values were non-null before calling element.sendKeys(str), which IE appears to allow but Chrome throws an exception. And there are so many instances.

So, I need to find the correct IEDriverServer for my Windows 10 IE but I am having trouble doing so. Google did not give me much except it led me to the driver I already downloaded.

Can anyone help?


回答1:


As a thumb-rule you can always use the released IEDriverServer from the respective released Selenium clients.

As an example,

  • If you are using Selenium v3.14
    • Download, extract and use IEDriverServer_Win32_3.14.0.zip or IEDriverServer_x64_3.14.0.zip
  • Snapshot:


Update

However to work with IE11 you have to take care of a couple of things which are beyond the scope of this discussion and are as follows:

  • How does the registry entry HKEY_LOCAL_MACHINE\…\FEATURE_BFCACHE for InternetExplorerDriver solves the Internet Explorer 11 issue?
  • Internet Explorer Protective mode setting and Zoom levels
  • Selenium InternetExplorerDriver doesn't get focus on the window
  • How to ignore protected Mode Settings for Internet Explorer using setCapability() through Selenium and Java?



回答2:


Yes, you were right. Previously it would warn you that the zones weren't the same, and not even start. now it does not warn you and chugs along but fails.



来源:https://stackoverflow.com/questions/55285722/what-is-the-correct-iedriverserver-version-to-use-with-ie-11-through-selenium

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!