Skip to content

Bump vitest from 4.0.18 to 4.1.1#18

Open
dependabot[bot] wants to merge 1 commit intomainfrom
dependabot/npm_and_yarn/vitest-4.1.1
Open

Bump vitest from 4.0.18 to 4.1.1#18
dependabot[bot] wants to merge 1 commit intomainfrom
dependabot/npm_and_yarn/vitest-4.1.1

Conversation

@dependabot
Copy link
Copy Markdown
Contributor

@dependabot dependabot Bot commented on behalf of github Apr 1, 2026

Bumps vitest from 4.0.18 to 4.1.1.

Release notes

Sourced from vitest's releases.

v4.1.1

   🚀 Features

   🐞 Bug Fixes

    View changes on GitHub

v4.1.0

Vitest 4.1 is out!

This release page lists all changes made to the project during the 4.1 beta. To get a review of all the new features, read our blog post.

   🚀 Features

... (truncated)

Commits
  • 1f2d318 chore: release v4.1.1
  • ebfde79 refactor: rename matchesTagsFilter to matchesTags (#9956)
  • 5611500 feat(experimental): introduce experimental.vcsProvider (#9928)
  • eec53d9 feat(experimental): expose matchesTagsFilter to test if the current filter ...
  • bf89208 fix(coverage): load built-in provider without module runner (#9939)
  • 5a60868 refactor: fix typos (#9950)
  • aaf9f18 fix(coverage): simplify provider types (#9931)
  • 6fdb2ba fix: guard disposable and optional body (#9912)
  • e78adcf fix: open browser in --standalone mode without running tests (#9911)
  • ae5ec03 fix: properly re-evaluate actual modules of mocked external (#9898)
  • Additional commits viewable in compare view

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

Bumps [vitest](https://github.com/vitest-dev/vitest/tree/HEAD/packages/vitest) from 4.0.18 to 4.1.1.
- [Release notes](https://github.com/vitest-dev/vitest/releases)
- [Commits](https://github.com/vitest-dev/vitest/commits/v4.1.1/packages/vitest)

---
updated-dependencies:
- dependency-name: vitest
  dependency-version: 4.1.1
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot dependabot Bot added dependencies Pull requests that update a dependency file javascript Pull requests that update javascript code labels Apr 1, 2026
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Apr 1, 2026

QA Instructions

QA Testing Instructions for PR: Bump vitest from 4.0.18 to 4.1.1


Summary

This PR upgrades the vitest dependency from version 4.0.18 to 4.1.1. The new version includes multiple feature enhancements, bug fixes, and breaking changes, such as the deprecation of vite 8.beta support, updated APIs, and fixes for existing functionality. The aim of this PR is to take advantage of the improvements in the latest version to maintain compatibility and ensure optimized testing workflows.


Test Environment Setup

  1. Pull this branch and run npm install or yarn to ensure the updated dependency (vitest@4.1.1) and its additional dependencies are installed.
  2. Make sure the test suite runs in a development environment. This includes:
    • Node.js version compatible with the application.
    • Any custom vitest configurations in the vite.config.ts, vitest.config.ts, or equivalent files.
    • Access to any mocked modules or environment variables used in testing.

Test Scenarios

1. Run Existing Tests
  • Steps:
    1. Execute the test suite using vitest (e.g., npm run test or yarn test).
  • Expected Results:
    • All tests should pass as before.
    • There should be no unexpected errors or deprecations in the test output.
    • Verify that coverage reports are properly generated in HTML format.
2. Test for new vitest@4.1.1 changes
  • Steps:
    • Create a custom test using the new doMock() feature to validate its behavior.
      import { doMock } from 'vitest';
      test('example test', () => {
        const disposable = doMock('./module-to-mock');
        expect(disposable.dispose).toBeInstanceOf(Function);
      });
      
  • Expected Results:
    • doMock() should return a disposable object that can dispose of the mock properly.
3. Validate Tags Matching (Experimental)
  • Steps:
    1. Create new tests in your test directory and tag them with custom tags using the .tags property, e.g.,
      test('tagged test', { tags: ['myTag'] }, () => {
        expect(true).toBe(true);
      });
    2. Use vitest --tag myTag to filter on the custom myTag.
    3. Use vitest --tag nonExistentTag to filter an invalid tag.
  • Expected Results:
    • Tests tagged with myTag should run successfully.
    • Tests with nonExistentTag should not execute.
4. Backward Compatibility with Existing Mocks & Timers
  • Steps:
    1. Ensure existing tests that rely on vi.mock() or timer controls still work as expected.
    2. Validate new vi.advanceTimers is accessible and behaves as documented.
  • Expected Results:
    • Mocking behavior remains consistent.
    • Timer-related tests (e.g., vi.advanceTimers) accurately handle timer manipulation.

Regression Risks

  1. Deprecated vite 8.beta support: Ensure compatibility with the current vite version used in the project.
  2. Changes to vi.mocked() or its helpers: Validate against any tests/mock usage within the codebase to ensure APIs haven’t broken.
  3. Coverage generation: Verify that test coverage metrics are preserved and that coverage reports continue to function properly.

Things to Watch For

  1. The experimental.vcsProvider and some tagging-related functionality are labeled as experimental. Confirm that enabling these features does not introduce unexpected non-backward-compatible changes.
  2. Edge cases involving rejected/soft promises in vi.expect now use improved behavior. Review tests that validate promises with .resolves or .rejects for breaking changes.
  3. Runtime dependency updates in the package-lock.json (e.g., @emnapi/core) should not affect runtime behavior outside vitest. Check if other application components are affected.

Perform these tests and confirm vitest and the overall project behave as expected post-upgrade. Update or fix any broken tests before merging this PR.


Generated by QA Instructions Action

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file javascript Pull requests that update javascript code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants