The Different Types of Locators used in in Selenium Wen Driver 2.0 are : 1.Xpath 2.ID 3.Link Text 4.Partial Link Text 5.Class 6.Tag Name 7.CSS Selectors
Characteristics of good Locators are : 1.It should be “Unique” 2.It should be “Descriptive” 3.Less chance of changing
|
If we consider the above points “Link Text’ ,”Partial Link Text”,”Tag Name” are not fit to be used as these are most likely to be changed in future. So it would be good if we use the following locators . 1.Xpath 2.ID 3.Class 4.CSS Selectors |