Skip to main content
All CollectionsEditor
Checking for visible elements on the page (Check)
Checking for visible elements on the page (Check)

Check feature allows you to check for visible elements on page such as texts, images, etc.

I
Written by Igor Ivanovski
Updated over a week ago

Checks are assertions about the state of your application under test. They verify that certain texts, images, and other elements are visible on the page.

Example

Make a trace that signs into your application. After signing in, add a check that verifies that the user has been successfully signed in by checking for an element that is visible on the page after the sign-in has been completed successfully.

Adding checks

  1. When recording steps, select other steps from the pointer and then click Check.

   2. Click an element on the page or highlight a text portion with your mouse in the Virtual Browser.

Check types

Select a check type by opening the locators from the check step. The following types are available:

How checks work

  1. Usetrace waits for the element defined in the step’s locators to be found. The maximum waiting time can be adjusted from the step’s locator tab.

  2. When the element has been found, Usetrace waits until the check condition (defined by the check type) is fulfilled. For example, an element’s text may change to the desired value after some delay.

  3. If the element is not found or the check condition is not fulfilled within the given time limit (default 15 seconds), the check fails.

Other examples:

Detecting an iframe element

If we cannot detect the Iframe with the Check Step using the Virtual Browser locators, we should try with the second option: Define element locators manually.

1. Click on the Add Locators button
2. Inspect the src and title of the iframe element then fill in the values as in this template example below:

for CSS add this: iframe[title='title text here'] [src='https://url.goes.here']


for XPATH add this: //iframe[@title='title text here' and @src='https://url.goes.here']


Did this answer your question?