Cypress : Some network requests does not get initiated/called when test is executed in chrome headless mode

54 Views Asked by At
  1. I have a test scenario in cypress which gets passed in headed mode. When I look for the logs in test runner in left panel, I see set of XHR getting called and its respective passed status.

  2. But same scenario when I execute in headless mode, observed below 2 issues. 2.1 Some network request did not get appeared when checked in log in execution video. 2.2 Some network requests which gets passed in headed mode fails in headless mode.

  3. This is quite a new thing I have observed. I have tried different timeouts. but that did not help. Not sure this is being originated from cypress or Application itself is causing some error. I am using latest cypress version 13 and chrome version 120

The expected output :

  1. Test scenario passing headed mode should get passed in headless mode.

  2. No matter the execution mode(headed/headless), Same set of Network requests should get called and its status can not be changed based on its execution mode.

0

There are 0 best solutions below