@vitest/mocker breaking changes
@vitest/mocker 5.1.0 (November 2, 2026) is its newest release with breaking changes, 6 of them. The first: Test run now fails when a browser tester cannot connect in @vitest/mocker 5.1.0. Every breaking API change we have recorded in @vitest/mocker on npm: 51 breaking changes in 19 versions. Below, its 19 versions with breaking changes, newest first, removals and renames first, each with its source.
Updated December 4, 2026
On this page
Latest version 5.1.2, released November 25, 2026. Source repository
Packages on npm run on Node.js. Node.js end of life dates.
- From 4.1.11 to 5.1.0: 23 breaking changes in 8 versions.
- From 4.0.0 to 5.1.0: 42 breaking changes in 18 versions.
@vitest/mocker 5.1.0 breaking changes
- Behavior changed
A run where a browser tester cannot connect now fails instead of passing silently. Check that testers can connect before relying on green runs. github.com - Default changed
The default port for browser mode is now 23315. If you depend on the previous default port, set the port explicitly. github.com - Default changed
The browser trace view now shows only failing tests by default. Turn it off in your configuration if you want traces for all tests. github.com - Signature changed
browser:ModuleMockerInterceptor.register
Was register: (module: MockedModule) => Promise<void>; now register: (module: MockedModule, importer: string) => Promise<void>. npmjs.com - Signature changed
node:createManualModuleSource
Was function createManualModuleSource(moduleUrl: string, exports: string[], globalAccessor?: string): string; now function createManualModuleSource(moduleUrl: string, exports: string[], globalAccessor?: string, method?: "getFactoryModule"... npmjs.com - Signature changed
node:findMockRedirect
Was function findMockRedirect(root: string, mockPath: string, external: string | null): string | null; now function findMockRedirect(root: string, mockPath: string, external: string | null, rawId?: string): string | null. npmjs.com
@vitest/mocker 5.0.4 breaking changes
- Behavior changed
maxWorkers
Browser instances now run as workers and Vitest opens fewer instances by default. Users with a custom maxWorkers setting may see different performance. github.com - Default changed
fsModuleCache
The fsModuleCache option is now enabled by default. Users who relied on it being off must set it explicitly. github.com
@vitest/mocker 5.0.0 breaking changes
- Signature changed
AutomockedModule.fromJSON
Was static fromJSON(data: AutomockedModuleSerialized): AutospiedModule; now static fromJSON(data: AutomockedModuleSerialized): AutomockedModule. npmjs.com
@vitest/mocker 5.0.0-rc.4 breaking changes
- Behavior changed
vitest list
vitest list now parses files statically by default, which changes its output for existing users. github.com
@vitest/mocker 5.0.0-rc.3 breaking changes
- Behavior changed
Coverage now uses the @vitest/istanbuljs packages, which may require updating installed coverage dependencies. github.com - Behavior changed
toMatchFileSnapshot
toMatchFileSnapshot now rejects when it uses the same snapshot file as toMatchSnapshot. github.com
@vitest/mocker 5.0.0-rc.1 breaking changes
- Behavior changed
Inline projects inherit the root config by default, so users with inline projects may see different settings applied. github.com - Behavior changed
Temporal can now be mocked without enabling fake timers, which changes behavior for code that relied on the previous requirement. github.com - Behavior changed
A test now fails when an asynchronous assertion is not awaited, so tests that previously passed may now fail. github.com - Behavior changed
Spy class mocks now keep prototype methods on instances, which changes behavior for code relying on the previous mock shape. github.com - Behavior changed
Inline projects now share one Vite server, changing how servers are created for projects. github.com - Behavior changed
Failure screenshots are now saved in attachmentsDir instead of the previous location. github.com - Behavior changed
Types for expect and matchers now have better promise support, which may change type-checking results for existing code. github.com - Behavior changed
Support for nested projects changes how project configs are handled for existing setups. github.com - Behavior changed
-t
The -t test name filter now uses > as the separator, so existing filter patterns may need updating. github.com
Older versions
13 older versions, each with its first changes. Sign up to see every change
Show 13 older versions
@vitest/mocker 5.0.0-beta.7 breaking changes
- Behavior changed
Config resolution is now separate from creating the server, which changes how the config and server are set up for users who relied on the old order. github.com
@vitest/mocker 5.0.0-beta.2 breaking changes
- Behavior changed
Deserializing an automock now produces an automock. Code that relied on the previous deserialized result may behave differently. github.com
@vitest/mocker 4.1.11 breaking changes
- Behavior changed
Redirect mocks only work for paths on the fs allowlist in this release. Code that redirects mocks to other paths may stop working and needs its paths added to the allowlist. github.com
@vitest/mocker 4.1.8 breaking changes
- Behavior changed
With allowWrite or allowExec set to false, the client cdp API is now disabled. Code that relied on it in that configuration must enable those options or stop using the cdp API. github.com
@vitest/mocker 4.1.1 breaking changes
- Removed
Vitest 4.1.1 no longer supports Vite 8 beta versions. Projects on a Vite 8 beta need to move to a supported Vite release. github.com
@vitest/mocker 4.1.0 breaking changes
- Behavior changed
hideSkippedTests
hideSkippedTests no longer hides test.todo entries, so todo tests now appear where they were previously hidden. github.com - Behavior changed
vi.mock
Manual and redirect mocks no longer load or transform the original module, which can change code that depended on that side effect. github.com
And 7 more in this version.
@vitest/mocker 4.1.0-beta.6 breaking changes
- Behavior changed
Manual and redirect mocks skip loading and transforming the original module now. github.com
@vitest/mocker 4.1.0-beta.5 breaking changes
- Behavior changed
Browser screenshot diffs are now produced by BlazeDiff, so diff output may differ from before. github.com
@vitest/mocker 4.1.0-beta.4 breaking changes
- Configuration changed
deepEqual
Setting deepEqual in the chai config is no longer allowed because it is not serializable. github.com
@vitest/mocker 4.0.16 breaking changes
- Behavior changed
Suite functions called inside a test body are now rejected instead of being accepted. Move suite definitions outside of tests. github.com
@vitest/mocker 4.0.14 breaking changes
- Removed
prepare
The runner hook prepare was removed. Code that calls or overrides prepare will no longer work. github.com - Renamed
collect
The runner hook collect was renamed to import. Code that calls or overrides collect must use import instead. github.com
@vitest/mocker 4.0.7 breaking changes
- Default changed
Test files are sorted by project by default, which changes the default order in which tests run. github.com
@vitest/mocker 4.0.0 breaking changes
- Removed
MockObjectOptions.spyOn
MockObjectOptions.spyOn was removed in @vitest/mocker 4.0.0 npmjs.com - Renamed
node:ServerIdResolution
Use ServerIdResolution instead. npmjs.com
And 7 more in this version.
Related packages
Check your code
These are the changes. To see which of them reach your code, scan a public repository, or have your coding agent call check_code with your manifest or lockfile over MCP. The API reads every change in every version. A fix pull request opens for the changes that reach a connected repository. Nothing merges or deploys.

Put your code on continuous maintenance.
Scan a public repository now, or give your agent one line.
See how out of date your code is.
Tell your agent what changed since it was trained.
claude mcp add --transport http since https://api.since.dev/mcpCodex, Cursor and any MCP client use https://api.since.dev/mcp.