下载文件量角器测试用例

时间:2014-11-28 17:16:35

标签: angularjs protractor angularjs-e2e

我正在编写一个量角器测试用例来下载一个可以是任何类型的文件。

  senario:To download a file
  Step 1-click on the downloadlink
  Step 2-check whwther the file is downloaded or not

我现在如何检查文件是否正确下载。

1 个答案:

答案 0 :(得分:18)

我能够通过Chrome实现下载测试。

  1. 请按照此配置设置:https://stackoverflow.com/a/26127745/511069

  2. 创建function waitFileExists(fileAbsPath)并在文件完全下载后执行您的期望:https://stackoverflow.com/a/27031924/511069

相关问题