My playwright test never passes when I use the command "page.waitForResponse". Although the API call is performed and can be seen in the network tab of chrome. I set the jest timeout to 30000, but this does not seem to be the issue.
it("Test", async () => {
await page.goto("http://localhost:8080/")
await Promise.all([
await page.waitForResponse("https://development/my/call", {
timeout: 1000,
}),
page.click("css=body")
])
})
Network
url: https://development/my/call
Status: 200
Type: xhr
Error
Async callback was not invoked within the 30000 ms timeout specified by jest.setTimeout.Error