Skip to content

Bump jest from 29.7.0 to 30.0.0 #507

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Jun 13, 2025
Merged

Conversation

dependabot[bot]
Copy link
Contributor

@dependabot dependabot bot commented on behalf of github Jun 11, 2025

Bumps jest from 29.7.0 to 30.0.0.

Release notes

Sourced from jest's releases.

Jest 30

Today we are happy to announce the release of Jest 30. This release features a substantial number of changes, fixes, and improvements. While it is one of the largest major releases of Jest ever, we admit that three years for a major release is too long. In the future, we are aiming to make more frequent major releases to keep Jest great for the next decade.

If you want to skip all the news and just get going, run npm install jest@^30.0.0 and follow the migration guide: Upgrading from Jest 29 to 30.

Read the full blog post

Features

  • [*] Renamed globalsCleanupMode to globalsCleanup and --waitNextEventLoopTurnForUnhandledRejectionEvents to --waitForUnhandledRejections
  • [expect] Add ArrayOf asymmetric matcher for validating array elements. (#15567)
  • [babel-jest] Add option excludeJestPreset to allow opting out of babel-preset-jest (#15164)
  • [expect] Revert #15038 to fix expect(fn).toHaveBeenCalledWith(expect.objectContaining(...)) when there are multiple calls (#15508)
  • [jest-circus, jest-cli, jest-config] Add waitNextEventLoopTurnForUnhandledRejectionEvents flag to minimise performance impact of correct detection of unhandled promise rejections introduced in #14315 (#14681)
  • [jest-circus] Add a waitBeforeRetry option to jest.retryTimes (#14738)
  • [jest-circus] Add a retryImmediately option to jest.retryTimes (#14696)
  • [jest-circus, jest-jasmine2] Allow setupFilesAfterEnv to export an async function (#10962)
  • [jest-circus, jest-test-result] Add startedAt timestamp in TestCaseResultObject within onTestCaseResult (#15145)
  • [jest-cli] Export buildArgv (#15310)
  • [jest-config] [BREAKING] Add mts and cts to default moduleFileExtensions config (#14369)
  • [jest-config] [BREAKING] Update testMatch and testRegex default option for supporting mjs, cjs, mts, and cts (#14584)
  • [jest-config] Loads config file from provided path in package.json (#14044)
  • [jest-config] Allow loading jest.config.cts files (#14070)
  • [jest-config] Show rootDir in error message when a preset fails to load (#15194)
  • [jest-config] Support loading TS config files using esbuild-register via docblock loader (#15190)
  • [jest-config] Allow passing TS config loader options via docblock comment (#15234)
  • [jest-config] If Node is running with type stripping enabled, do not require a TS loader (#15480)
  • [@jest/core] Group together open handles with the same stack trace (#13417, & #14789)
  • [@jest/core] Add perfStats to surface test setup overhead (#14622)
  • [@jest/core] [BREAKING] Changed --filter to accept an object with shape { filtered: Array<string> } to match documentation (#13319)
  • [@jest/core] Support --outputFile option for --listTests (#14980)
  • [@jest/core] Stringify Errors properly with --json flag (#15329)
  • [@jest/core, @jest/test-sequencer] [BREAKING] Exposes globalConfig & contexts to TestSequencer (#14535, & #14543)
  • [jest-each] Introduce %$ option to add number of the test to its title (#14710)
  • [@jest/environment] [BREAKING] Remove deprecated jest.genMockFromModule() (#15042)
  • [@jest/environment] [BREAKING] Remove unnecessary defensive code (#15045)
  • [jest-environment-jsdom] [BREAKING] Upgrade JSDOM to v22 (#13825)
  • [@jest/environment-jsdom-abstract] Introduce new package which abstracts over the jsdom environment, allowing usage of custom versions of JSDOM (#14717)
  • [jest-environment-node] Update jest environment with dispose symbols Symbol (#14888 & #14909)
  • [expect, @jest/expect] [BREAKING] Add type inference for function parameters in CalledWith assertions (#15129)
  • [@jest/expect-utils] Properly compare all types of TypedArrays (#15178)
  • [@jest/fake-timers] [BREAKING] Upgrade @sinonjs/fake-timers to v13 (#14544 & #15470)
  • [@jest/fake-timers] Exposing new modern timers function advanceTimersToFrame() which advances all timers by the needed milliseconds to execute callbacks currently scheduled with requestAnimationFrame (#14598)
  • [jest-matcher-utils] Add SERIALIZABLE_PROPERTIES to allow custom serialization of objects (#14893)
  • [jest-mock] Add support for the Explicit Resource Management proposal to use the using keyword with jest.spyOn(object, methodName) (#14895)
  • [jest-reporters] Add support for DEC mode 2026 (#15008)
  • [jest-resolver] Support file:// URLs as paths (#15154)
  • [jest-resolve,jest-runtime,jest-resolve-dependencies] Pass the conditions when resolving stub modules (#15489)
  • [jest-runtime] Exposing new modern timers function jest.advanceTimersToFrame() from @jest/fake-timers (#14598)
  • [jest-runtime] Support import.meta.filename and import.meta.dirname (available from Node 20.11) (#14854)

... (truncated)

Changelog

Sourced from jest's changelog.

30.0.0

Features

  • [*] Renamed globalsCleanupMode to globalsCleanup and --waitNextEventLoopTurnForUnhandledRejectionEvents to --waitForUnhandledRejections
  • [expect] Add ArrayOf asymmetric matcher for validating array elements. (#15567)
  • [babel-jest] Add option excludeJestPreset to allow opting out of babel-preset-jest (#15164)
  • [expect] Revert #15038 to fix expect(fn).toHaveBeenCalledWith(expect.objectContaining(...)) when there are multiple calls (#15508)
  • [jest-circus, jest-cli, jest-config] Add waitNextEventLoopTurnForUnhandledRejectionEvents flag to minimise performance impact of correct detection of unhandled promise rejections introduced in #14315 (#14681)
  • [jest-circus] Add a waitBeforeRetry option to jest.retryTimes (#14738)
  • [jest-circus] Add a retryImmediately option to jest.retryTimes (#14696)
  • [jest-circus, jest-jasmine2] Allow setupFilesAfterEnv to export an async function (#10962)
  • [jest-circus, jest-test-result] Add startedAt timestamp in TestCaseResultObject within onTestCaseResult (#15145)
  • [jest-cli] Export buildArgv (#15310)
  • [jest-config] [BREAKING] Add mts and cts to default moduleFileExtensions config (#14369)
  • [jest-config] [BREAKING] Update testMatch and testRegex default option for supporting mjs, cjs, mts, and cts (#14584)
  • [jest-config] Loads config file from provided path in package.json (#14044)
  • [jest-config] Allow loading jest.config.cts files (#14070)
  • [jest-config] Show rootDir in error message when a preset fails to load (#15194)
  • [jest-config] Support loading TS config files using esbuild-register via docblock loader (#15190)
  • [jest-config] Allow passing TS config loader options via docblock comment (#15234)
  • [jest-config] If Node is running with type stripping enabled, do not require a TS loader (#15480)
  • [@jest/core] Group together open handles with the same stack trace (#13417, & #14789)
  • [@jest/core] Add perfStats to surface test setup overhead (#14622)
  • [@jest/core] [BREAKING] Changed --filter to accept an object with shape { filtered: Array<string> } to match documentation (#13319)
  • [@jest/core] Support --outputFile option for --listTests (#14980)
  • [@jest/core] Stringify Errors properly with --json flag (#15329)
  • [@jest/core, @jest/test-sequencer] [BREAKING] Exposes globalConfig & contexts to TestSequencer (#14535, & #14543)
  • [jest-each] Introduce %$ option to add number of the test to its title (#14710)
  • [@jest/environment] [BREAKING] Remove deprecated jest.genMockFromModule() (#15042)
  • [@jest/environment] [BREAKING] Remove unnecessary defensive code (#15045)
  • [jest-environment-jsdom] [BREAKING] Upgrade JSDOM to v22 (#13825)
  • [@jest/environment-jsdom-abstract] Introduce new package which abstracts over the jsdom environment, allowing usage of custom versions of JSDOM (#14717)
  • [jest-environment-node] Update jest environment with dispose symbols Symbol (#14888 & #14909)
  • [expect, @jest/expect] [BREAKING] Add type inference for function parameters in CalledWith assertions (#15129)
  • [@jest/expect-utils] Properly compare all types of TypedArrays (#15178)
  • [@jest/fake-timers] [BREAKING] Upgrade @sinonjs/fake-timers to v13 (#14544 & #15470)
  • [@jest/fake-timers] Exposing new modern timers function advanceTimersToFrame() which advances all timers by the needed milliseconds to execute callbacks currently scheduled with requestAnimationFrame (#14598)
  • [jest-matcher-utils] Add SERIALIZABLE_PROPERTIES to allow custom serialization of objects (#14893)
  • [jest-mock] Add support for the Explicit Resource Management proposal to use the using keyword with jest.spyOn(object, methodName) (#14895)
  • [jest-reporters] Add support for DEC mode 2026 (#15008)
  • [jest-resolver] Support file:// URLs as paths (#15154)
  • [jest-resolve,jest-runtime,jest-resolve-dependencies] Pass the conditions when resolving stub modules (#15489)
  • [jest-runtime] Exposing new modern timers function jest.advanceTimersToFrame() from @jest/fake-timers (#14598)
  • [jest-runtime] Support import.meta.filename and import.meta.dirname (available from Node 20.11) (#14854)
  • [jest-runtime] Support import.meta.resolve (#14930)
  • [jest-runtime] [BREAKING] Make it mandatory to pass globalConfig to the Runtime constructor (#15044)
  • [jest-runtime] Add unstable_unmockModule (#15080)
  • [jest-runtime] Add onGenerateMock transformer callback for auto generated callbacks (#15433 & #15482)
  • [jest-runtime] [BREAKING] Use vm.compileFunction over vm.Script (#15461)

... (truncated)

Commits

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 merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @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 [jest](https://github.com/jestjs/jest/tree/HEAD/packages/jest) from 29.7.0 to 30.0.0.
- [Release notes](https://github.com/jestjs/jest/releases)
- [Changelog](https://github.com/jestjs/jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/jestjs/jest/commits/v30.0.0/packages/jest)

---
updated-dependencies:
- dependency-name: jest
  dependency-version: 30.0.0
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot dependabot bot added the topic: infrastructure Related to project infrastructure label Jun 11, 2025
@per1234 per1234 added the type: enhancement Proposed improvement label Jun 11, 2025
Copy link
Contributor

@per1234 per1234 left a comment

Choose a reason for hiding this comment

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

This is blocked because the ts-jest package has a peer dependency on jest@^29.0.0:

https://github.com/kulshekhar/ts-jest/blob/v29.3.4/package.json#L70

So this must wait until compatibility with jest@30.x is added to ts-jest, and a new release of ts-jest is made.

@per1234 per1234 added the status: blocked Progress on this prevented by an external cause label Jun 11, 2025
Bumps [ts-jest](https://github.com/kulshekhar/ts-jest) from 29.3.4 to 29.4.0.
- [Release notes](https://github.com/kulshekhar/ts-jest/releases)
- [Changelog](https://github.com/kulshekhar/ts-jest/blob/main/CHANGELOG.md)
- [Commits](kulshekhar/ts-jest@v29.3.4...v29.4.0)

---
updated-dependencies:
- dependency-name: ts-jest
  dependency-version: 29.4.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
@codecov-commenter
Copy link

codecov-commenter commented Jun 13, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 57.14%. Comparing base (d7c51a2) to head (f9d4316).
Report is 2 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #507      +/-   ##
==========================================
- Coverage   59.18%   57.14%   -2.05%     
==========================================
  Files           1        1              
  Lines          98       98              
  Branches       16       16              
==========================================
- Hits           58       56       -2     
+ Misses         33       29       -4     
- Partials        7       13       +6     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@per1234 per1234 removed the status: blocked Progress on this prevented by an external cause label Jun 13, 2025
@per1234 per1234 force-pushed the dependabot/npm_and_yarn/jest-30.0.0 branch from 2a4a5cc to 6258da5 Compare June 13, 2025 02:38
Bumps [jest-circus](https://github.com/jestjs/jest/tree/HEAD/packages/jest-circus) from 29.7.0 to 30.0.0.
- [Release notes](https://github.com/jestjs/jest/releases)
- [Changelog](https://github.com/jestjs/jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/jestjs/jest/commits/v30.0.0/packages/jest-circus)

---
updated-dependencies:
- dependency-name: jest-circus
  dependency-version: 30.0.0
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
@per1234 per1234 force-pushed the dependabot/npm_and_yarn/jest-30.0.0 branch from 6258da5 to f9d4316 Compare June 13, 2025 02:48
@per1234 per1234 merged commit f09f104 into main Jun 13, 2025
47 checks passed
@per1234 per1234 deleted the dependabot/npm_and_yarn/jest-30.0.0 branch June 13, 2025 03:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
topic: infrastructure Related to project infrastructure type: enhancement Proposed improvement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants