Test pauses or hangs when checking checkbox?

Ask general questions here.
Fergal
Certified Professional
Certified Professional
Posts: 333
Joined: Tue Feb 18, 2014 2:14 pm
Location: Co Louth, Ireland
Contact:

Test pauses or hangs when checking checkbox?

Post by Fergal » Thu Apr 16, 2020 8:49 am

Ranorex 9.3.0

I have a test which requires checking a checkbox in a drop down menu, on a Windows desktop application. The checkbox is identified using a repository variable in the XPath and has an Effective timeout of 1 minute.

I've tried using two different actions to check that checkbox: (1) Invoke action - Check and (2) Set value - Checked. Both of these actions cause the Ranorex test run to pause and just hang. The test keeps running - it doesn't fail or stop, but no further actions are performed beyond the Invoke or Set Value actions . No error message is given and the only way to stop the test is to manually stop the Ranorex test run. Although the effective timeout is 1 minute, the test can hang like this for over 10 minutes before I stop it manually.

Would you please have any suggestions to resolve this?

Thanks.

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

Re: Test pauses or hangs when checking checkbox?

Post by odklizec » Thu Apr 16, 2020 9:22 am

Hi,

Well, at first, you should try the most recent 9.3.1 with number of bugfixes. Then instead of invoking action or using SetValue, try the good old mouse click, which is the best (most recommended) action anyway. Neither Set Value or Invoke Action is user-like action, so it should be used with caution! On the other hand, neither action should hang the test ;) Also, does this happen also on other computers?
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

Fergal
Certified Professional
Certified Professional
Posts: 333
Joined: Tue Feb 18, 2014 2:14 pm
Location: Co Louth, Ireland
Contact:

Re: Test pauses or hangs when checking checkbox?

Post by Fergal » Thu Apr 16, 2020 12:00 pm

Thanks very much odklizec.

I have updated to 9.3.1 and still have the issue.
odklizec wrote:
Thu Apr 16, 2020 9:22 am
...instead of invoking action or using SetValue, try the good old mouse click...
A mouse click is also my preferred option. The item to be clicked is low down on the drop down options and is not visible when the drop down is expanded. Using an invoke ensure visible on the item did not work, hence I tried the invoke check and set value actions.

The test is being run on a client's app on their VM and unfortunately I cannot try it on another machine at this time.

Any further suggestions would be great.

Thanks again.

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

Re: Test pauses or hangs when checking checkbox?

Post by odklizec » Thu Apr 16, 2020 12:55 pm

Hi,

The "invisible" option may be the reason of your issue, but it's hard to tell without seeing your app and particular VM setup? In case the option you want to click is in the dropdown, then I would suggest to try bringing it up by typing the name of option directly in the dropdown. Usually this works with web dropdowns, but I'm not sure about the desktop apps and particularly your app? It may or may not work? ;) Just give it a try.
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

Fergal
Certified Professional
Certified Professional
Posts: 333
Joined: Tue Feb 18, 2014 2:14 pm
Location: Co Louth, Ireland
Contact:

Re: Test pauses or hangs when checking checkbox?

Post by Fergal » Thu Apr 16, 2020 1:23 pm

odklizec wrote:
Thu Apr 16, 2020 12:55 pm
... try bringing it up by typing the name of option directly in the dropdown. ..
Thanks again odklizec, unfortunately that doesn't work for this particular drop-down.

Replying to your earlier post gave me an idea for a workaround, which is not perfect but is working for the moment. An earlier test in the test suite, creates the item with the checkbox, which appears in the drop-down. I've updated that test to add a "0" before the item name, thus bringing it to the top of the drop-down menu list (alphabetical order), from where it can be clicked. Don't believe I would have thought of that without your input and your help is much appreciated.