Tell us how can we handle Web-based pop-up?

Submitted by: Muhammad
There are four methods of the effective Web-based pop-up handling:

☛ string getText() method returns the text displayed on the alert box
☛ void accept() method clicks on the “Ok” button as soon as the pop-up window appears
☛ void dismiss() method clicks on the “Cancel” button as soon as the pop-up window appears
☛ void sendKeys(String stringToSend) method enters the specified string pattern into the alert box
Submitted by: Muhammad

Read Online Automation Job Interview Questions And Answers