Categories

Automating dialog box validation

How to automate a dialog box validation

It will happen often that you will need to validate a dialog box on supported web browsers in order to confirm or cancel an action.

However, it is impossible to capture a dialog box with the capture tool.

To automate the validation with Agilitest, you will need to select the dialog box from the root application available in an action.

When you create an action without inteface element, it will show the root application.

Click on the “Mouse” action in the actions menu

mouse action

Then, select "Mouse click"

mouse click action

Click on the “Root application" to select the interface type

root application

A new menu will appear with the following possibilities:

root app menu
  • Add an interface element
  • Modify the system element
  • Manage a dialog box
  • Screen record

To know more on the other elements types, you can consult ou documentation about Editing actions.

To automate a dialog box, click on the “Dialog box” button

dialo box button

There are three actions possible on a dialog box

Confirm the dialog box

From the root application, select “Dialog box” to show its options

dialog box options

Select the validation type you need for the dialog box:

  • Accept
  • Dismiss
accept box

Example :

A dialog box that needs to be accepted or dismissed

example dialog box

Click action

It is also possible to simply use the click action on a dialog box if only one button appears.

click on dialog box

Example :

An “Ok” button that is used to make the dialog box disappear

ok button on dialog box

Property action

On each of the proposed actions it is possible to perform a property action which will enter the information entered in the dialog box.

Example :

To do that, click on the “Property” action situated in the action menu

property action

Then, select “Dialog box” from the root application.

dialog box button

This will return the text shown in the dialog box,

dialog box text

As a value in your property action.

value in a propert

Still require support?
Contact support