jest-util
30.5.1 · 1 Sep 2026MIT156.2M / weekRepositoryHomepagenpmAtom feed
21.2.1 is the newest release of 21.x.
In short
1 deprecated25 new41 fixed109 changed1 internal
- deprecated
jest-haste-map: Deprecate functional ignorePattern and use it in cache key
Release note
Add --changedFilesWithAncestor
Add --findRelatedFiles
Add --onlyChanged tests
Add
contextLinesoption to jest-diffAdd alternative serialize API for pretty-format plugins
Add displayName to MPR
Add displayName to TestResult
Add es5 build of pretty-format
Add extra info to no tests for changed files message
Add fake chalk in browser builds in order to support IE10
Add jest.requireActual
Add maxWorkers to globalConfig
Add skipped tests support for jest-editor-support
Add source map support for better debugging experience
Add support for Error objects in toMatchObject
Add support for Immutable.Record in pretty-format
Add tests for extract_requires on export types
Add that toMatchObject can match arrays
Add watchPathIgnorePatterns to exclude paths to trigger test re-run in watch mode
Adding ancestorTitles property to JSON test output
Allow custom resolver to be used with[out] moduleNameMapper
Avoid parsing
.require(…)method callsAvoid unnecessary function declarations and call in pretty-format
Avoid writing to stdout in default reporter if --json is enabled. Fixes #3941
Better error handling for --config
Call consistent pretty-format plugins within Jest
Change babel-core to peerDependency for compatibility with Babel 7
Change Promise detection code in jest-circus to support non-global Promise implementations
Changed files eager loading
Check whether we should output to stdout or stderr
Clarify what objects toContain and toContainEqual can be used on
Clean up resolve() logic. Provide useful names for variables and functions. Test that a directory exists before attempting to resolve files within it.
cleanupStackTrace
Compare objects with Symbol keys
Complain if expect is passed multiple arguments
Completes nodeCrawl with empty roots
Consistent naming of files
Convert code base to ESM import
Correct summary message for flag --findRelatedTests.
Coverage thresholds can be set up for individual files
Custom reporter error handling
Define separate type for pretty-format plugin Options
Delete confusing async keyword
Delete redundant branch in ReactElement and HTMLElement plugins
Don't format node assert errors when there's no 'assert' module
Don't print test summary in --silent
Don't try to build ghost packages
Escape double quotes in attribute values in HTMLElement plugin
Explain how to clear the cache
Factor out common code for collections in pretty-format
Factor out common code for markup in React plugins
Feature/internal resolve
Fix --logHeapUsage
Fix --showConfig to show all project configs
Fix --watchAll
Fix bug when setTimeout is mocked
Fix changedFilesWithAncestor
Fix colors for expected/stored snapshot message
Fix concurrent test failure
Fix for 4286: Compare Maps and Sets by value rather than order
Fix forceExit
Fix grammar in React Native docs
Fix inconsistent name of complex values in pretty-format
Fix issue mocking bound method
Fix jest-circus
Fix lint warning in master
Fix linting
Fix merge conflict
Fix missing console.log messages
Fix mock return value
Fix mocking for modules with folders on windows
Fix NODE_PATH resolving for relative paths
Fix options.moduleNameMapper override order with preset (#3565
Fix React PropTypes warning in tests for Immutable plugin
Fix regression in mockReturnValueOnce
Fix sample code of mock class constructors
Fix setup-test-framework-test
Fix typescript jest test crash
Fix watch mode
Fix Watchman on windows
babel: Handle ignored files in babel v7
babel: Support upcoming beta
Fixed object matcher
Fixes #3820 use extractExpectedAssertionsErrors in jasmine setup
Flow upgrade
Force message in matchers to always be a function
Format
describeand usetestinstead ofitaliasglobal_config.js for multi-project runner
Handle async errors
Hard-fail if hasteImpl is throwing an error during initialization.
Ignore import type for extract_requires
Ignore indentation of data structures in jest-diff
Implement 'jest.requireMock'
Improve Jest phabricator plugin
Improve Seq and remove newline from non-min empty in Immutable plugin
Improved the jest reporter with snapshot info per test.
Include fullName in formattedAssertion
Integrated with Yarn workspaces
Jest --all
jest-circus test failures
jest-circus Timeouts
jest-haste-map: Add test case for broken handling of ignore pattern
jest-haste-map: Add test+fix for broken platform module support
- deprecated
jest-haste-map: Deprecate functional ignorePattern and use it in cache key
jest-haste-map: Mock 'fs' with more idiomatic jest.mock()
jest-haste-map: Only file IO errors should be silently ignored
jest-haste-map: Throw when trying to get a duplicated module
jest-haste-map: Watchman crawler: normalize paths
jest-runtime: Atomic cache write, and check validity of data
Join lines with newline in jest-diff
Keep ARGV only in CLI files
Let transformers adjust cache key based on mapCoverage
Lift requires
Log stack when reporting errors in jest-runtime
Make --listTests return a new line separated list when not using --json
Make build script printing small-terminals-friendly
Make error messages more explicit for toBeCalledWith assertions
Make jest-matcher-utils use ESM exports
Make jest-runner a standalone package.
Make Jest’s Test Runner configurable.
Make listTests always print to console.log
Make providesModuleNodeModules ignore nested node_modules directories
Make sure function mocks match original arity
Make sure runAllTimers also clears all ticks
Make toBe matcher error message more helpful for objects and arrays
Make useRealTimers play well with timers: fake
Move getType from jest-matcher-utils to separate package
Multiroot jest-change-files
Output created snapshot when using --ci option
Point out you can use matchers in .toMatchObject
Prevent babelrc package import failure on relative current path
Print RDP details for windows builds
Provide better error checking for transformed content
Provide printText and printComment in markup.js for HTMLElement plugin
Provide regex visualization for testRegex
Refactor CLI
Refactor names and delimiters of complex values in pretty-format
Replace concat(Immutable) with Immutable as item of plugins array
Replace Jasmine with jest-circus
Replace match with test and omit redundant String conversion
Replace print with serialize in AsymmetricMatcher plugin
Replace print with serialize in ConvertAnsi plugin
Replace print with serialize in HTMLElement plugin
Replace print with serialize in Immutable plugins
Replace unchanging args with one config arg within pretty-format
Return UNDEFINED for undefined type in ReactElement plugin
Rewrite some read bumps in pretty-format
Run update method before installing JRE on Circle
Separated the snapshot summary creation from the printing to improve testability.
Set coverageDirectory during normalize phase
Setup custom reporters after default reporters
Setup for Circle 2
Simplify readme
Simplify snapshots definition
skipNodeResolution config option
Small fixes to toHaveProperty docs
Sort attributes by name in HTMLElement plugin
Specify watchPathIgnorePatterns will only be available in Jest 21+
Split TestRunner off of TestScheduler
Strict and explicit config resolution logic
Support maxDepth option in React plugins
Support SVG elements in HTMLElement plugin
Test empty Immutable collections with {min: false} option
Test to debug travis failure in master
testPathPattern message test
Throw Error When Using Nested It Specs
Throw when moduleNameMapper points to inexistent module
Unified 'no tests found' message for non-verbose MPR
Update migration guide with jest-codemods transformers
Use "inputSourceMap" for coverage re-mapping.
Use "verbose" no test found message when there is only one project
Use babel transform to inline all requires
Use eslint plugins to run prettier
Use iterableEquality in spy matchers
Use modern HTML5 <!DOCTYPE>
Wrap
Error.captureStackTracein a try