gpt4 book ai didi

java - 等到文本框 Selenium 中不存在文本

转载 作者:行者123 更新时间:2023-11-29 09:31:50 25 4
gpt4 key购买 nike

下面是我尝试自动化的场景:

1) Some text is already present in Textbox.
2) Click on Radio button.
3) Processing popup is displayed for few seconds. After popup disappears the textbox
becomes blank
4) After textbox is blank then I have to enter different value in text box.

请帮帮我,如何等到文本框值为空。

我正在使用 IE 驱动程序实现自动化。

提前致谢

最佳答案

我会尝试:
整数超时 = 10;//取决于你的需求
WebDriverWait myWait= new WebDriverWait(driver,timeout);
myWait.until(ExpectedCondition.textToBePresentInElementValue(By locator, String text))

-- 空字符串作为文本参数传递

关于java - 等到文本框 Selenium 中不存在文本,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/37456716/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com