In karate framework,
for eg: few rows in the table matches certain conditions and rest of the rows does not match. Using filter
- def rows = locateAll(“//table//tbody//tr”)
- def filtered = rows.filter(x => x.text.includes(‘AA’) && x.text.includes(‘BB’))
able to filter the rows
but need to get the first row number that matches the above condition for further processing like button click or link click in the same row
Expected results
to fetch the first row position that matches the conditions applied using filter keyword. so that with that row details can locate the button/link available and script is clicks the button/link