This is a migrated thread and some comments may be shown as answers.

How to invoke script on checkbox selection from pop-up menu?

9 Answers 161 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Dipali
Top achievements
Rank 1
Dipali asked on 10 Apr 2012, 03:57 PM

Hi,

The scenario I am trying to automate is:

  1. Click on menu. It opens up a pop-up menu having different options listed along with the checkbox for each option.
  2. Select the checkbox for an option.
  3. Selection of check box adds one more option to the same menu called as ‘Apply’. Click the ‘Apply’ option.

Now I am trying to record this scenario using Telerik Test studio. When I am executing the recorded steps, I could successfully select the checkbox from pop-up menu. But after that ‘Apply’ option is not getting added to the same pop-up menu.

Could someone please advise me on how can I deal with the above scenario?

9 Answers, 1 is accepted

Sort by
0
Plamen
Telerik team
answered on 10 Apr 2012, 05:03 PM
Hi Dipali,

This sound like a javascript event issue. Probably the underlying "onclick" javascript is not being triggered for the checkbox. Ensure the "InvokeOnClick" property is set to True for the "Check" step (see screenshot).
  
If it is and the javascript isn't triggering, you might try disabling that step and recording a Desktop Left Mouse click step on the checkbox instead from the Mouse Actions option on the Elements Menu.

Regards,
Plamen
the Telerik team
Quickly become an expert in Test Studio, check out our new training sessions!
Test Studio Trainings
0
Dipali
Top achievements
Rank 1
answered on 11 Apr 2012, 08:12 AM
Hi Plamen,

As you have shown in the image ‘InvokeOnClick.png’, InvokeOnClick propert is set to True in my case.

The second approach of adding a mouse click even through Elements menu: While trying to add mouse event I am facing a issue. When I select the Blue bubble icon to add mouse event, my pop-up menu options gets disappear from the screen and then I cannot perform any action through Elements menu for the expected checkbox UI control.

Could you please let me know how to handle such controls?
0
Accepted
Plamen
Telerik team
answered on 11 Apr 2012, 05:57 PM
Hi Dipali,

To record the Mouse Click step you need to use our Freeze Mode feature. This feature freezes the page's DOM and allows you to record actions and verifications on a drop down by freezing the DOM at the moment it's expanded. 

Please give it a try and let me know if it works.

Greetings,
Plamen
the Telerik team
Quickly become an expert in Test Studio, check out our new training sessions!
Test Studio Trainings
0
Dipali
Top achievements
Rank 1
answered on 12 Apr 2012, 03:42 PM

Hi Plamen,

Thanks for quick response.

I tried using ‘Freeze Mode’ feature and I could successfully add one of the option from the pop-up menu. But, it took me a hell lot of time to  do so. The second cursor which appears is very troublesome to move it to the designated place.

For the pop-up menu I am using, the menu items depends on the user inputs. In the application under test, user creates some settings and these settings are my menu items. So I was trying to add the pop-up menu as an object to the elements library. But I could not do so as the second cursor is not moving swiftly. Also how can I go about selecting the items from this pop-up menu as the menu items are dynamically generated?

0
Plamen
Telerik team
answered on 17 Apr 2012, 11:36 AM
Hi Dipali,

Would it be possible for us to get direct access to your application? This would be the fastest and easiest way for us to help you with the problem you are experiencing. If it is not possible, we suggest you take a Fiddler trace and attach it to the ticket. If you are unfamiliar with how to do that please refer to this short video. You can download the Fiddler application here. If you deem that information too sensitive for this forum, you can create a support ticket and attach it there.

Also, I'm not completely sure but there might be a jQuery event attached to the CheckBox. Test Studio is checking the box through the UI during execution, but it won't automatically process the jQuery event. If that's the case, here is an article explaining how to overcome the problem with a coded step.

All the best,
Plamen
the Telerik team
Quickly become an expert in Test Studio, check out our new training sessions!
Test Studio Trainings
0
Dipali
Top achievements
Rank 1
answered on 26 Apr 2012, 06:55 AM

Hi Plamen,


I was trying Freeze mode on VM m/c. then I tried to use Freeze mode on physical m/c and it worked fine for me. I could solve the issue.

Many Thanks for your help!!!
0
Plamen
Telerik team
answered on 26 Apr 2012, 02:27 PM
Hello Dipali,

I am glad to hear that the issue is resolved! Please feel free to contact us again if you have any questions.

All the best,
Plamen
the Telerik team
Quickly become an expert in Test Studio, check out our new training sessions!
Test Studio Trainings
0
Rolando
Top achievements
Rank 1
answered on 30 Oct 2012, 10:38 PM
Hello Plamen

I have a serious problem

Win7, 64bits, Telerik Test Studio 2012.2.920.0

The Freeze mode is not recording any action.
Example:
I Start recording, get into my website, go to a menu and mouseover it, activate the Freeze mode ( Scroll lock key ) and got the new mouse pointer with the lock so then move over an option from the displayed submenu and got the blue nub, then click on the blue nub and nothing happens

This is getting me crazy since i read that other people is working fine with this

The website use aspx and ajax to handle the controls of those mouseover actions

Hope you can guide me on this
Thanks
0
Plamen
Telerik team
answered on 05 Nov 2012, 11:27 AM
Hi Rolando,

This seems to be a duplicate of support ticket 624381. We'll address the issue there to prevent duplicate effort on our end.

Regards,
Plamen
the Telerik team
Are you enjoying Test Studio? We’d appreciate your vote in the ATI automation awards.
Vote now
Tags
General Discussions
Asked by
Dipali
Top achievements
Rank 1
Answers by
Plamen
Telerik team
Dipali
Top achievements
Rank 1
Rolando
Top achievements
Rank 1
Share this question
or