Take the 2-minute tour ×
Software Quality Assurance & Testing Stack Exchange is a question and answer site for software quality control experts, automation engineers, and software testers. It's 100% free, no registration required.

Am new to selenium web driver.

I need to download the file, if we click on download, after downloading it it will ask confirmation to open or save file. It should save with out asking confirmation.

Please help me how to handle this.

share|improve this question
1  
When you say "it should save without asking confirmation" do you mean you need to know how to handle the confirmation dialog (which is standard in web applications) or you need to know how to disable the confirmation dialog for testing purposes? –  Kate Paulk Jan 7 at 13:11
add comment

1 Answer

If your goal is to bypass the confirmation for testing purposes, I know this can be done for Chrome:

  1. Open chrome://settings/ in the Chrome browser
  2. Select the "Show advanced settings..." link
  3. Scroll down to the "Downloads" settings
  4. Uncheck the box labeled "Ask where to save each file before downloading"

If you run your tests on Chrome you should be able to verify your download process with a more pure Selenium approach (not having to dabble in any black magic to get script away that dialog)

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.