Handle Dialog Block
Accepts or dismisses a JavaScript initiated dialog (alert, confirm, prompt, or onbeforeunload).
You need to use this block before the dialog occurs. For example, when a dialog is occurred after clicking an element.
Accept dialog
Whether to accept or dismiss the dialog.Prompt text
The text to enter into the dialog prompt before accepting. Used only if this is a prompt dialog.