Dev Resources
Jest favicon

Jest

Testing

๐Ÿƒ Delightful JavaScript Testing.

Jest's website screenshot

About Jest

Jest is a JavaScript testing framework focused on simplicity, working with projects using Babel, TypeScript, Node, React, Angular, Vue, and others. It aims to work out of the box with zero configuration on most JavaScript projects, and includes snapshot testing for tracking large objects, either alongside tests or embedded inline.

Tests run in isolated, parallelized processes to maximize performance, with previously failed tests run first and runs reorganized based on file execution time. The framework includes a mocking system with a custom resolver for imports and a Mock Functions API for spying on function calls, code coverage collection via a --coverage flag with no additional setup, and detailed context provided on test failures.

Jest is maintained by the Jest Core Team and the OpenJS Foundation, with development supported through Open Collective donations. It reports over 100 million downloads in the past month and use on more than 15 million public GitHub repositories.

Key features

  • Zero-config setup that works out of the box on most JavaScript projects
  • Snapshot testing to track large objects, stored alongside tests or inline
  • Parallelized, isolated test execution across separate processes
  • Built-in code coverage via the --coverage flag with no extra setup
  • Easy mocking of imports with a rich Mock Functions API for spying on calls
  • Rich failure context and detailed exception output when tests fail

Frequently asked questions

What kind of projects does Jest work with?

Jest works with projects using Babel, TypeScript, Node, React, Angular, Vue and more.

Do I need to configure Jest before using it?

No, Jest aims to work out of the box with zero configuration on most JavaScript projects.

How do I get code coverage with Jest?

You add the --coverage flag and Jest collects code coverage information from the entire project, including untested files, with no additional setup.

How widely is Jest used?

Jest has over 100 million downloads in the last month and is used on more than 15,000,000 public repos on GitHub.

Does Jest support mocking?

Yes, Jest uses a custom resolver for imports so you can easily mock objects outside a test's scope, paired with a rich Mock Functions API.

Advertise here

Featured products

  • SerpApi - Search API favicon
  • CoreClaw favicon

Show your product to thousands of developers

ยท 100k monthly pageviews
ยท 7k newsletter subscribers

Advertise your product

You might also like