Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- driver = webdriver.Firefox()
- #Abre uma noba aba no site do google
- driver.execute_script("window.open('https://www.google.com');")
- #Troca o controle para a nova aba
- driver.switch_to_window(driver.window_handles[1])
- #Fecha a aba que estΓ‘ sendo controlada
- driver.close()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement