Last active
December 14, 2019 17:04
-
-
Save brcontainer/89c286c237c0c710c0483ebface9c208 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from selenium import webdriver | |
lista_nomes = ['Joao Arruda Botelho','Camila Moraes Sarmento','Regina Moreira Salles'] | |
lista_emails = ['[email protected]', '[email protected]', '[email protected]'] | |
driver = webdriver.Chrome() | |
url = "http://painelvix.com/galaxia4/formulario_testes.php?r=UUVJcFdZMXlZcE5XdVU2cGVEUjVMYllMNnVBYS9GajVVUkZ3em9tRDZObz0," | |
for k in range(3): | |
driver.get(url) | |
driver.find_element_by_name("nome").click() | |
driver.find_element_by_name("nome").clear() | |
driver.find_element_by_name("nome").send_keys(lista_nomes[k]) | |
driver.find_element_by_name("email").click() | |
driver.find_element_by_name("email").clear() | |
driver.find_element_by_name("email").send_keys(lista_emails[k]) | |
driver.find_element_by_name("perfil[]").click() | |
try: | |
driver.find_element_by_xpath("//*/text()[normalize-space(.)='Solicitar']/parent::*").click() | |
except: | |
continue | |
driver.close() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment