Q:

Selenium webdriver how to do file upload with ng-click="upload('files')"

I'm trying to see if this is possible - to automate a file upload when the HTML code is NOT an
< input type='file' >

but rather a link 
<a ng-click="upload('files')"> File Upload </a>

When this link is clicked, it automatically opens a file selector to choose which file you want to upload.
The problem is, it does not contain an INPUT type='file' element which I could locate and then use webdriver.send_keys('/Users/myname/testfile.txt').
How can I go about trying to get selenium webdriver to handle this file upload? 
Any help to direct me to a solution is greatly appreciated.

A:

Last time that i needed this WebDriver couldn't interact with dialogs cause dialogs are the domain of the operating system and not the webpage.
One option would be to skip the file dialog entirely and issue a POST/GET/PUT, but this requires more advanced knowledge of the website as well as understanding of how to construct a request.
What i did in that ocation was to create an auxiliar program executable for dealing with the dialog, so i called it in the middle of the Selenium script, just after generating the dialog.
Here you have a sample of the last approach using Java & AutoIT: http://www.automationtesting.co.in/2009/07/selenium-handle-dialogs.html

