Big update!Introducing GitHub Bot Commands. Learn more
Socket
Log inBook a demo

babel-preset-jest

Package Overview
Dependencies
2
Maintainers
6
Versions
179
Issues
File Explorer

Advanced tools

babel-preset-jest

> Babel preset for all Jest plugins. This preset is automatically included when using [babel-jest](https://github.com/facebook/jest/tree/main/packages/babel-jest).

    29.2.0latest

Version published
Maintainers
6
Weekly downloads
21,518,491
increased by6.17%

Weekly downloads

Changelog

Source

29.2.0

Features

  • [@jest/cli, jest-config] A seed for the test run will be randomly generated, or set by a CLI option (#13400)
  • [@jest/cli, jest-config] --show-seed will display the seed value in the report, and can be set via a CLI flag or through the config file (#13400)
  • [jest-config] Add readInitialConfig utility function (#13356)
  • [jest-core] Allow testResultsProcessor to be async (#13343)
  • [@jest/environment, jest-environment-node, jest-environment-jsdom, jest-runtime] Add getSeed() to the jest object (#13400)
  • [expect, @jest/expect-utils] Allow isA utility to take a type argument (#13355)
  • [expect] Expose AsyncExpectationResult and SyncExpectationResult types (#13411)

Fixes

  • [babel-plugin-jest-hoist] Ignore TSTypeQuery when checking for hoisted references (#13367)
  • [jest-core] Fix detectOpenHandles false positives for some special objects such as TLSWRAP (#13414)
  • [jest-mock] Fix mocking of getters and setters on classes (#13398)
  • [jest-reporters] Revert: Transform file paths into hyperlinks (#13399)
  • [@jest/types] Infer type of each table correctly when the table is a tuple or array (#13381)
  • [@jest/types] Rework typings to allow the *ReturnedWith matchers to be called with no argument (#13385)

Chore & Maintenance

  • [*] Update @babel/* deps, resulting in slightly different stack traces for each (#13422)

Performance

  • [jest-runner] Do not instrument v8 coverage data if coverage should not be collected (#13282)

Readme

Source

babel-preset-jest

Babel preset for all Jest plugins. This preset is automatically included when using babel-jest.

Install

$ npm install --save-dev babel-preset-jest

Usage

module.exports = { presets: ['jest'], };

Via CLI

$ babel script.js --presets jest

Via Node API

require('@babel/core').transform('code', { presets: ['jest'], });

FAQs

What is babel-preset-jest?

> Babel preset for all Jest plugins. This preset is automatically included when using [babel-jest](https://github.com/facebook/jest/tree/main/packages/babel-jest).

Is babel-preset-jest popular?

The npm package babel-preset-jest receives a total of 18,081,007 weekly downloads. As such, babel-preset-jest popularity was classified as popular.

Is babel-preset-jest well maintained?

We found that babel-preset-jest demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago.It has 6 open source maintainers collaborating on the project.

Last updated on 14 Oct 2022

Did you know?

Socket installs a Github app to automatically flag issues on every pull request and report the health of your dependencies. Find out what is inside your node modules and prevent malicious activity before you update the dependencies.

Install Socket
Socket

Product

Subscribe to our newsletter

Get open source security insights delivered straight into your inbox. Be the first to learn about new features and product updates.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc