用守夜人守望网络

我正在使用 nightwatch 来测试应用程序的前端.我正在测试某些按钮是否可点击.

I'm using nightwatch to test the frontend of an application. I'm testing that some buttons are clickable or not.

是否可以用nightwatch,知道是否有网络点击发出的请求,或者更一般地说,观看网络.

Is it possible with nightwatch, to know if there was a network request made by the click, or more generally, to watch the network.

推荐答案

是的,你可以使用 https://www.npmjs.com/package/nightwatch-xhr 以监视来自 Nightwatch.js 的 Ajax 请求.

Yes, you can use https://www.npmjs.com/package/nightwatch-xhr in order to watch for Ajax requests from Nightwatch.js.

(我是维护者之一)

相关文章