Wait For Not Exists & Validate (NotExists) failure

Bug reports.
User avatar
odklizec
Ranorex Guru
Ranorex Guru
Posts: 3922
Joined: Mon Aug 13, 2012 9:54 am
Location: Zilina, Slovakia

Wait For Not Exists & Validate (NotExists) failure

Post by odklizec » Wed Jan 15, 2014 2:15 pm

Hi,

New day, new issue ;) OK, my new problem is like this. I have a recording, which closes the application then starts the Wait For Not Exists action with 5000ms timeout. And after this action, there is started Validate "NotExists" action.

The application is closed and Wait For Not Exists is almost immediatelly finished (in less than 2 sec.), so the application must really be terminated/not existing, right? The thing is, that Validate "NotExists" action sometimes fails with "Element for item 'Repository.AppName.Self' does exist." error.
WaitForNotExists.png
Left report shows that "Wait For Not Exists" takes slightly over 1sec to complete. Why it's finished if the application still exists?
WaitForNotExists.png (603.16 KiB) Viewed 2161 times
Why the Wait For Not Exists is terminated before the timeout is reached and the application probably still exists? How this could happen?

I tried to turn the Turbo playback OFF, but this did not help. The only thing that helped was adding a forced Delay before the Validate step, but I would like to avoid that.

This recording worked fine but all of suddenly, it started to act like this. Could it be something wrong in 4.1.4? Does the Wait For Not Exists action use a different kind of element existence detection than Validate "NotExists" action?

Unfortunately, I don't have a demo to share. I'm only able to reproduce it after loading and unloading number of proprietary files, which takes about 15 minutes to complete the test. Our nightly test loads even greater number of these files and the test takes about 2 hours to complete. And as I said, exactly the same test worked fine before.
Pavel Kudrys
Ranorex explorer at Descartes Systems

Please add these details to your questions:
  • Ranorex Snapshot. Learn how to create one >here<
  • Ranorex xPath of problematic element(s)
  • Ranorex version
  • OS version
  • HW configuration

User avatar
rprehm
Posts: 24
Joined: Tue Dec 17, 2013 6:43 pm

Re: Wait For Not Exists & Validate (NotExists) failure

Post by rprehm » Fri Jan 17, 2014 4:43 pm

Hello odklizec,

Unfortunately this is not the expected behavior of the WaitForNotExists respectively Validate.NotExists. We are not able to reproduce the issue on our side.
Can you please add a snapshots action before and after the WaitForNotExists in in order to analyze the problem?
Report_Snaphot.png
Report_Snaphot.png (40.5 KiB) Viewed 2150 times
Please send the Snapshot files as well as the Report files to: [email protected]
Thank you very much for your efforts and your cooperation!

Regards,
Robert

User avatar
Support Team
Site Admin
Site Admin
Posts: 11709
Joined: Fri Jul 07, 2006 4:30 pm
Location: Graz, Austria

Re: Wait For Not Exists & Validate (NotExists) failure

Post by Support Team » Fri Jan 17, 2014 10:55 pm

An addendum to the post from Robert:
"Wait For Not Exists" uses the absolute path to search for the element, whereas "Validate NotExists" uses the repository structure including cached folder elements.

In other words: WaitForNotExists could return successfully (meaning the item is not found) if e.g. the (absolute) RanoreXPath checks for the window title and the window title is not the same any more. However, the Validate.NotExists could still find the element (and consequently fail) if the window element is cached from previous actions on the item.

Have you tried disabling caching ("Use Cache") of the app/rooted folder?

Regards,
Alex
Ranorex Team
.
Image

User avatar
odklizec
Ranorex Guru
Ranorex Guru
Posts: 3922
Joined: Mon Aug 13, 2012 9:54 am
Location: Zilina, Slovakia

Re: Wait For Not Exists & Validate (NotExists) failure

Post by odklizec » Mon Jan 20, 2014 9:31 am

Hi Robert and Alex,

Thanks for your suggestions. I will try both of them and let you know the result. It's definitely a weird behavior.
Pavel Kudrys
Ranorex explorer at Descartes Systems

Please add these details to your questions:
  • Ranorex Snapshot. Learn how to create one >here<
  • Ranorex xPath of problematic element(s)
  • Ranorex version
  • OS version
  • HW configuration