-2

I want to know if Karate framework can use Angular specific locators to support the angular JS apps.

1 Answers1

0

Karate gives you easy ways to run JS against the HTML DOM, which is all you need.

Here is an example: https://stackoverflow.com/a/67629911/143475

Also see: https://stackoverflow.com/a/66900081/143475

* def filter = function(x){ x.text.contains('Unique Identifier') }
* def list = locateAll('.grand-parent-class', filter)
* list[0].parent.children[4].click()

You should be able to easily write a re-usable function that converts an angular-specifc locator to the actual element. Do contribute your findings back so that it helps others.

Peter Thomas
  • 47,282
  • 14
  • 68
  • 196