Friday, 22 July 2016

What is By in selenium webdriver

By class In selenium web driver:
========================
By is an abstract class and which is avalaible in org.openqa.selenium package.

These are the static methods present in By class and by using this classes we can identify web elements

1.public static By id(String id);
2. public static By name(String name);
3. public static By className(String className);
4. public static By cssSelector(String cssSelector );
5. public static By linkText(String linkText);
6. public static By partialLinkText(String partialLinkText);
7. public static By tagName(String tagName);

8. public static By xpath(String xpath);

No comments:

Post a Comment