Title: Slow performances when running tests with `--experimental-test-coverage` · Issue #55103 · nodejs/node · GitHub
Open Graph Title: Slow performances when running tests with `--experimental-test-coverage` · Issue #55103 · nodejs/node
X Title: Slow performances when running tests with `--experimental-test-coverage` · Issue #55103 · nodejs/node
Description: Version v22.9.0 Platform Darwin N4V4PGFGPT 23.6.0 Darwin Kernel Version 23.6.0: Mon Jul 29 21:16:46 PDT 2024; root:xnu-10063.141.2~1/RELEASE_ARM64_T8112 arm64 Subsystem No response What steps will reproduce the bug? Run tests with --expe...
Open Graph Description: Version v22.9.0 Platform Darwin N4V4PGFGPT 23.6.0 Darwin Kernel Version 23.6.0: Mon Jul 29 21:16:46 PDT 2024; root:xnu-10063.141.2~1/RELEASE_ARM64_T8112 arm64 Subsystem No response What steps will ...
X Description: Version v22.9.0 Platform Darwin N4V4PGFGPT 23.6.0 Darwin Kernel Version 23.6.0: Mon Jul 29 21:16:46 PDT 2024; root:xnu-10063.141.2~1/RELEASE_ARM64_T8112 arm64 Subsystem No response What steps will ...
Opengraph URL: https://github.com/nodejs/node/issues/55103
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Slow performances when running tests with `--experimental-test-coverage`","articleBody":"### Version\n\nv22.9.0\n\n### Platform\n\n```text\nDarwin N4V4PGFGPT 23.6.0 Darwin Kernel Version 23.6.0: Mon Jul 29 21:16:46 PDT 2024; root:xnu-10063.141.2~1/RELEASE_ARM64_T8112 arm64\n```\n\n\n### Subsystem\n\n_No response_\n\n### What steps will reproduce the bug?\n\nRun tests with `--experimental-test-coverage` option. Comparing it to other solutions (f.e. running Node tests and getting the coverage with `nyc`) this is way slower. For instance, on a repo with ~800 tests, collecting coverage with `nyc` takes 77s, while running with `--experimental-test-coverage` takes 148s.\n\n### How often does it reproduce? Is there a required condition?\n\nI can reproduce it every time I run the Node tests with the native test coverage option.\n\n### What is the expected behavior? Why is that the expected behavior?\n\nThe performances should be at least equal (ideally better) than with 3rd party dependencies (like `nyc`).\n\n### What do you see instead?\n\nAn average time spent per test of 185ms vs 96ms.\n\n### Additional information\n\nI tried running with/without additional options (f.e. `--test-coverage-exclude`, `--test-coverage-include`, `--test-coverage-branches`, `--test-coverage-functions`, `--test-coverage-lines`) but it didn't help. The performance issue seems only to be related to the algorithm that's triggered by the `--experimental-test-coverage` option.","author":{"url":"https://github.com/rozzilla","@type":"Person","name":"rozzilla"},"datePublished":"2024-09-24T15:50:16.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":10},"url":"https://github.com/55103/node/issues/55103"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:6edaa84d-d7d0-98ca-7bdf-363e66258df6 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | D2C4:DCE25:CCD3BB:128B73C:6A4CC4BA |
| html-safe-nonce | 61b0bb66f63481892a295f8bccb65a258d2a43a32c60f50e45abcb80f2ed4717 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJEMkM0OkRDRTI1OkNDRDNCQjoxMjhCNzNDOjZBNENDNEJBIiwidmlzaXRvcl9pZCI6IjQ0MDYwMDE4NjYwNjE0MzE5OTQiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 129f69a744cccf8c958de149b5fee19bfb4f0011217449a61766de22f6e32e6e |
| hovercard-subject-tag | issue:2545775650 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/nodejs/node/55103/issue_layout |
| twitter:image | https://opengraph.githubassets.com/8cb27bbca41809fe7cad7894c3ec0331c4dc26352000f68e0363d2774f106c22/nodejs/node/issues/55103 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/8cb27bbca41809fe7cad7894c3ec0331c4dc26352000f68e0363d2774f106c22/nodejs/node/issues/55103 |
| og:image:alt | Version v22.9.0 Platform Darwin N4V4PGFGPT 23.6.0 Darwin Kernel Version 23.6.0: Mon Jul 29 21:16:46 PDT 2024; root:xnu-10063.141.2~1/RELEASE_ARM64_T8112 arm64 Subsystem No response What steps will ... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | rozzilla |
| hostname | github.com |
| expected-hostname | github.com |
| None | 3d11bb817438277de2a940854450e83a7d32b6aeb5014e9e6b00a6423900251c |
| turbo-cache-control | no-preview |
| go-import | github.com/nodejs/node git https://github.com/nodejs/node.git |
| octolytics-dimension-user_id | 9950313 |
| octolytics-dimension-user_login | nodejs |
| octolytics-dimension-repository_id | 27193779 |
| octolytics-dimension-repository_nwo | nodejs/node |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 27193779 |
| octolytics-dimension-repository_network_root_nwo | nodejs/node |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | d0da0eb92994395299ed4450bf67b0373005be36 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width