Q. Which method is used to switch to an alert in Selenium?
Solution:
switchTo().alert() switches the WebDriver focus to an alert popup for interaction.
Get Question Bank
Strengthen Your Practice with our comprehensive question bank.
switchTo().alert() switches the WebDriver focus to an alert popup for interaction.
Strengthen Your Practice with our comprehensive question bank.