I want to know if Karate framework can use Angular specific locators to support the angular JS apps.
Asked
Active
Viewed 195 times
1 Answers
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
- 54,465
- 21
- 84
- 248
-
Thank you for the quick response and sure will share as I learn and implement more.. – janette menezes May 21 '21 at 18:17