Noticed that Cypress test runner is cutting out X-CSRFToken from the request header, which causes the request to return 403 Forbidden. Here is the screenshot of headers from manual run and Cypress test run,
Screenshot taken while navigating in Chrome browser: 
Screenshot taken while running Cypress test: 
To confirm this, I replayed the request through curl attaching the X-CSRFToken. It worked fine then. How could I handle this while running Cypress tests?
Aucun commentaire:
Enregistrer un commentaire