Packages

@vitest/spy

5.0.5 · 15 Oct 2026MIT202.7M / weekRepositoryHomepagenpmAtom feed

Your version

2.1.4

28 Oct 2024Where it was published

2.1.9 is the newest release of 2.x.

In short

1 new1 faster16 fixed2 internal

Release note

Features

This patch release includes a non-breaking feature for the experimental Browser Mode that doesn't follow SemVer. If you want to avoid picking up releases like this, make sure to pin the Vitest version in your package.json. See npm's documentation about semver for more information.

  • browser: Allow custom HTML path, respect plugins transformIndexHtml

Bug Fixes

  • windows: Don't normalize drive case letter in root

  • browser: Fix default browser port

  • browser: Optimize expect-type

  • browser: Don't polyfill process.env

  • browser: Increment browser port automatically if there are several projects with browser.enabled

  • browser: Cleanup keyboard state

  • browser: Don't add v= queries to setup files imports

  • browser: User event cleanup on retry

  • browser: Ignore non mocked msw requests

  • browser: Initiate MSW in the same frame as tests

  • expect: Correct behavior of toThrowError with empty string parameter

  • mocker: Remove spy from peer dependencies

  • vitest: Print warnings form Vite plugins

  • vitest: Don't fail if the working directory starts with a lowercase drive letter

  • vitest: Silence import analysis warning

  • vitest,runner: Simplify test.extend type exports

Performance

  • Use hash to replace createHash