First Commit
This commit is contained in:
		
							
								
								
									
										2
									
								
								.gitignore
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										2
									
								
								.gitignore
									
									
									
									
										vendored
									
									
										Normal file
									
								
							| @ -0,0 +1,2 @@ | |||||||
|  | venv/ | ||||||
|  | geckodriver.log | ||||||
							
								
								
									
										16
									
								
								main.py
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										16
									
								
								main.py
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,16 @@ | |||||||
|  | from time import sleep | ||||||
|  | from selenium import webdriver | ||||||
|  | from selenium.webdriver import common | ||||||
|  | from selenium.webdriver.support import ui, expected_conditions | ||||||
|  |  | ||||||
|  | if __name__ == "__main__": | ||||||
|  |     opts = webdriver.FirefoxOptions() | ||||||
|  |     # opts.add_argument("-headless") | ||||||
|  |     webd = webdriver.Firefox(options=opts) | ||||||
|  |     webd.get("https://hplanning2022.umons.ac.be") | ||||||
|  |  | ||||||
|  |     horaires = ui.WebDriverWait(webd, 3).until(expected_conditions.presence_of_element_located((common.by.By.XPATH, "/html/body/div[1]/div[3]/div[3]/div[2]/div[1]/div/ul/li[4]/b/a/div"))) | ||||||
|  |     horaires.click() | ||||||
|  |  | ||||||
|  |     cours = ui.WebDriverWait(webd, 3).until(expected_conditions.presence_of_element_located((common.by.By.XPATH, '//*[@id="GInterface.Instances[1].Instances[1].bouton_Edit"]'))) | ||||||
|  |     cours.click() | ||||||
		Reference in New Issue
	
	Block a user