|
Answer» Using POM an Object Repository can be created and can be maintained in the separate file. - Code reusability – You can achieve code reusability by writing the code once and use it in different tests.
- Code maintainability – There is a CLEAN separation between test code and PAGE specific code such as locators and layout which makes it very easy to maintain code. Code changes happen only on Page Object Classes when a UI change occurs and enhances test maintenance and reduces code duplication.
- Object Repository – Each page is defined as a java class and all the fields on the page will be defined in an interface as members, and the class will then implement the interface.
- Readability – Due to a CLEAR separation between test code and page-specific code, there is an ENHANCEMENT in readability.
|