【发布时间】:2021-07-08 20:56:33
【问题描述】:
await t.expect(Selector('#elementId').innerText)
.eql('Discounted 20% with your subscription');
这里是文本 - Discounted 20% with your membership
20% 不是恒定的,它可能会变为 15% 或 19%
我怎样才能“断言”这个?
我试过了
await t.expect(Selector('#elementId').innerText)
.eql('Discounted' + 'with your subscription');
但是没用
【问题讨论】:
标签: typescript testing automated-tests e2e-testing testcafe