Chapter 8. Using the Page Object Model

In this chapter, we will cover the following topics:

  • Using the PageFactory class for exposing the elements on a page
  • Using the PageFactory class for exposing an operation on a page
  • Using the LoadableComponent class
  • Implementing nested Page Object instances
  • Implementing the Page Object model in .NET
  • Implementing the Page Object model in Python
  • Implementing the Page Object model in Ruby using the page-object gem

Introduction

Developing a maintainable automation code is one of the keys to a successful test-automation project. Test-automation code should to be treated as production code, and similar standards and patterns should be applied while developing this code.

While developing Selenium WebDriver tests, we can use ...

Get Selenium Testing Tools Cookbook - Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.