【发布时间】:2019-09-28 03:53:17
【问题描述】:
我想检查我创建的页面上是否存在“64”。
const x = Selector('.FilterCockpit--header--count').withText('64');
以下测试失败。
test('x', async t => {
await t
.expect((x).exists).ok()
});
HTML 代码:
<div class="FilterCockpit--header--results">
<span class="FilterCockpit--header--count">
64
</span>
Results
</div>
我做错了什么?提前感谢您的帮助。
【问题讨论】:
-
我在控制台中收到错误消息:AssertionError: expected false to be truthy
标签: testing automated-tests e2e-testing testcafe web-testing