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

How to verify Javascript alert box

1 Answer 33 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Vishal
Top achievements
Rank 1
Vishal asked on 04 Mar 2014, 05:32 PM
Hi

I have a scenario where I have to verify whether javascript  alert has appeared or not. Based on the alert appearance I have to perform few more checks.
Please let me know how should I verify whether javascript alert has appeared or not?

It would be really helpful if you could provide me a sample code..

1 Answer, 1 is accepted

Sort by
0
Velin Koychev
Telerik team
answered on 07 Mar 2014, 04:02 PM
Hello Vishal,

You can write your own Custom Dialog Handler for that purpose.  Inside MyCustomAlertHandler you can write the code that will be executed only if the alert dialog is triggered. 

Let me know if you need any additional assistance. 

Regards,
Velin Koychev
Telerik
Quickly become an expert in Test Studio, check out our new training sessions!
Test Studio Trainings
Tags
General Discussions
Asked by
Vishal
Top achievements
Rank 1
Answers by
Velin Koychev
Telerik team
Share this question
or