selenium RC 点击,报错:The error message is: 没有权限

来源:互联网 发布:fanuc铣孔螺旋下刀编程 编辑:程序博客网 时间:2024/04/30 18:58

ERROR: Command execution failure. Please search the user group at https://groups.google.com/forum/#!forum/selenium-users for error details from the log window.  The error message is: 没有权限

原因: 当页面处于刷新状态时,执行selenium操作,特别是click(),ieElementPresent()和isTextPresent()的命令,报没有权限是常有的事
解决办法:加入等待时间,确认下页面是否真的加载完成(进度条)

以下是引用的别人的文章:
有人说selenium server的JAR包里面core/scripts/selenium-browserbot.js存在BUG,需要修改一下,其实修改了之后也并不能完全解决执行过程中偶发的“没有权限”问题。
  A)修改这个js文件,重新丢进包里;
  B)如果使用ie测试,则尽量使用iehta模式;
  C)重写一下click和type等方法,指定超时时间,在指定时间内反复try。
原创粉丝点击