selenium问题总结

1、使用ie浏览器进行selenium自动化测试时,无法启动浏览器并抛出如下异常:

Exception in thread "main" org.openqa.selenium.remote.SessionNotFoundException: Unexpected error launching Internet Explorer. Protected Mode settings are not the same for all zones. Enable Protected Mode must be set to the same value (enabled or disabled) for all zones. (WARNING: The server did not provide any stacktrace information)
Command duration or timeout: 1.13 seconds

需要统一设置各个区域的保护模式,全部开启或者全部关闭。



 

 2、webdriver不支持sendkeys(string),提示The method sendKeys(CharSequence[]) in the type WebElement is not applicable for the arguments (String)。

java的版本与eclipse的编译环境版本不一致。

猜你喜欢

转载自ming911.iteye.com/blog/2201858
今日推荐