FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

fix(reporters): `--merge-reports` to show each total run times by AriPerkkio · Pull Request #7877 · vitest-dev/vitest · GitHub

fix(reporters): --merge-reports to show each total run times - #7877

Merged
sheremet-va merged 1 commit into
vitest-dev:mainfrom
AriPerkkio:fix/merge-reports-execution-times
May 5, 2025
Merged

sheremet-va merged 1 commit into
vitest-dev:mainfrom
AriPerkkio:fix/merge-reports-execution-times

Conversation

AriPerkkio commented Apr 23, 2025 •
edited
Loading

Copy link
Copy Markdown
Member

Description

Adds total test run times of each blob in test report of --merge-reports run. The Duration is sum of all blobs. Below it we show Per blob durations.

Please don't delete this checklist! Before submitting the PR, please make sure you do the following:

  • It's really useful if your PR references an issue where it is discussed ahead of time. If the feature is substantial or introduces breaking changes without a discussion, PR might be closed.
  • Ideally, include a test that fails without this PR but passes with it.
  • Please, don't make changes to pnpm-lock.yaml unless you introduce a new test example.

Tests

  • Run the tests with pnpm test:ci.

Documentation

  • If you introduce new functionality, document it. You can run documentation with pnpm run docs command.

Changesets

  • Changes in changelog are generated from PR name. Please, make sure that it explains your changes in an understandable manner. Please, prefix changeset messages with feat:, fix:, perf:, docs:, or chore:.

AriPerkkio force-pushed the fix/merge-reports-execution-times branch 3 times, most recently from 6ba3c89 to b996dbf Compare April 24, 2025 12:22

netlify Bot commented Apr 24, 2025 •
edited
Loading

Copy link
Copy Markdown

✅ Deploy Preview for vitest-dev ready!

Built without sensitive environment variables

Name Link
🔨 Latest commit c2044d7
🔍 Latest deploy log https://app.netlify.com/sites/vitest-dev/deploys/681780b3124da8000826fe5f
😎 Deploy Preview https://deploy-preview-7877--vitest-dev.netlify.app
📱 Preview on mobile Toggle QR Code...



Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

AriPerkkio force-pushed the fix/merge-reports-execution-times branch from b996dbf to 67ef233 Compare April 24, 2025 12:38
AriPerkkio marked this pull request as ready for review April 24, 2025 12:53
Comment thread packages/vitest/src/node/core.ts Outdated
AriPerkkio force-pushed the fix/merge-reports-execution-times branch 2 times, most recently from 4f540be to d02dca4 Compare April 29, 2025 06:14

sheremet-va left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Generally, I dislike executionTimes?: number[] as a public API.

What are these numbers? Why are the optional? Do we just keep adding new arguments to hooks? I think this needs to be standardized somehow

Maybe have something like a SubTestRun? Or ShardTestRun

Comment thread packages/vitest/src/node/test-run.ts Outdated

Copy link
Copy Markdown
Member Author

Do you have any suggestions what would be better way to pass data from blob reporter's readBlob to other reporters? Should we instead store it in ctx or ctx.state?

Copy link
Copy Markdown
Member

Do you have any suggestions what would be better way to pass data from blob reporter's readBlob to other reporters? Should we instead store it in ctx or ctx.state?

Storing it in ctx.state seems like an interesting idea actually 🤔 Something like ctx.state.blobs?

AriPerkkio force-pushed the fix/merge-reports-execution-times branch from d02dca4 to c2044d7 Compare May 4, 2025 14:58

AriPerkkio commented May 4, 2025 •
edited
Loading

Copy link
Copy Markdown
Member Author

Storing blobs in ctx.state.blobs now. Base reporter is accessing executionTimes from state instead of reporter hooks.

This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Total test duration is wrong in --merge-reports

2 participants


Back | FazBrowse Home | New Git URL