开发者

(Selenium) How to test whether a download of a certain file was started?

I want to test whether a certain action results in a file download (a) at all, and (b) with the file having a certain开发者_开发技巧 name.

Is there any way to use Selenium to do this?


The current version of Selenium runs in the JavaScript sandbox so can't control things outside of the page such as downloading files, uploading files, etc.

You might find that WebDriver (soon to be Selenium 2.0) supports downloads as it is not restricted to JavaScript in the same way as Selenium 1.0. See http://code.google.com/p/selenium/wiki/GettingStarted for more information.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜