0

I'm writing TestCafe script to test some UI, and I'm wondering if there is an easy way to test this kind of Selectors match:

const element = Selector('div > div').withText('Some text')

The thing is that there might be multiple elements with text "Some text" on the page, and I would like to assure that I'm testing the appropriate one with:

await t.expect(element.exists).ok()

Slazak
  • 3
  • 3

0 Answers0