What are iframes?
An IFrame (Inline Frame) is an HTML document embedded inside another HTML document on a website. The IFrame HTML element is often used to insert content from another source, such as an advertisement, into a Web page. Although an IFrame behaves like an inline image, it can be configured with its own scrollbar independent of the surrounding page's scrollbar.
The src attribute specifies URL(web address) of the inline frame page.
How to Identify IFrame
We can identify an iframe on a website in two ways:
1.Right-click on the page and click on View Page Source or inspect elements. On the page source, search for “iframe". If you find any iframe tags, it means the page includes iframes.
How to handle iframe in Testsigma
Here are a few steps to add switch Step to your Test Case:
STEP 1: Select one of the switch NLPs. For example, Switch to the frame ui identifier
STEP 2: Now using the Testsigma Chrome Extention, select the frame by clicking on the frame, which you want to switch to.
When you click on the frame, the Xpath of the frame will be recorded to the UI-identifier.
Now you can interact with the elements inside that frame. Similarly, if you want to interact with a different frame, you have to switch to that frame before you proceed. Else, Test-case will fail as the elements inside that frame won't be accessible.