NeuraLegion / cypress-har-generator

Cypress plugin for generating HTTP Archive (HAR) files captures network requests during Cypress tests.
https://www.npmjs.com/package/@neuralegion/cypress-har-generator
MIT License
80 stars 18 forks source link

Can I use this plugin to get a HAR file from the Cypress session itself, rather than the browser instance of each test? #402

Closed henricook closed 2 days ago

henricook commented 7 months ago

Description I'm trying to diagnose an issue where a setup call made by Cypress itself (cy.callAPI) is failing. It would be helpful if I could get a HAR file for callAPI requests too, is this plugin capable of that?

derevnjuk commented 2 days ago

@henricook Thanks for the question. Unfortunately, it's not currently possible, as the plugin only listens to browser network traffic and cannot intercept requests made directly by Cypress. Duplicate of https://github.com/NeuraLegion/cypress-har-generator/issues/59