如何使用量角器处理Windows文件上传和下载脚本?Windows file Upload Image
答案 0 :(得分:0)
<input name="upload" type="file">
上传解决方案:
var absolutePath = path.join(__dirname,'..\\..\\dash-e2e-tests\\resources\\files-cabin\\test-files\\image.png); element(by.xpath("xpath")).sendKeys(absolutePath);
下载解决方案:
capabilities: {
browserName: 'chrome',
'chromeOptions': {
prefs: {
download: {
'prompt_for_download': false,
'directory_upgrade': true,
'default_directory': downloadfile
}
}
}
},