Support and Forum Vets,
I am having an issue with something pretty simple. When I start a test on a webdriver endpoint, the test starts and gets to the correct landing page, but about 30% of the time, it fails to click the login button on the page.
I have tried everything that I can think of (including many of the Ranorex API options like Ensurevisible and WaitforExists) I have even tried to use some native c# webdriver stuff.
Now I am at the point in which I click on the button, check to see if the URL changes, and then if I need to, try to click the button again. This doesn't even work 100% of the time.
Any ideas what I can try next or have you seen anything like this before?
Ranorex version: 9.3.2
Selenium grid cloud provider: Testingbot
Url: rosieapp.com
Thanks in advance,
Bryon Sullivan
Inconsistent Clicking on Webdriver endpoint
-
- Posts: 4
- Joined: Thu May 30, 2019 8:22 pm
- Support Team
- Site Admin
- Posts: 12145
- Joined: Fri Jul 07, 2006 4:30 pm
- Location: Houston, Texas, USA
- Contact:
Re: Inconsistent Clicking on Webdriver endpoint
Hello Bryon,
This sounds like a timing issue in my opinion. Most probably, the button is not fully loaded or ready to be clicked.
Please add a delay right before doing the click. If this doesn't help, you can try to split up the mouse click event into a mouse move and a click event. When moving the mouse to the button first, the button gets time to get activated (by mouse hover).
I hope this helps.
Regards,
Bernhard
This sounds like a timing issue in my opinion. Most probably, the button is not fully loaded or ready to be clicked.
Please add a delay right before doing the click. If this doesn't help, you can try to split up the mouse click event into a mouse move and a click event. When moving the mouse to the button first, the button gets time to get activated (by mouse hover).
I hope this helps.
Regards,
Bernhard
-
- Posts: 4
- Joined: Thu May 30, 2019 8:22 pm
Re: Inconsistent Clicking on Webdriver endpoint
Bernhard,
Thanks for the reply. I have already tried that. Honestly I have tried everything that I can think of.
I have tried:
1. Using a Moveto() and then a Click()
2. Using a Click()
3. Using WaitForExists()
4. Using hard delays up to 30 seconds after Ranorex can validate that the item is present
5. Using a Click(), waiting, checking the URL to see if the page changed and if not Click() again
6. Getting the current endpoint as a Selenium webdriver, defining the object with a css selector, and clicking on it that way
7. Trying Host.Current.TryGetAsWebDriverEndpoint().StartBrowser() instead of Host.Current.OpenBrowser()
8. Multiple combinations of the above together
I think it may be time to engage support formally unless you have any other ideas?
Thanks for the reply. I have already tried that. Honestly I have tried everything that I can think of.
I have tried:
1. Using a Moveto() and then a Click()
2. Using a Click()
3. Using WaitForExists()
4. Using hard delays up to 30 seconds after Ranorex can validate that the item is present
5. Using a Click(), waiting, checking the URL to see if the page changed and if not Click() again
6. Getting the current endpoint as a Selenium webdriver, defining the object with a css selector, and clicking on it that way
7. Trying Host.Current.TryGetAsWebDriverEndpoint().StartBrowser() instead of Host.Current.OpenBrowser()
8. Multiple combinations of the above together
I think it may be time to engage support formally unless you have any other ideas?
- Support Team
- Site Admin
- Posts: 12145
- Joined: Fri Jul 07, 2006 4:30 pm
- Location: Houston, Texas, USA
- Contact:
Re: Inconsistent Clicking on Webdriver endpoint
Hello Bryon,
You could try to use an invoke action instead. You wrote, the element is a button type, so you can use the invoke action "Press" in the recorder.
If you use code, the call of the method looks similar to this one:
Regards,
Bernhard
You could try to use an invoke action instead. You wrote, the element is a button type, so you can use the invoke action "Press" in the recorder.
If you use code, the call of the method looks similar to this one:
repo.ClearEntryButton.Press();If this doesn't help, please create a Support Ticket.
Regards,
Bernhard