You may need to delay the test run at some point. For instance, the application under test may have to wait until the end of a time-consuming operation, such as loading a database or connecting to a network printer or another computer. Without a sufficient delay, the test run would have unexpected results.
You can set a pause between operations in a keyword test. To do this, place the Delay operation into the test before the delayed operation and specify the Delay Time parameter.
To delay the script run, use the
aqUtils.Delay method. This method uses two parameters: the first parameter is the delay time, in milliseconds; the second parameter is optional and specifies the text to show in the indicator. For example, the following code delays the script run for two seconds:
You can also use delays in a loop as to wait for a specific application’s response. For examples, see Waiting for Object State Changes.