Selenium IDE 向下箭头键

发布于 2024-10-08 13:00:49 字数 210 浏览 0 评论 0原文

我一直试图让我的硒测试来模拟向下箭头键的按下。

我只是使用 html 格式进行测试,并使用 typeKeys 作为命令,正确找到目标,并且对于我放入 \40 的值,该值似乎在 UI 中转换为 \\40 。当我运行该命令时,它最终会将 \40 附加到输入的当前值。

我正在使用该网站的最新版本的 selenium ide。

有什么指点吗?

干杯

I'm stuck trying to get my selenium testing to simulate a down arrow key press.

Im just using the html format for my tests and am using typeKeys as the command, the target is correctly found, and for the value I am putting in \40 which seems to be converted into \\40 in the UI. When I run the command it ends up appending \40 to the current value of the input.

I'm using the latest version of the selenium ide from the site.

Any pointers?

Cheers

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

著墨染雨君画夕 2024-10-15 13:00:49

Selenium 为这项任务提供了自己的方法。

尝试使用 keyDown() 而不是 typeKeys()

Selenium provides its own methods for this task.

Try using keyDown() instead of typeKeys()

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文