I'm trying to automate uploading a file using selenium webdriver in Python. Right now, I have the following code:
url = "https://uploadfiles.io/"
driver = webdriver.Firefox(executable_path="/path/to/firefoxdriver")
driver.get(url)
getForm = driver.find_element_by_xpath("//form[@class='dropzone needsclick dz-clickable']")
getForm.send_keys("/path/to/somefile")
However, this doesn't work. For some weird reason it tries to find the text I'm sending in to send_keys on the page (like when you do command+f).