Forum Discussion
From your original question, you recorded the steps initially. Could you paste a screenshot of the keyword test or the script you recorded? Usually, the recording will expose how you need to reference that auto-completion so you can code around it.
I join you my Key word test "AssignationEssais"
the Keyword test stop at the "textnodeTestComplete" item and launch an error
thank you for help
- tristaanogre9 years agoEsteemed Contributor
OK, that's excellent.
So, basically, what is probably happening (and this is conjecture based upon experience) is that there is a slight timing delay between when your keyword test enters the text and when the text box pops up. However, during that delay, your test is continuing and is attempting to click on the text box before it exists or before it has fully populated. That is what is causing your general problem... that the "Click" is being attempted before the text box is fully rendered.Three ways you can solve this:
1) Insert a Delay between when you type the text and when you click on the text box. This is the quick and dirty way of doing it. It works but it's clumsy in that you are hardcoding the delay. What if you run the test on a machine that performs more slowly? Is your delay going to be long enough. It works, but, as I said, it has it's problems.
2) Use the custom timeout option to specify to wait some time for the object to be present before attempting the click. Information on this can be found at https://support.smartbear.com/viewarticle/73343/. I've had some luck with this in the past but I've found that, along with Delay, it can be a bit clumsy because the timing is never exactly the way you want it to be. Additionally, it's dependant somewhat on the object pre-existing. So, it may or may not work.
3) Utilize the WaitNNN methods within your keyword test. THIS is my favorite option. Now, I could describe it for you in detail here... but thankfully, the guys at SmartBear already wrote up how to do this in their online guide. Read the whole article but the stuff you'll be most interested in is at and around https://support.smartbear.com/viewarticle/68268/?q=wait+for+object#KDTTimeout
Hope this helps!