📜  如何通过量角器上传 csv 文件 - 无论代码示例

📅  最后修改于: 2022-03-11 14:57:37.460000             🧑  作者: Mango

代码示例1
it('upload file', function(){
  var fileToUpload = 'C:/Users/Anusha/Desktop/demo.csv';
  var absolutePath = path.resolve(fileToUpload);
  var button = element(by.css('[ng-file-select]');
  button.click();
  var input = element(by.css('input[type="file"]'));
  input.sendKeys(absolutePath);
});