ExplicitWait allow your code to halt program execution, or freeze the
thread, until the condition you pass it resolves. The condition is
called with a certain frequency until the timeout of the wait is
elapsed. This means that for as long as the condition returns a falsy
value, it will keep trying and waiting.
Selenium中没有无限等待的概念。因为这不是等待无限时间(1分钟、1小时、1天、1个月、1年……等等)的理想情况
特定条件应在特定时间内完成。所以,您可以做的一件事是提供最大阈值等待时间。Selenium将持续检查元素是否可单击,直到达到最大阈值
根据Selenium文件:
相关问题 更多 >
编程相关推荐