Telerik blogs

Test Studio's clicking and typing steps come in two varieties: regular and simulated clicks. You can flip between the two by going into the Properties menu for the respective step:

A regular (non-simulated) click/typing is an action that is injected directly into the DOM of the page. This has advantages - it's faster and more reliable. It will work even if you run the test on a locked desktop. But it's fundamentally different from a real user clicking/typing on a control.
And the disadvantage is that it will not trigger any events that are associated with the control in question. 

Often you will have a javascript function that is triggered by a specific event (OnMouseOver, OnKeyPress etc). on a specific control. Generally, a non-simulated click will not trigger such an event. Consequently the javascript function will not be fired off and some action that you're expecting within your application will not occur. You can try it out your self on the following sample page. The onkeydown event is a pretty typical example of this problem.

So there you have it: whenever your click/typing steps don't seem to be doing what they're supposed to do - try flipping them to SimulateRealClick=true. It will help a lot of the time.

About the author

Stoil Stoichev

Stoil Stoychev

has been helping customers solve their complex testing challenges leveraging his in-depth knowledge of Telerik Test Studio. He has traveled the globe fine-tuning his technical expertise and helping our valued clients succeed. In his spare time he enjoys motorcycles, live music and various sports.


Comments are disabled in preview mode.