wait_for_browser_close should really be called exit_on_browser_close