Difference between Page object model and Page object factory

385 views
Skip to first unread message

Ramesvar GV

unread,
May 12, 2014, 9:38:32 AM5/12/14
to webd...@googlegroups.com
can any one explain difference between Page object model and Page object factory??

Which is best??

darrell

unread,
May 15, 2014, 9:10:48 AM5/15/14
to webd...@googlegroups.com
You aren't even comparing apples and oranges here. This is more like asking what is the difference between apples and apple pie.

A Page Object Model is a way of representing an application in a test framework. For every 'page' in the application you create a Page Object to reference the 'page'. A Page Factory is one way of implementing a Page Object Model. Search for "Java Factory" to understand the concept of a Factory.

Additionally, the Selenium project has a PageFactory implementation. This is an actual implementation of a Factory rather than just the concept.

Darrell
Reply all
Reply to author
Forward
0 new messages