【发布时间】:2013-08-07 17:11:11
【问题描述】:
我正在尝试使用 Selenium 测试一个值是否已从服务器加载到 GWT 的 RichTextArea 中。
我在做
@FindByDebugId("gwt-debug-about-me")
private WebElement aboutMeRichText;
当我发送密钥时,没有问题,文本打印在 RichTextArea 中。
但是当我尝试这个(检索值)时:
aboutMeRichText.getText()
它返回一个空字符串。
当我查看 HTML 中生成的内容时,是这样的:
<iframe class="GJUJXOPBLP-com-asdf-asdf-client-resource-Resources-Styles-textBox hasRichTextToolbar" id="gwt-debug-about-me">
#document
<html><head></head><body>Hi there !</body></html>
</iframe>
我该怎么做才能找回“你好!”文字?
【问题讨论】:
-
我遇到了与 GXT 类似的问题,我试图检索的字段有一个名为“只读”的属性,当设置时我无法检索文本,有点矛盾属性,但尽管如此......你碰巧有这样的东西吗?
标签: gwt selenium webdriver selenium-webdriver selenium-chromedriver