Skip to main content

Working With Windows in Selenium Web Drivers

IN Web Application, it may be possible that once you open the browser then multiple windows open. These windows may have advertisement or other useful information. it may be also possible that once user will click on any link then a new window or new tab will open. So in this article we will handle these multiple windows using Selenium Web Driver.

Here user will need method to handle main window by using getWindowHandle() then we need to handles all other new windows opening by getWindowHandles() method.

getWindowHandle() Return an opaque handle to this window that uniquely identifies it within this driver instance while getWindowHandles() Return a set of window handles which can be used to iterate over all open windows of this WebDriver instance by passing them to switchTo().WebDriver.Options.window()






Comments

Popular posts from this blog

What is API?

In general way, API (Application Programming Interface) is the intermediate software which is useful for two applications to communicate. API is the tool which is used for interaction of two applications. If developer developing any software which have multiple blocks (Modules) than developer use APIs to put them together.

How to Put Load on a Script in JMeter

In last post we discussed about how to record a test script and Firefox settings to run the script. In this post we will discuss about how the Thread Group will work, how can we put n number of users to perform load testing, In JMeter by using Thread Group, we can create virtual users. Thread Group is a set of thread which work in same scenario. There are multiple thread group are available which is use to configure how the virtual users interest with the application, How much load maintain and till how much time load maintain.

JMeter Overview Description

In this article we will go through the multiple section of JMeter and describe the tool information. we will discuss about every component of JMeter tool in this Article so that you can hands on while working on script on JMeter about these components.