脚本如下:
require 'watir-webdriver'
b = Watir::Browser.new:chrome
b.goto('http://120.26.130.253:3000/course/questionstore?_v=0.2.2&course_id=355')
b.div(:class,"header-part float-right").click
b.div(:class=>"ant-tabs-tab-inner").click
运行脚本时,提示: unknown error: Element is not clickable at point (411, 83). Other element would receive the click: <div tabindex="-1" class="ant-modal-wrap common-login-dialog" role="dialog">...</div> (Selenium::WebDriver::Error::UnknownError)
源码如下图:
当运行到第三步时总是自动切换到注册,而我的目的是登录,运行第四行我想去点击弹窗登录就爆出上述错误,不知道是哪里的问题,刚开始学习自动化测试,还请多多指教啊~