Wedriver.Timeouts中有三种Java超时函数:
我试图查找python相当于第三个,但我无法找到它。以下是前两个的python等价物。
答案 0 :(得分:3)
这就是你要找的东西:
set_script_timeout(time_to_wait)
Set the amount of time that the script should wait during an
execute_async_script call before throwing an error.
Args :
time_to_wait: The amount of time to wait (in seconds)
Usage :
driver.set_script_timeout(30)
参考 - set_script_timeout