wait for not exists

Ask general questions here.
martinsw
Posts: 72
Joined: Fri Dec 09, 2011 2:48 pm

wait for not exists

Post by martinsw » Wed Jul 25, 2012 12:27 pm

Dear Ranorex,

The "wait for not exists" action comes with a timeout value. I am building an automation to test a web application and I don't want my automation to wait any longer than is necessary (speed is of the essence!).

Once the element concerned no longer exists, I want the automation to proceed to the next step straight away rather than waiting for the specified timeout value to elapse. Is there a value that I can specify for the timeout period which will make this happen? (i.e. would setting the timeout period to "0" have this effect?)

What I want is for the "wait for not exists" action to be "performance sensitive". For example, if network performance is good during test run A and the element no longer exists after 500ms, I want the automation to proceed to the next action straight away. However, if network performance is slow during test run B and it takes the element 2 seconds to no longer exist, again I want the automation to wait no longer than is necessary (in this case 2 seconds) before proceeding to the next step.

Is there any way this can bee achieved?

Thanks, Martin

User avatar
Support Team
Site Admin
Site Admin
Posts: 12145
Joined: Fri Jul 07, 2006 4:30 pm
Location: Houston, Texas, USA
Contact:

Re: wait for not exists

Post by Support Team » Wed Jul 25, 2012 3:40 pm

Hi Martin,

The "WaitForNotExists(waitTimeout)" action does exactly what you want to achieve.
The waitTimeout parameter just tells Ranorex how long the automation should wait maximally for the disappearance of an item.

Kind regards,
Larissa
Ranorex Support Team

User avatar
artur_gadomski
Posts: 207
Joined: Mon Jul 19, 2010 6:55 am
Location: Copenhagen, Denmark
Contact:

Re: wait for not exists

Post by artur_gadomski » Thu Jul 26, 2012 6:47 am

But doesn't it also wait as log as search timeout is on the element? If it's 30s it will return 30s after element disappears.

martinsw
Posts: 72
Joined: Fri Dec 09, 2011 2:48 pm

Re: wait for not exists

Post by martinsw » Thu Jul 26, 2012 9:41 am

Thanks Larissa

User avatar
Support Team
Site Admin
Site Admin
Posts: 12145
Joined: Fri Jul 07, 2006 4:30 pm
Location: Houston, Texas, USA
Contact:

Re: wait for not exists

Post by Support Team » Thu Jul 26, 2012 10:16 am

You are welcome, Martin.

@ Artur:
Imagine following scenario: We have an item MyItem within a recording and we want to continue the automation as soon as MyItem disappears.

Since we want to continue as soon as possible with automation we use the action WaitForNotExists instead of Delay.

Now Ranorex does the following:
The search timeout of MyItem defines the time-interval used for the search of the item. If the item can't be found in this period, the run ends with a failure. If the item is found in this period Ranorex performs the action on our item MyItem (the WaitForNotExist action) and continues immediately after MyItem disappears.

Hope the difference is clear now.
Larissa
Ranorex Support Team