Setting a Wait State for an Object

This feature is used to set a wait state for an object during playback to check for its existence. This is useful when waiting for an object right after starting your application, or after other actions that may take a long time.

To set a wait state:

  1. In Functional Tester, Java Scripting, click the Record a Functional Tester Script button or the File > New > Functional Test Script Using Recorder menu command to start recording a script. See Recording a Script in Functional Test, Java Scripting for more information. In Functional Tester, Java Scripting, click the Record a Functional Tester Script button or the File > New > Add Script Using Recorder menu command to start recording a script. See Recording a Script in Functional Test, VB.NET Scripting for more information.

  2. In the Recording Monitor, click the Start Application button to start your test application. See Starting Your Test Applications for more information.

  3. Locate the object in your application that you want to wait for.

  4. In the Recording Monitor, click the Insert Verification Point or Action Command button.

  5. On the Select an Object page of the Verification Point and Action Wizard, use the Object Finder to select the object in your application. See the Select an Object page for more information about selecting objects. Once you have selected the object, click Next.

  6. On the Select an Action page, click the Wait for Selected Test Object option, which is the fourth option on the page. Then, click Next.

    To set a wait state for the object, either use the defaults, or set your own time. Maximum Wait Time is the maximum number of seconds Functional Tester will wait for the object to appear in your application during playback. Check Interval is the number of seconds between times that Functional Test will check for the object during the wait period.

    When Use the defaults is checked, Functional Tester will check for the existence of the object in your application every 2 seconds, for up to 120 seconds. To set your own time, clear the Use the defaults check box and type in your own values for Maximum Wait Time and Check Interval.

  7. Click Finish.

    The statement containing the waitForExistence will then be written into your script at the point you inserted the object.

Terms of use | Feedback
(C) Copyright IBM Corporation 2002, 2004. All Rights Reserved.