gpt4 book ai didi

java - WebDriver 测试未在 IE11 上运行

转载 作者:塔克拉玛干 更新时间:2023-11-01 22:44:35 24 4
gpt4 key购买 nike

当我运行我的 WebDriver 测试时,它们根本不工作。到目前为止我做了什么:1) 我更新了我的注册表项以包含 FEATURE_BFCACHE2) 所有区域的保护模式设置相同3)增强保护模式被禁用4) 我也尝试在我的 PATH 中设置 IEDriverServer

测试在 Chrome、Firefox 等上运行良好,但当我在 IE11 上运行时,我得到:

Caused by: org.openqa.selenium.NoSuchElementException: Unable to find element with css selector == a[href='#pricing'] (WARNING: The server did not provide any stacktrace information)
Command duration or timeout: 270 milliseconds
For documentation on this error, please visit: http://seleniumhq.org/exceptions/no_such_element.html
Build info: version: '2.44.0', revision: '76d78cf', time: '2014-10-23 20:02:37'
System info: host: 'C025', ip: '169.254.167.218', os.name: 'Windows 7', os.arch: 'amd64', os.version: '6.1', java.version: '1.7.0_51'
Session ID: 8bb9e652-976a-4b46-88dd-9fb339a0d352
Driver info: org.openqa.selenium.ie.InternetExplorerDriver
Capabilities [{platform=WINDOWS, javascriptEnabled=true, elementScrollBehavior=0, ignoreZoomSetting=false, enablePersistentHover=true, ie.ensureCleanSession=false, browserName=internet explorer, enableElementCacheCleanup=true, unexpectedAlertBehaviour=dismiss, version=11, ie.usePerProcessProxy=false, ignoreProtectedModeSettings=false, cssSelectorsEnabled=true, requireWindowFocus=false, initialBrowserUrl=http://localhost:23811/, handlesAlerts=true, ie.forceCreateProcessApi=false, nativeEvents=true, browserAttachTimeout=0, ie.browserCommandLineSwitches=, takesScreenshot=true}]

我正在使用 eclipse 用 java 编写我的代码,我的其余设置是:1) selenium-server-standalone-2.44.0.jar2) IEServerDriver.exe 32位3) Windows 7 64位4) java.version: 1.7.0_51

如有任何帮助,我们将不胜感激。

最佳答案

如果您使用了 Windows 更新 KB3025390 IE 将无法按预期工作。目前还没有解决方案。参见 this

此外,卸载更新 KB3025390 应该可以使 WebDriver 与 Internet Explorer 11 一起正常工作。请参阅此 answer

关于java - WebDriver 测试未在 IE11 上运行,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/27947515/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com