Stuff about software development, agile and testing

Monday, January 12, 2009

Testing File upload with Watir

For uploading file from watir test we have to do something like following

@browser.file_field(:name, "fileUploadFieldName").set "path.to.file"

But when I was running my test(on windows) I was getting the following error

Watir::Exception::WatirException, "The AutoIt dll must be correctly registered for this feature to work properly"

Apparently what this means is you have to install AutoIt and once you do that everything works as you expected. I kind of discovered it in a hard way but maybe some else will find this little information useful.





Labels