我该如何解决“引发新错误('无法解析privateKey:'+ privKeyInfo.message);”在Windows中"/>
我该如何解决“引发新错误('无法解析privateKey:'+ privKeyInfo.message);”在Windows中
当我运行测试时,我在Windows测试客户端中收到此错误
CypressError:cy.exec('npm run -s command')失败,因为该命令以非零代码退出。
传递{failOnNonZeroExit:false}以忽略退出代码失败。
有关失败的信息:代码:1
Stderr:C:\ Users \ Administrator.jenkins \ workspace \ cypress-execution \ node_modules \ ssh2 \ lib \ client.js:146抛出新的错误('无法解析privateKey:'+ privKeyInfo.message);
回答如下:用try... catch
块包装代码
try {
throw 'myException'; // your code goes here
}
catch (e) {
console.log(e);
}
更多推荐
我该如何解决“引发新错误('无法解析privateKey:'+ privKeyInfo.message);”在Windows中
发布评论