Ask a Question

TestComplete Verifying long wait time

Regular Visitor

TestComplete Verifying long wait time

I'm currently trying to verify a visual prompt reminder kinda like an icon showing up every hour. Normal I would just do a WaitProperty attaching isVisible, but I think waiting an hour pretty absurd. I was wondering if there is something like a passive wait where when testcomplete reaches a certain time it will pause it's current tests to finish verifying. I know exactly when the icon should show up. I could possibly run other test in between, but I'm cautious about timing.  Any suggestions?

Champion Level 3

You can try Delay.  

Community Hero



I suggest You write an interval function for these actions:

use Timer object:





// unit name 'Example1'
function run() {
  MyTimer = Utils.Timers.Add(3000, "Example1.timerRoutine", true);

function timerRoutine() {
  Indicator.PushText("FROM TIMER!")

// unit name 'Example2'
//USEUNIT Example1
function runTimer() {;  

  for(y = 1; y < 1000000; y++) {
    Indicator.PushText("waiting for timer!")




If You run this function, you can see that every 3s indicator will switch text from "waiting for timer!" to "FROM TIMER!"

Write Your own function to look for that popUp every 1h. But be careful.



When a timer elapses, TestComplete pauses the test to run the timer’s routine. The test is resumed after the timer routine has finished running.

Because of this, try to make timer routines as fast as possible. Using many timers with long-running routines can slow down the test run.


SmartBear Alumni (Retired)

Great suggestions, Community!


HI @joeychou99! Did you give this a try?

Sonya Mihaljova
Community and Education Specialist

Showing results for 
Search instead for 
Did you mean: