cypress-io / cypress-io/code-coverage

Improve backend code coverage performance

Open
#933 0 comments 0 reactions 0 assignees View on GitHub
performance
Dominant language
TypeScript
Stars
445
Forks
115
PR merge metrics
No merged PRs in 30d

Description

[This code](https://github.com/cypress-io/code-coverage/blob/eca3ba7af1a16737e2a06842a395b0afe61b50c0/support.js#L193-L222) uses a `cy.request` to query the running dev servers to get their coverage which then just gets loaded in client-side and immediately sent to the Cypress server via a `cy.task`. It likely could be more efficient (skip one network hop, avoid transferring the data to the browser, and populating the cy.task message field with the large amount of data) to query the dev server directly from the Cypress app server.

The only way this falls apart is if the dev servers have to be accessed via `cy.request` but i'm not sure that is a likely scenario. We could always detect whether the coverage routes are accessible first and then fallback to the existing logic otherwise.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.