on modal action

Description

Specify the action to be invoked in the event of the appearance of a modal dialog box which would otherwise disrupt the intended flow of test automation.

Arguments

Valid contexts

This action may be used within the following project items: test modules and user-defined actions.

Notes

Applicable Systems/Platforms

Use of this action is supported on the following systems/platforms:Windows.

Applicable Built-In Settings

The following settings are applicable to this action: remove double quotes from cells.

Example

Scenario: You are aware of the fact that the AUT under development is, at times, capable of throwing unexpected exceptions, resulting in the appearance of modal dialogs. You wish to allow your test to handle such exceptions gracefully wherever they may occur, by dismissing the dialog, so that automation may continue. You also want to record the error message displayed by the dialog. Hence, you want the action lines handling this contingency to:

  1. capture screenshots when the modal dialog box unexpectedly appears, using the built-in capture screen action;
  2. click the Continue button, which such exception dialogs are always expected to have, to dismiss the dialog and allow automation to proceed; and
  3. Allow for the possibility that a modal dialog other than the standard “Unhandled exception” dialog has appeared, one that lacks a Continue button. Hence, if your procedure is unable to find a Continue button, simply attempt to close the modal dialog box with a built-in close window action.

Action Lines

Result

At line #19 in the test procedure during the automated run, an unexpected modal dialog box appears. This triggers the modal dialog handler action to dismiss the dialog. Subsequently, TestArchitect resumes normal automation starting with the last action (line #19) executed prior to the invoking of the handler action.


Copyright © 2023 LogiGear Corporation. All rights reserved. LogiGear is a registered trademark, and Action Based Testing and TestArchitect are trademarks of LogiGear Corporation. All other trademarks contained herein are the property of their respective owners.

LogiGear Corporation

1730 S. Amphlett Blvd. Suite 200, San Mateo, CA 94402

Tel: +1(800) 322-0333