On a website I am testing we have various links that download PDF files to the users computer.
Our selenium suite runs nightly on bamboo, if we were to download the various files overnight it would cause the hard disk to fill up in short order. The Selenium job itself is sandboxed and can't access the file system to delete the file.
What is best practice for testing file downloads with this setup?
A few potential scenarios;
- Download the file and perform some kind of cron cleanup serverside (this might not be viable).
- Check the URL of the file location is as expected but don't download the file
- Click the link and accept the presence of a dialogue box as sufficient coverage (without downloading the file)