Chapter 6. Working with Alerts, Frames, and Windows

In this chapter, we will cover the following:

  • Handling a simple JavaScript alert box
  • Handling a confirm and prompt alert box
  • Identifying and handling frames
  • Working with IFRAME
  • Identifying and handling a child window
  • Identifying and handling a window by its title
  • Identifying and handling a pop-up window by its content

Introduction

To build a great user interface, developers use features similar to desktop applications in the form of pop-up windows and alerts. While testing complex workflows, tests need to flow from the browser window to a pop-up window in order to alert the user and perform operations as needed. This chapter will explain common issues that pertain to the handling of pop-up windows and alerts, and how best to use Selenium WebDriver API for this.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.188.115.155