New rules placed under src\test\resources
Elements for Simple rules should be processed using following way
e.g.
"Button": ["input[type=submit]", "input[type=button]",
"button[type=button]", "button.btn", "a.btn"],
here you see 5 rules
if rule started from "//" then it identified as xpath else css. Other ways to locate elements not acceptable
for each rule generator grab all elements on in dom
After try to find uniqueness for each found tag
- Try to find id if no >name > value> label(before,after,around) > alt > text
if any of this attributes makes element unique on page then this locator used
if no unique attributes then go one node up and try to find uniqueness for it using previous rule.
Repeat this 3 levels up (cusomizable variable) if no uniqueness found then through not unique element exception
New rules placed under src\test\resources
Elements for Simple rules should be processed using following way
e.g.
"Button": ["input[type=submit]", "input[type=button]",
"button[type=button]", "button.btn", "a.btn"],
here you see 5 rules
if rule started from "//" then it identified as xpath else css. Other ways to locate elements not acceptable
for each rule generator grab all elements on in dom
After try to find uniqueness for each found tag
if any of this attributes makes element unique on page then this locator used
if no unique attributes then go one node up and try to find uniqueness for it using previous rule.
Repeat this 3 levels up (cusomizable variable) if no uniqueness found then through not unique element exception