Q. What happens when you call quit() on a WebDriver instance?

A
Closes the current tab only
B
Closes all associated browser windows and ends the session
C
Refreshes the page
D
Maximizes the window
Solution:

quit() terminates the WebDriver session and closes all browser windows.

Entri Contact Image

Get Expert Advice for Free: Register for Your Free Consultation Now!

    [honeypot honeypot-100]