Can anyone state some of the advantages of Page Object Model framework?

0 votes
Can anyone state some of the advantages of Page Object Model framework?
Jun 4, 2019 in Selenium by Naomi
694 views

1 answer to this question.

0 votes

Hey Naomi, POM (Page Object Model) framework has following advantages:

  • Object Repository – Each page will be defined as a java class. All the fields in the page will be defined in an interface as members. The class will then implement the interface.

  • Code maintainability – There is a clean separation between test code and page specific code such as locators and layout which becomes very easy to maintain code. Code changes only on Page Object Classes when a UI change occurs. It enhances test maintenance and reduces code duplication.

  • Readability – Improves readability due to clean separation between test code and page specific code.

  • Code reusability – We could achieve code reusability by writing the code once and use it in different tests.

answered Jun 4, 2019 by Rakshit

Related Questions In Selenium

+1 vote
1 answer

How can I automate the process of adding iPhone to cart in Flipkart using Selenium(java),Page Object Model and TestNG? Also validate if product is added and available in cart?

Hey check this https://www.edureka.co/community/47160/automate-purchase-adding-book-cart-flipkart-using-selenium? It deals with a similar ...READ MORE

answered Jan 13 in Selenium by Karan
• 9,610 points
1,684 views
0 votes
1 answer

What are the advantages of TestNG over JUnit framework?

Hey Kimberly, TestNG has many advantages over ...READ MORE

answered Jun 11, 2019 in Selenium by Abha
• 27,800 points
383 views
0 votes
1 answer
0 votes
1 answer

Finding WebDriver element with Class Name in java

The better way to handle this element ...READ MORE

answered Apr 10, 2018 in Selenium by nsv999
• 5,510 points
2,226 views
0 votes
2 answers

Selenium: Diff between POM (page object model) and page factory?

Hi, In POM (Page Object Model) you create ...READ MORE

answered Mar 14, 2019 in Selenium by Ellen Dares
3,850 views
0 votes
1 answer
0 votes
1 answer

What are the advantages of Pytest framework over other test frameworks?

Hello Shanky, Pytest is one of the ...READ MORE

answered Aug 22, 2019 in Selenium by Abha
• 27,800 points
599 views
+1 vote
1 answer

Can someone explain the meaning of WebDriver wd = new ChromeDriver();?

WebDriver webdriver = new ChromeDriver(); The following simply ...READ MORE

answered Dec 14, 2018 in Selenium by Aniket
99 views