如果我尝试启动我的办公室门户的url(可以正常手动运行),那我就从赛普拉斯那里得到了错误提示
cy.visit()尝试加载失败:
https://intrauat.web.bc/cgi-bin/index
我们从您的Web服务器收到的回复是:
401:未经授权
这被认为是失败的,因为状态代码不是2xx。
有什么帮助吗?
thnx shobhit
答案 0 :(得分:1)
尝试使用代理创建。
参考link
答案 1 :(得分:0)
如果您的网址需要oauth凭据。您可以使用:
cy.visit('https://intrauat.web.bc/cgi-bin/index', {
auth: {
username: 'test',
password: 'test'
}
})