From 7192a3ed97c7acd2125f53b188ba9be0a14fc5f3 Mon Sep 17 00:00:00 2001 From: Liam Doran Date: Tue, 16 Jun 2020 10:35:03 -0400 Subject: [PATCH 01/11] setSystemTime and getRealSystemTime type and doc update (#10169) --- CHANGELOG.md | 2 ++ docs/JestObjectAPI.md | 4 ++-- .../from-config/__tests__/test.js | 12 +++++++++++- .../from-jest-object/__tests__/test.js | 14 +++++++++++++- packages/jest-environment/src/index.ts | 2 +- packages/jest-fake-timers/src/modernFakeTimers.ts | 2 +- packages/jest-runtime/src/index.ts | 2 +- .../versioned_docs/version-26.0/JestObjectAPI.md | 4 ++-- 8 files changed, 33 insertions(+), 9 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 85c66a5d976f..9f7103b29bf0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -19,6 +19,8 @@ - `[jest-core]` 🎉🎉🎉🎉🎉🎉🎉🎉🎉🎉🎉🎉🎉🎉🎉🎉🎉🎉🎉🎉🎉🎉🎉🎉🎉 ([#10000](https://github.com/facebook/jest/pull/10000)) - `[jest-core, jest-reporters, jest-test-result, jest-types]` Cleanup `displayName` type ([#10049](https://github.com/facebook/jest/pull/10049)) - `[jest-runtime]` Jest-internal sandbox escape hatch ([#9907](https://github.com/facebook/jest/pull/9907)) +- `[jest-fake-timers]` Update `now` param type to support `Date` in addition to `number`. ([#10169](https://github.com/facebook/jest/pull/10169)) +- `[docs]` Add param to `setSystemTime` docs and remove preceding period from it and `getRealSystemTime` ([#10169](https://github.com/facebook/jest/pull/10169)) ### Performance diff --git a/docs/JestObjectAPI.md b/docs/JestObjectAPI.md index be28b93e4d21..d1205b6768d7 100644 --- a/docs/JestObjectAPI.md +++ b/docs/JestObjectAPI.md @@ -647,13 +647,13 @@ This means, if any timers have been scheduled (but have not yet executed), they Returns the number of fake timers still left to run. -### `.jest.setSystemTime()` +### `jest.setSystemTime(now?: number | Date)` Set the current system time used by fake timers. Simulates a user changing the system clock while your program is running. It affects the current time but it does not in itself cause e.g. timers to fire; they will fire exactly as they would have done without the call to `jest.setSystemTime()`. > Note: This function is only available when using modern fake timers implementation -### `.jest.getRealSystemTime()` +### `jest.getRealSystemTime()` When mocking time, `Date.now()` will also be mocked. If you for some reason need access to the real current time, you can invoke this function. diff --git a/e2e/modern-fake-timers/from-config/__tests__/test.js b/e2e/modern-fake-timers/from-config/__tests__/test.js index a32e5a5bc8e4..9974cab6c89b 100644 --- a/e2e/modern-fake-timers/from-config/__tests__/test.js +++ b/e2e/modern-fake-timers/from-config/__tests__/test.js @@ -7,7 +7,7 @@ 'use strict'; -test('fake timers', () => { +test('fake timers with number argument', () => { jest.setSystemTime(0); expect(Date.now()).toBe(0); @@ -16,3 +16,13 @@ test('fake timers', () => { expect(Date.now()).toBe(1000); }); + +test('fake timers with Date argument', () => { + jest.setSystemTime(new Date(0)); + + expect(Date.now()).toBe(0); + + jest.setSystemTime(new Date(1000)); + + expect(Date.now()).toBe(1000); +}); diff --git a/e2e/modern-fake-timers/from-jest-object/__tests__/test.js b/e2e/modern-fake-timers/from-jest-object/__tests__/test.js index acf8f56889cd..6fd28535c2bd 100644 --- a/e2e/modern-fake-timers/from-jest-object/__tests__/test.js +++ b/e2e/modern-fake-timers/from-jest-object/__tests__/test.js @@ -7,7 +7,7 @@ 'use strict'; -test('fake timers', () => { +test('fake timers with number argument', () => { jest.useFakeTimers('modern'); jest.setSystemTime(0); @@ -18,3 +18,15 @@ test('fake timers', () => { expect(Date.now()).toBe(1000); }); + +test('fake timers with Date argument', () => { + jest.useFakeTimers('modern'); + + jest.setSystemTime(new Date(0)); + + expect(Date.now()).toBe(0); + + jest.setSystemTime(new Date(1000)); + + expect(Date.now()).toBe(1000); +}); diff --git a/packages/jest-environment/src/index.ts b/packages/jest-environment/src/index.ts index 21970ecd1543..547afb313373 100644 --- a/packages/jest-environment/src/index.ts +++ b/packages/jest-environment/src/index.ts @@ -306,5 +306,5 @@ export interface Jest { * * > Note: This function is only available when using Lolex as fake timers implementation */ - setSystemTime(now?: number): void; + setSystemTime(now?: number | Date): void; } diff --git a/packages/jest-fake-timers/src/modernFakeTimers.ts b/packages/jest-fake-timers/src/modernFakeTimers.ts index 03ca30807a89..aba11f4387c6 100644 --- a/packages/jest-fake-timers/src/modernFakeTimers.ts +++ b/packages/jest-fake-timers/src/modernFakeTimers.ts @@ -118,7 +118,7 @@ export default class FakeTimers { } } - setSystemTime(now?: number): void { + setSystemTime(now?: number | Date): void { if (this._checkFakeTimers()) { this._clock.setSystemTime(now); } diff --git a/packages/jest-runtime/src/index.ts b/packages/jest-runtime/src/index.ts index 2cfe0a14d10a..3c63587d2bcd 100644 --- a/packages/jest-runtime/src/index.ts +++ b/packages/jest-runtime/src/index.ts @@ -1559,7 +1559,7 @@ class Runtime { _getFakeTimers().advanceTimersByTime(msToRun), setMock: (moduleName: string, mock: unknown) => setMockFactory(moduleName, () => mock), - setSystemTime: (now?: number) => { + setSystemTime: (now?: number | Date) => { const fakeTimers = _getFakeTimers(); if (fakeTimers instanceof ModernFakeTimers) { diff --git a/website/versioned_docs/version-26.0/JestObjectAPI.md b/website/versioned_docs/version-26.0/JestObjectAPI.md index eb6c6ebac297..ce3d6f314153 100644 --- a/website/versioned_docs/version-26.0/JestObjectAPI.md +++ b/website/versioned_docs/version-26.0/JestObjectAPI.md @@ -648,13 +648,13 @@ This means, if any timers have been scheduled (but have not yet executed), they Returns the number of fake timers still left to run. -### `.jest.setSystemTime()` +### `jest.setSystemTime(now?: number | Date)` Set the current system time used by fake timers. Simulates a user changing the system clock while your program is running. It affects the current time but it does not in itself cause e.g. timers to fire; they will fire exactly as they would have done without the call to `jest.setSystemTime()`. > Note: This function is only available when using modern fake timers implementation -### `.jest.getRealSystemTime()` +### `jest.getRealSystemTime()` When mocking time, `Date.now()` will also be mocked. If you for some reason need access to the real current time, you can invoke this function. From 852819abc0de900f6d8ebb417e7d4fc3d7e647aa Mon Sep 17 00:00:00 2001 From: Arie Shapiro <37379037+ArieShapiro@users.noreply.github.com> Date: Tue, 16 Jun 2020 16:52:28 +0200 Subject: [PATCH 02/11] Update UsingMatchers.md (#10161) Co-authored-by: ran shapiro --- docs/UsingMatchers.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/UsingMatchers.md b/docs/UsingMatchers.md index ef52762c91fa..eb00e44e82d5 100644 --- a/docs/UsingMatchers.md +++ b/docs/UsingMatchers.md @@ -138,7 +138,7 @@ test('the shopping list has beer on it', () => { ## Exceptions -If you want to test that a particular function throws an error when it's called, use `toThrow`. +If you want to test whether a particular function throws an error when it's called, use `toThrow`. ```js function compileAndroidCode() { From 15576d3d37a14050f302f213c655520590bafeee Mon Sep 17 00:00:00 2001 From: Nick McCurdy Date: Sat, 20 Jun 2020 05:57:46 -0400 Subject: [PATCH 03/11] Update links to Reactiflux (#10180) --- .github/ISSUE_TEMPLATE/question.md | 4 ++-- .github/SUPPORT.md | 2 +- CONTRIBUTING.md | 2 +- docs/MoreResources.md | 2 +- ...7-05-06-jest-20-delightful-testing-multi-project-runner.md | 2 +- .../2018-05-29-jest-23-blazing-fast-delightful-testing.md | 2 +- website/core/Footer.js | 2 +- website/pages/en/help.js | 4 ++-- website/versioned_docs/version-22.x/MoreResources.md | 2 +- website/versioned_docs/version-23.x/MoreResources.md | 2 +- 10 files changed, 12 insertions(+), 12 deletions(-) diff --git a/.github/ISSUE_TEMPLATE/question.md b/.github/ISSUE_TEMPLATE/question.md index a4942dc28381..68a0c85dc134 100644 --- a/.github/ISSUE_TEMPLATE/question.md +++ b/.github/ISSUE_TEMPLATE/question.md @@ -1,7 +1,7 @@ --- name: 💬 Questions / Help label: ':speech_balloon: Question' -about: If you have questions, please check our Discord or StackOverflow +about: If you have questions, please check Reactiflux or StackOverflow --- @@ -13,5 +13,5 @@ about: If you have questions, please check our Discord or StackOverflow For questions or help please see: - [The Jest help page](https://jestjs.io/en/help.html) -- [Our discord channel in Reactiflux](https://discord.gg/MWRhKCj) +- [Our `#testing` channel in Reactiflux](https://www.reactiflux.com/) - The [jestjs](https://stackoverflow.com/questions/tagged/jestjs) tag on [StackOverflow](https://stackoverflow.com/questions/ask) diff --git a/.github/SUPPORT.md b/.github/SUPPORT.md index 7d8247a9eea3..d8e4fff68f23 100644 --- a/.github/SUPPORT.md +++ b/.github/SUPPORT.md @@ -1,3 +1,3 @@ -Please note this issue tracker is not a help forum. We recommend using [StackOverflow](https://stackoverflow.com/questions/tagged/jest) or our [discord channel](https://discord.gg/MWRhKCj) for questions. +Please note this issue tracker is not a help forum. We recommend using [StackOverflow](https://stackoverflow.com/questions/tagged/jest) or [Reactiflux](https://www.reactiflux.com/) for questions. diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index a8a81a5899de..87361d6ea05b 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -211,7 +211,7 @@ Facebook has a [bounty program](https://www.facebook.com/whitehat/) for the safe ## How to Get in Touch -- Discord - [#jest](https://discord.gg/MWRhKCj) on [Reactiflux](http://www.reactiflux.com/) +`#testing` on [Reactiflux](https://www.reactiflux.com/) ## Code Conventions diff --git a/docs/MoreResources.md b/docs/MoreResources.md index 966a09be7ad9..c9d0968eeae3 100644 --- a/docs/MoreResources.md +++ b/docs/MoreResources.md @@ -19,6 +19,6 @@ You will find a number of example test cases in the [`examples`](https://github. ## Join the community -Ask questions and find answers from other Jest users like you. [Reactiflux](http://www.reactiflux.com/) is a Discord chat where a lot of Jest discussion happens. Check out the [#jest](https://discord.gg/MWRhKCj) channel. +Ask questions and find answers from other Jest users like you. [Reactiflux](https://www.reactiflux.com/) is a Discord chat where a lot of Jest discussion happens. Check out the `#testing` channel. Follow the [Jest Twitter account](https://twitter.com/fbjest) and [blog](/blog/) to find out what's happening in the world of Jest. diff --git a/website/blog/2017-05-06-jest-20-delightful-testing-multi-project-runner.md b/website/blog/2017-05-06-jest-20-delightful-testing-multi-project-runner.md index 515cd405871f..834d1ad7e6a6 100644 --- a/website/blog/2017-05-06-jest-20-delightful-testing-multi-project-runner.md +++ b/website/blog/2017-05-06-jest-20-delightful-testing-multi-project-runner.md @@ -87,4 +87,4 @@ Recently the Jest core team and other contributors started to talk more about Je - Rogelio Guzman did a talk about [Jest Snapshots and Beyond](https://www.youtube.com/watch?time_continue=416&v=HAuXJVI_bUs) at React Conf. - I spoke about [Building High-Quality JavaScript Tools](https://developers.facebook.com/videos/f8-2017/building-high-quality-javascript-tools/) at Facebook's F8 conference. -_As always, this release couldn't have been possible without you, the JavaScript community. We are incredibly grateful that we get the opportunity to work on improving JavaScript testing together. If you'd like to contribute to Jest, please don't hesitate to reach out to us on [GitHub](https://github.com/facebook/jest) or on [Discord](https://discord.gg/MWRhKCj)._ +_As always, this release couldn't have been possible without you, the JavaScript community. We are incredibly grateful that we get the opportunity to work on improving JavaScript testing together. If you'd like to contribute to Jest, please don't hesitate to reach out to us on [GitHub](https://github.com/facebook/jest) or on [Discord](https://www.reactiflux.com/)._ diff --git a/website/blog/2018-05-29-jest-23-blazing-fast-delightful-testing.md b/website/blog/2018-05-29-jest-23-blazing-fast-delightful-testing.md index dfdccca2f7b6..26f19bc7a0af 100644 --- a/website/blog/2018-05-29-jest-23-blazing-fast-delightful-testing.md +++ b/website/blog/2018-05-29-jest-23-blazing-fast-delightful-testing.md @@ -130,4 +130,4 @@ Full talk is available [here](https://www.youtube.com/watch?v=cAKYQpTC7MA). The turnout was amazing, and we were able to meet a lot of the London-based community in person. Thank you to everyone who joined us and for your continued support! Stay tuned for our next post which will outline the Jest Open Collective and the plans we have for the future. -_As always, this release couldn't have been possible without you, the JavaScript community. We are incredibly grateful that we get the opportunity to work on improving JavaScript testing together. If you'd like to contribute to Jest, please don't hesitate to reach out to us on_ _[GitHub](https://github.com/facebook/jest) or on_ _[Discord](https://discord.gg/MWRhKCj)._ +_As always, this release couldn't have been possible without you, the JavaScript community. We are incredibly grateful that we get the opportunity to work on improving JavaScript testing together. If you'd like to contribute to Jest, please don't hesitate to reach out to us on_ _[GitHub](https://github.com/facebook/jest) or on_ _[Discord](https://www.reactiflux.com/)._ diff --git a/website/core/Footer.js b/website/core/Footer.js index 223518caa51b..eefb8b12ba52 100644 --- a/website/core/Footer.js +++ b/website/core/Footer.js @@ -62,7 +62,7 @@ class Footer extends React.Component { > Stack Overflow - Jest Chat + Reactiflux Twitter diff --git a/website/pages/en/help.js b/website/pages/en/help.js index 12b1cf2a5187..735837e574aa 100755 --- a/website/pages/en/help.js +++ b/website/pages/en/help.js @@ -33,8 +33,8 @@ class Help extends React.Component { content: ( Ask questions and find answers from other Jest users like you.\n\n- - Join the [#jest](https://discord.gg/MWRhKCj) channel on - [Reactiflux](http://www.reactiflux.com/), a Discord community.\n- + Join the `#testing` channel on + [Reactiflux](https://www.reactiflux.com/), a Discord community.\n- Many members of the community use Stack Overflow. Read through the [existing questions](https://stackoverflow.com/questions/tagged/jestjs) tagged diff --git a/website/versioned_docs/version-22.x/MoreResources.md b/website/versioned_docs/version-22.x/MoreResources.md index 1dcf93605673..d864c92edecd 100644 --- a/website/versioned_docs/version-22.x/MoreResources.md +++ b/website/versioned_docs/version-22.x/MoreResources.md @@ -20,6 +20,6 @@ You will find a number of example test cases in the [`examples`](https://github. ## Join the community -Ask questions and find answers from other Jest users like you. [Reactiflux](http://www.reactiflux.com/) is a Discord chat where a lot of Jest discussion happens. Check out the [#jest](https://discordapp.com/channels/102860784329052160/103622435865104384) channel. +Ask questions and find answers from other Jest users like you. [Reactiflux](https://www.reactiflux.com/) is a Discord chat where a lot of Jest discussion happens. Check out the `#testing` channel. Follow the [Jest Twitter account](https://twitter.com/fbjest) and [blog](/blog/) to find out what's happening in the world of Jest. diff --git a/website/versioned_docs/version-23.x/MoreResources.md b/website/versioned_docs/version-23.x/MoreResources.md index b23c48c8f529..3dc5d4c0dcc9 100644 --- a/website/versioned_docs/version-23.x/MoreResources.md +++ b/website/versioned_docs/version-23.x/MoreResources.md @@ -20,6 +20,6 @@ You will find a number of example test cases in the [`examples`](https://github. ## Join the community -Ask questions and find answers from other Jest users like you. [Reactiflux](http://www.reactiflux.com/) is a Discord chat where a lot of Jest discussion happens. Check out the [#jest](https://discord.gg/MWRhKCj) channel. +Ask questions and find answers from other Jest users like you. [Reactiflux](https://www.reactiflux.com/) is a Discord chat where a lot of Jest discussion happens. Check out the `#testing` channel. Follow the [Jest Twitter account](https://twitter.com/fbjest) and [blog](/blog/) to find out what's happening in the world of Jest. From 4471bbbb2d009a5d71c7beb702cb3cadb46d0a94 Mon Sep 17 00:00:00 2001 From: Leo Date: Sat, 20 Jun 2020 18:58:24 +0900 Subject: [PATCH 04/11] Update GlobalAPI.md (#10157) --- docs/GlobalAPI.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/GlobalAPI.md b/docs/GlobalAPI.md index 2673a6fffd19..c321d53f956b 100644 --- a/docs/GlobalAPI.md +++ b/docs/GlobalAPI.md @@ -3,7 +3,7 @@ id: api title: Globals --- -In your test files, Jest puts each of these methods and objects into the global environment. You don't have to require or import anything to use them. However, if you prefer explicit imports, you can do `import {describe, expect, it} from '@jest/globals'`. +In your test files, Jest puts each of these methods and objects into the global environment. You don't have to require or import anything to use them. However, if you prefer explicit imports, you can do `import {describe, expect, test} from '@jest/globals'`. ## Methods From 504cacee18b844a974e76e5c45b2568bf023d3ac Mon Sep 17 00:00:00 2001 From: Joe Lencioni Date: Tue, 23 Jun 2020 06:10:12 -0500 Subject: [PATCH 05/11] Improve Jest startup time and test runtime, particularly when running with coverage, by caching micromatch and avoiding recreating RegExp instances (#10131) Co-authored-by: Christoph Nakazawa --- CHANGELOG.md | 2 + packages/jest-core/src/SearchSource.ts | 19 ++-- .../src/__tests__/SearchSource.test.ts | 28 ++++++ packages/jest-haste-map/src/HasteFS.ts | 7 +- .../jest-transform/src/shouldInstrument.ts | 31 ++++-- packages/jest-util/package.json | 4 +- .../src/__tests__/globsToMatcher.test.ts | 72 ++++++++++++++ packages/jest-util/src/globsToMatcher.ts | 99 +++++++++++++++++++ packages/jest-util/src/index.ts | 1 + 9 files changed, 244 insertions(+), 19 deletions(-) create mode 100644 packages/jest-util/src/__tests__/globsToMatcher.test.ts create mode 100644 packages/jest-util/src/globsToMatcher.ts diff --git a/CHANGELOG.md b/CHANGELOG.md index 9f7103b29bf0..bb662811e451 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -24,6 +24,8 @@ ### Performance +- `[jest-core, jest-transform, jest-haste-map]` Improve Jest startup time and test runtime, particularly when running with coverage, by caching micromatch and avoiding recreating RegExp instances ([#10131](https://github.com/facebook/jest/pull/10131)) + ## 26.0.1 ### Fixes diff --git a/packages/jest-core/src/SearchSource.ts b/packages/jest-core/src/SearchSource.ts index 48c630f2adb4..333d8539f314 100644 --- a/packages/jest-core/src/SearchSource.ts +++ b/packages/jest-core/src/SearchSource.ts @@ -16,7 +16,7 @@ import DependencyResolver = require('jest-resolve-dependencies'); import {escapePathForRegex} from 'jest-regex-util'; import {replaceRootDirInPath} from 'jest-config'; import {buildSnapshotResolver} from 'jest-snapshot'; -import {replacePathSepForGlob, testPathPatternToRegExp} from 'jest-util'; +import {globsToMatcher, testPathPatternToRegExp} from 'jest-util'; import type {Filter, Stats, TestPathCases} from './types'; export type SearchResult = { @@ -37,12 +37,19 @@ export type TestSelectionConfig = { watch?: boolean; }; -const globsToMatcher = (globs: Array) => (path: Config.Path) => - micromatch([replacePathSepForGlob(path)], globs, {dot: true}).length > 0; +const regexToMatcher = (testRegex: Config.ProjectConfig['testRegex']) => { + const regexes = testRegex.map(testRegex => new RegExp(testRegex)); -const regexToMatcher = (testRegex: Config.ProjectConfig['testRegex']) => ( - path: Config.Path, -) => testRegex.some(testRegex => new RegExp(testRegex).test(path)); + return (path: Config.Path) => + regexes.some(regex => { + const result = regex.test(path); + + // prevent stateful regexes from breaking, just in case + regex.lastIndex = 0; + + return result; + }); +}; const toTests = (context: Context, tests: Array) => tests.map(path => ({ diff --git a/packages/jest-core/src/__tests__/SearchSource.test.ts b/packages/jest-core/src/__tests__/SearchSource.test.ts index fbc4513ef1f6..5bb1deedc263 100644 --- a/packages/jest-core/src/__tests__/SearchSource.test.ts +++ b/packages/jest-core/src/__tests__/SearchSource.test.ts @@ -206,6 +206,34 @@ describe('SearchSource', () => { }); }); + it('finds tests matching a JS with overriding glob patterns', () => { + const {options: config} = normalize( + { + moduleFileExtensions: ['js', 'jsx'], + name, + rootDir, + testMatch: [ + '**/*.js?(x)', + '!**/test.js?(x)', + '**/test.js', + '!**/test.js', + ], + testRegex: '', + }, + {} as Config.Argv, + ); + + return findMatchingTests(config).then(data => { + const relPaths = toPaths(data.tests).map(absPath => + path.relative(rootDir, absPath), + ); + expect(relPaths.sort()).toEqual([ + path.normalize('module.jsx'), + path.normalize('no_tests.js'), + ]); + }); + }); + it('finds tests with default file extensions using testRegex', () => { const {options: config} = normalize( { diff --git a/packages/jest-haste-map/src/HasteFS.ts b/packages/jest-haste-map/src/HasteFS.ts index 358eee2e3676..bdad6f292a82 100644 --- a/packages/jest-haste-map/src/HasteFS.ts +++ b/packages/jest-haste-map/src/HasteFS.ts @@ -5,8 +5,7 @@ * LICENSE file in the root directory of this source tree. */ -import micromatch = require('micromatch'); -import {replacePathSepForGlob} from 'jest-util'; +import {globsToMatcher, replacePathSepForGlob} from 'jest-util'; import type {Config} from '@jest/types'; import type {FileData} from './types'; import * as fastPath from './lib/fast_path'; @@ -84,9 +83,11 @@ export default class HasteFS { root: Config.Path | null, ): Set { const files = new Set(); + const matcher = globsToMatcher(globs); + for (const file of this.getAbsoluteFileIterator()) { const filePath = root ? fastPath.relative(root, file) : file; - if (micromatch([replacePathSepForGlob(filePath)], globs).length > 0) { + if (matcher(replacePathSepForGlob(filePath))) { files.add(file); } } diff --git a/packages/jest-transform/src/shouldInstrument.ts b/packages/jest-transform/src/shouldInstrument.ts index d9fcdcd268c3..8b729ace3afb 100644 --- a/packages/jest-transform/src/shouldInstrument.ts +++ b/packages/jest-transform/src/shouldInstrument.ts @@ -8,7 +8,7 @@ import * as path from 'path'; import type {Config} from '@jest/types'; import {escapePathForRegex} from 'jest-regex-util'; -import {replacePathSepForGlob} from 'jest-util'; +import {globsToMatcher, replacePathSepForGlob} from 'jest-util'; import micromatch = require('micromatch'); import type {ShouldInstrumentOptions} from './types'; @@ -16,6 +16,20 @@ const MOCKS_PATTERN = new RegExp( escapePathForRegex(path.sep + '__mocks__' + path.sep), ); +const cachedRegexes = new Map(); +const getRegex = (regexStr: string) => { + if (!cachedRegexes.has(regexStr)) { + cachedRegexes.set(regexStr, new RegExp(regexStr)); + } + + const regex = cachedRegexes.get(regexStr)!; + + // prevent stateful regexes from breaking, just in case + regex.lastIndex = 0; + + return regex; +}; + export default function shouldInstrument( filename: Config.Path, options: ShouldInstrumentOptions, @@ -33,15 +47,15 @@ export default function shouldInstrument( } if ( - !config.testPathIgnorePatterns.some(pattern => !!filename.match(pattern)) + !config.testPathIgnorePatterns.some(pattern => + getRegex(pattern).test(filename), + ) ) { if (config.testRegex.some(regex => new RegExp(regex).test(filename))) { return false; } - if ( - micromatch([replacePathSepForGlob(filename)], config.testMatch).length - ) { + if (globsToMatcher(config.testMatch)(replacePathSepForGlob(filename))) { return false; } } @@ -59,10 +73,9 @@ export default function shouldInstrument( // still cover if `only` is specified !options.collectCoverageOnlyFrom && options.collectCoverageFrom.length && - micromatch( - [replacePathSepForGlob(path.relative(config.rootDir, filename))], - options.collectCoverageFrom, - ).length === 0 + !globsToMatcher(options.collectCoverageFrom)( + replacePathSepForGlob(path.relative(config.rootDir, filename)), + ) ) { return false; } diff --git a/packages/jest-util/package.json b/packages/jest-util/package.json index 10cfaa9030df..dc891b89a98d 100644 --- a/packages/jest-util/package.json +++ b/packages/jest-util/package.json @@ -14,11 +14,13 @@ "chalk": "^4.0.0", "graceful-fs": "^4.2.4", "is-ci": "^2.0.0", - "make-dir": "^3.0.0" + "make-dir": "^3.0.0", + "micromatch": "^4.0.2" }, "devDependencies": { "@types/graceful-fs": "^4.1.2", "@types/is-ci": "^2.0.0", + "@types/micromatch": "^4.0.0", "@types/node": "*" }, "engines": { diff --git a/packages/jest-util/src/__tests__/globsToMatcher.test.ts b/packages/jest-util/src/__tests__/globsToMatcher.test.ts new file mode 100644 index 000000000000..f676d7ae0360 --- /dev/null +++ b/packages/jest-util/src/__tests__/globsToMatcher.test.ts @@ -0,0 +1,72 @@ +/** + * Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */ + +import micromatch = require('micromatch'); +import globsToMatcher from '../globsToMatcher'; + +it('works like micromatch with only positive globs', () => { + const globs = ['**/*.test.js', '**/*.test.jsx']; + const matcher = globsToMatcher(globs); + + expect(matcher('some-module.js')).toBe( + micromatch(['some-module.js'], globs).length > 0, + ); + + expect(matcher('some-module.test.js')).toBe( + micromatch(['some-module.test.js'], globs).length > 0, + ); +}); + +it('works like micromatch with a mix of overlapping positive and negative globs', () => { + const globs = ['**/*.js', '!**/*.test.js', '**/*.test.js']; + const matcher = globsToMatcher(globs); + + expect(matcher('some-module.js')).toBe( + micromatch(['some-module.js'], globs).length > 0, + ); + + expect(matcher('some-module.test.js')).toBe( + micromatch(['some-module.test.js'], globs).length > 0, + ); + + const globs2 = ['**/*.js', '!**/*.test.js', '**/*.test.js', '!**/*.test.js']; + const matcher2 = globsToMatcher(globs2); + + expect(matcher2('some-module.js')).toBe( + micromatch(['some-module.js'], globs2).length > 0, + ); + + expect(matcher2('some-module.test.js')).toBe( + micromatch(['some-module.test.js'], globs2).length > 0, + ); +}); + +it('works like micromatch with only negative globs', () => { + const globs = ['!**/*.test.js', '!**/*.test.jsx']; + const matcher = globsToMatcher(globs); + + expect(matcher('some-module.js')).toBe( + micromatch(['some-module.js'], globs).length > 0, + ); + + expect(matcher('some-module.test.js')).toBe( + micromatch(['some-module.test.js'], globs).length > 0, + ); +}); + +it('works like micromatch with empty globs', () => { + const globs = []; + const matcher = globsToMatcher(globs); + + expect(matcher('some-module.js')).toBe( + micromatch(['some-module.js'], globs).length > 0, + ); + + expect(matcher('some-module.test.js')).toBe( + micromatch(['some-module.test.js'], globs).length > 0, + ); +}); diff --git a/packages/jest-util/src/globsToMatcher.ts b/packages/jest-util/src/globsToMatcher.ts new file mode 100644 index 000000000000..e100d42cfcbf --- /dev/null +++ b/packages/jest-util/src/globsToMatcher.ts @@ -0,0 +1,99 @@ +/** + * Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */ + +import micromatch = require('micromatch'); +import type {Config} from '@jest/types'; +import replacePathSepForGlob from './replacePathSepForGlob'; + +const globsToMatchersMap = new Map< + string, + { + isMatch: (str: string) => boolean; + negated: boolean; + } +>(); + +const micromatchOptions = {dot: true}; + +/** + * Converts a list of globs into a function that matches a path against the + * globs. + * + * Every time micromatch is called, it will parse the glob strings and turn + * them into regexp instances. Instead of calling micromatch repeatedly with + * the same globs, we can use this function which will build the micromatch + * matchers ahead of time and then have an optimized path for determining + * whether an individual path matches. + * + * This function is intended to match the behavior of `micromatch()`. + * + * @example + * const isMatch = globsToMatcher(['*.js', '!*.test.js']); + * isMatch('pizza.js'); // true + * isMatch('pizza.test.js'); // false + */ +export default function globsToMatcher( + globs: Array, +): (path: Config.Path) => boolean { + if (globs.length === 0) { + // Since there were no globs given, we can simply have a fast path here and + // return with a very simple function. + return (_: Config.Path): boolean => false; + } + + const matchers = globs.map(glob => { + if (!globsToMatchersMap.has(glob)) { + // Matchers that are negated have different behavior than matchers that + // are not negated, so we need to store this information ahead of time. + const {negated} = micromatch.scan(glob, micromatchOptions); + + const matcher = { + isMatch: micromatch.matcher(glob, micromatchOptions), + negated, + }; + + globsToMatchersMap.set(glob, matcher); + } + + return globsToMatchersMap.get(glob)!; + }); + + return (path: Config.Path): boolean => { + const replacedPath = replacePathSepForGlob(path); + let kept = undefined; + let negatives = 0; + + for (let i = 0; i < matchers.length; i++) { + const {isMatch, negated} = matchers[i]; + + if (negated) { + negatives++; + } + + const matched = isMatch(replacedPath); + + if (!matched && negated) { + // The path was not matched, and the matcher is a negated matcher, so we + // want to omit the path. This means that the negative matcher is + // filtering the path out. + kept = false; + } else if (matched && !negated) { + // The path was matched, and the matcher is not a negated matcher, so we + // want to keep the path. + kept = true; + } + } + + // If all of the globs were negative globs, then we want to include the path + // as long as it was not explicitly not kept. Otherwise only include + // the path if it was kept. This allows sets of globs that are all negated + // to allow some paths to be matched, while sets of globs that are mixed + // negated and non-negated to cause the negated matchers to only omit paths + // and not keep them. + return negatives === matchers.length ? kept !== false : !!kept; + }; +} diff --git a/packages/jest-util/src/index.ts b/packages/jest-util/src/index.ts index cfd00f7fd55d..40d200b1930d 100644 --- a/packages/jest-util/src/index.ts +++ b/packages/jest-util/src/index.ts @@ -18,6 +18,7 @@ export {default as convertDescriptorToString} from './convertDescriptorToString' import * as specialChars from './specialChars'; export {default as replacePathSepForGlob} from './replacePathSepForGlob'; export {default as testPathPatternToRegExp} from './testPathPatternToRegExp'; +export {default as globsToMatcher} from './globsToMatcher'; import * as preRunMessage from './preRunMessage'; export {default as pluralize} from './pluralize'; export {default as formatTime} from './formatTime'; From 95b94e84cf60d919035d79112b18859909a8b831 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?An=C4=B1l=20Anar?= Date: Tue, 23 Jun 2020 16:24:29 +0200 Subject: [PATCH 06/11] feat(jest-mock): Export Mock, MockInstance, SpyInstance types (#10138) --- CHANGELOG.md | 1 + packages/jest-mock/src/index.ts | 108 +++++++++++++++++--------------- 2 files changed, 57 insertions(+), 52 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index bb662811e451..9baa9146f079 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,7 @@ ### Features +- `[jest-mock]` Export `Mock`, `MockInstance`, `SpyInstance` types ([#10138](https://github.com/facebook/jest/pull/10138)) - `[jest-config]` Support config files exporting (`async`) `function`s ([#10001](https://github.com/facebook/jest/pull/10001)) - `[jest-cli, jest-core]` Add `--selectProjects` CLI argument to filter test suites by project name ([#8612](https://github.com/facebook/jest/pull/8612)) - `[jest-cli, jest-init]` Add `coverageProvider` to `jest --init` prompts ([#10044](https://github.com/facebook/jest/pull/10044)) diff --git a/packages/jest-mock/src/index.ts b/packages/jest-mock/src/index.ts index 7251b0a9ec02..730fe5c63f1a 100644 --- a/packages/jest-mock/src/index.ts +++ b/packages/jest-mock/src/index.ts @@ -33,6 +33,39 @@ namespace JestMock { value?: T; length?: number; }; + + export interface Mock = Array> + extends Function, + MockInstance { + new (...args: Y): T; + (...args: Y): T; + } + + export interface SpyInstance> + extends MockInstance {} + + export interface MockInstance> { + _isMockFunction: true; + _protoImpl: Function; + getMockName(): string; + getMockImplementation(): Function | undefined; + mock: MockFunctionState; + mockClear(): this; + mockReset(): this; + mockRestore(): void; + mockImplementation(fn: (...args: Y) => T): this; + mockImplementation(fn: () => Promise): this; + mockImplementationOnce(fn: (...args: Y) => T): this; + mockImplementationOnce(fn: () => Promise): this; + mockName(name: string): this; + mockReturnThis(): this; + mockReturnValue(value: T): this; + mockReturnValueOnce(value: T): this; + mockResolvedValue(value: T): this; + mockResolvedValueOnce(value: T): this; + mockRejectedValue(value: T): this; + mockRejectedValueOnce(value: T): this; + } } /** @@ -87,38 +120,6 @@ type FunctionPropertyNames = { }[keyof T] & string; -interface Mock = Array> - extends Function, - MockInstance { - new (...args: Y): T; - (...args: Y): T; -} - -interface SpyInstance> extends MockInstance {} - -interface MockInstance> { - _isMockFunction: true; - _protoImpl: Function; - getMockName(): string; - getMockImplementation(): Function | undefined; - mock: MockFunctionState; - mockClear(): this; - mockReset(): this; - mockRestore(): void; - mockImplementation(fn: (...args: Y) => T): this; - mockImplementation(fn: () => Promise): this; - mockImplementationOnce(fn: (...args: Y) => T): this; - mockImplementationOnce(fn: () => Promise): this; - mockName(name: string): this; - mockReturnThis(): this; - mockReturnValue(value: T): this; - mockReturnValueOnce(value: T): this; - mockResolvedValue(value: T): this; - mockResolvedValueOnce(value: T): this; - mockRejectedValue(value: T): this; - mockRejectedValueOnce(value: T): this; -} - const MOCK_CONSTRUCTOR_NAME = 'mockConstructor'; const FUNCTION_NAME_RESERVED_PATTERN = /[\s!-\/:-@\[-`{-~]/; @@ -363,7 +364,10 @@ function isReadonlyProp(object: any, prop: string): boolean { class ModuleMockerClass { private _environmentGlobal: Global; - private _mockState: WeakMap, MockFunctionState>; + private _mockState: WeakMap< + JestMock.Mock, + MockFunctionState + >; private _mockConfigRegistry: WeakMap; private _spyState: Set<() => void>; private _invocationCallCounter: number; @@ -430,7 +434,7 @@ class ModuleMockerClass { } private _ensureMockConfig>( - f: Mock, + f: JestMock.Mock, ): MockFunctionConfig { let config = this._mockConfigRegistry.get(f); if (!config) { @@ -441,7 +445,7 @@ class ModuleMockerClass { } private _ensureMockState>( - f: Mock, + f: JestMock.Mock, ): MockFunctionState { let state = this._mockState.get(f); if (!state) { @@ -495,7 +499,7 @@ class ModuleMockerClass { private _makeComponent>( metadata: JestMock.MockFunctionMetadata, restore?: () => void, - ): Mock; + ): JestMock.Mock; private _makeComponent>( metadata: JestMock.MockFunctionMetadata, restore?: () => void, @@ -505,7 +509,7 @@ class ModuleMockerClass { | RegExp | T | undefined - | Mock { + | JestMock.Mock { if (metadata.type === 'object') { return new this._environmentGlobal.Object(); } else if (metadata.type === 'array') { @@ -617,7 +621,7 @@ class ModuleMockerClass { const f = (this._createMockFunction( metadata, mockConstructor, - ) as unknown) as Mock; + ) as unknown) as JestMock.Mock; f._isMockFunction = true; f.getMockImplementation = () => this._ensureMockConfig(f).mockImpl; @@ -673,7 +677,7 @@ class ModuleMockerClass { f.mockImplementationOnce = ( fn: ((...args: Y) => T) | (() => Promise), - ): Mock => { + ): JestMock.Mock => { // next function call will use this mock implementation return value // or default mock implementation return value const mockConfig = this._ensureMockConfig(f); @@ -683,7 +687,7 @@ class ModuleMockerClass { f.mockImplementation = ( fn: ((...args: Y) => T) | (() => Promise), - ): Mock => { + ): JestMock.Mock => { // next function call will use mock implementation return value const mockConfig = this._ensureMockConfig(f); mockConfig.mockImpl = fn; @@ -789,9 +793,9 @@ class ModuleMockerClass { | RegExp | T | undefined - | Mock; + | JestMock.Mock; }, - ): Mock { + ): JestMock.Mock { // metadata not compatible but it's the same type, maybe problem with // overloading of _makeComponent and not _generateMock? // @ts-expect-error @@ -822,7 +826,7 @@ class ModuleMockerClass { mock.prototype.constructor = mock; } - return mock as Mock; + return mock as JestMock.Mock; } /** @@ -832,7 +836,7 @@ class ModuleMockerClass { */ generateFromMetadata>( _metadata: JestMock.MockFunctionMetadata, - ): Mock { + ): JestMock.Mock { const callbacks: Array = []; const refs = {}; const mock = this._generateMock(_metadata, callbacks, refs); @@ -913,13 +917,13 @@ class ModuleMockerClass { return metadata; } - isMockFunction(fn: any): fn is Mock { + isMockFunction(fn: any): fn is JestMock.Mock { return !!fn && fn._isMockFunction === true; } fn>( implementation?: (...args: Y) => T, - ): Mock { + ): JestMock.Mock { const length = implementation ? implementation.length : 0; const fn = this._makeComponent({length, type: 'function'}); if (implementation) { @@ -932,19 +936,19 @@ class ModuleMockerClass { object: T, methodName: M, accessType: 'get', - ): SpyInstance; + ): JestMock.SpyInstance; spyOn>( object: T, methodName: M, accessType: 'set', - ): SpyInstance; + ): JestMock.SpyInstance; spyOn>( object: T, methodName: M, ): T[M] extends (...args: Array) => any - ? SpyInstance, Parameters> + ? JestMock.SpyInstance, Parameters> : never; spyOn>( @@ -999,7 +1003,7 @@ class ModuleMockerClass { obj: T, propertyName: M, accessType: 'get' | 'set' = 'get', - ): Mock { + ): JestMock.Mock { if (typeof obj !== 'object' && typeof obj !== 'function') { throw new Error( 'Cannot spyOn on a primitive value; ' + this._typeOf(obj) + ' given', @@ -1058,7 +1062,7 @@ class ModuleMockerClass { Object.defineProperty(obj, propertyName, descriptor!); }); - (descriptor[accessType] as Mock).mockImplementation(function ( + (descriptor[accessType] as JestMock.Mock).mockImplementation(function ( this: unknown, ) { // @ts-expect-error @@ -1067,7 +1071,7 @@ class ModuleMockerClass { } Object.defineProperty(obj, propertyName, descriptor); - return descriptor[accessType] as Mock; + return descriptor[accessType] as JestMock.Mock; } clearAllMocks() { From ee40194a6757e34d7974908b4c634423ea2023e6 Mon Sep 17 00:00:00 2001 From: David Marvasti Date: Tue, 23 Jun 2020 10:25:06 -0400 Subject: [PATCH 07/11] Update ExpectAPI.md (#10141) (Typo) Removed word "to" --- docs/ExpectAPI.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/ExpectAPI.md b/docs/ExpectAPI.md index af1721ebf32a..245ac248eba3 100644 --- a/docs/ExpectAPI.md +++ b/docs/ExpectAPI.md @@ -495,7 +495,7 @@ expect.addSnapshotSerializer(serializer); // affects expect(value).toMatchSnapshot() assertions in the test file ``` -If you add a snapshot serializer in individual test files instead of to adding it to `snapshotSerializers` configuration: +If you add a snapshot serializer in individual test files instead of adding it to `snapshotSerializers` configuration: - You make the dependency explicit instead of implicit. - You avoid limits to configuration that might cause you to eject from [create-react-app](https://github.com/facebookincubator/create-react-app). From 17c3f1405316cdcda6888015d29dba2950e990e0 Mon Sep 17 00:00:00 2001 From: Bogdan Chadkin Date: Tue, 23 Jun 2020 17:57:11 +0300 Subject: [PATCH 08/11] chore: replace `make-dir` with `fs.mkdir` (#10136) --- CHANGELOG.md | 1 + e2e/Utils.ts | 13 ++++++------- package.json | 1 - packages/jest-snapshot/package.json | 1 - packages/jest-snapshot/src/utils.ts | 3 +-- packages/jest-util/package.json | 1 - packages/jest-util/src/createDirectory.ts | 4 ++-- scripts/build.js | 3 +-- 8 files changed, 11 insertions(+), 16 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 9baa9146f079..45a58b02ca70 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -22,6 +22,7 @@ - `[jest-runtime]` Jest-internal sandbox escape hatch ([#9907](https://github.com/facebook/jest/pull/9907)) - `[jest-fake-timers]` Update `now` param type to support `Date` in addition to `number`. ([#10169](https://github.com/facebook/jest/pull/10169)) - `[docs]` Add param to `setSystemTime` docs and remove preceding period from it and `getRealSystemTime` ([#10169](https://github.com/facebook/jest/pull/10169)) +- `[jest-snapshot, jest-util]` Replace `make-dir` with `fs.mkdir` ([#10136](https://github.com/facebook/jest/pull/10136)) ### Performance diff --git a/e2e/Utils.ts b/e2e/Utils.ts index ef725bd99eb6..47e22bafced5 100644 --- a/e2e/Utils.ts +++ b/e2e/Utils.ts @@ -11,7 +11,6 @@ import type {Config} from '@jest/types'; // eslint-disable-next-line import/named import {ExecaReturnValue, sync as spawnSync} from 'execa'; -import makeDir = require('make-dir'); import rimraf = require('rimraf'); import dedent = require('dedent'); import which = require('which'); @@ -46,7 +45,7 @@ export const linkJestPackage = (packageName: string, cwd: Config.Path) => { const packagesDir = path.resolve(__dirname, '../packages'); const packagePath = path.resolve(packagesDir, packageName); const destination = path.resolve(cwd, 'node_modules/', packageName); - makeDir.sync(destination); + fs.mkdirSync(destination, {recursive: true}); rimraf.sync(destination); fs.symlinkSync(packagePath, destination, 'junction'); }; @@ -77,12 +76,12 @@ export const writeFiles = ( directory: string, files: {[filename: string]: string}, ) => { - makeDir.sync(directory); + fs.mkdirSync(directory, {recursive: true}); Object.keys(files).forEach(fileOrPath => { const dirname = path.dirname(fileOrPath); if (dirname !== '/') { - makeDir.sync(path.join(directory, dirname)); + fs.mkdirSync(path.join(directory, dirname), {recursive: true}); } fs.writeFileSync( path.resolve(directory, ...fileOrPath.split('/')), @@ -95,13 +94,13 @@ export const writeSymlinks = ( directory: string, symlinks: {[existingFile: string]: string}, ) => { - makeDir.sync(directory); + fs.mkdirSync(directory, {recursive: true}); Object.keys(symlinks).forEach(fileOrPath => { const symLinkPath = symlinks[fileOrPath]; const dirname = path.dirname(symLinkPath); if (dirname !== '/') { - makeDir.sync(path.join(directory, dirname)); + fs.mkdirSync(path.join(directory, dirname), {recursive: true}); } fs.symlinkSync( path.resolve(directory, ...fileOrPath.split('/')), @@ -165,7 +164,7 @@ export const createEmptyPackage = ( }, }; - makeDir.sync(directory); + fs.mkdirSync(directory, {recursive: true}); packageJson || (packageJson = DEFAULT_PACKAGE_JSON); fs.writeFileSync( path.resolve(directory, 'package.json'), diff --git a/package.json b/package.json index 45325c4d15af..9fa3e18caf5d 100644 --- a/package.json +++ b/package.json @@ -59,7 +59,6 @@ "jest-watch-typeahead": "^0.5.0", "jquery": "^3.2.1", "lerna": "^3.20.2", - "make-dir": "^3.0.0", "micromatch": "^4.0.2", "mock-fs": "^4.4.1", "opencollective": "^1.0.3", diff --git a/packages/jest-snapshot/package.json b/packages/jest-snapshot/package.json index 88b963e754ef..278988d20188 100644 --- a/packages/jest-snapshot/package.json +++ b/packages/jest-snapshot/package.json @@ -22,7 +22,6 @@ "jest-matcher-utils": "^26.0.1", "jest-message-util": "^26.0.1", "jest-resolve": "^26.0.1", - "make-dir": "^3.0.0", "natural-compare": "^1.4.0", "pretty-format": "^26.0.1", "semver": "^7.3.2" diff --git a/packages/jest-snapshot/src/utils.ts b/packages/jest-snapshot/src/utils.ts index d1ef478e7fbf..20a62e79aa3c 100644 --- a/packages/jest-snapshot/src/utils.ts +++ b/packages/jest-snapshot/src/utils.ts @@ -7,7 +7,6 @@ import * as path from 'path'; import * as fs from 'graceful-fs'; -import makeDir = require('make-dir'); import naturalCompare = require('natural-compare'); import chalk = require('chalk'); import type {Config} from '@jest/types'; @@ -183,7 +182,7 @@ const printBacktickString = (str: string): string => export const ensureDirectoryExists = (filePath: Config.Path): void => { try { - makeDir.sync(path.join(path.dirname(filePath))); + fs.mkdirSync(path.join(path.dirname(filePath)), {recursive: true}); } catch (e) {} }; diff --git a/packages/jest-util/package.json b/packages/jest-util/package.json index dc891b89a98d..24180e5a499b 100644 --- a/packages/jest-util/package.json +++ b/packages/jest-util/package.json @@ -14,7 +14,6 @@ "chalk": "^4.0.0", "graceful-fs": "^4.2.4", "is-ci": "^2.0.0", - "make-dir": "^3.0.0", "micromatch": "^4.0.2" }, "devDependencies": { diff --git a/packages/jest-util/src/createDirectory.ts b/packages/jest-util/src/createDirectory.ts index df298c5ef34b..d9320bb7fcfb 100644 --- a/packages/jest-util/src/createDirectory.ts +++ b/packages/jest-util/src/createDirectory.ts @@ -5,12 +5,12 @@ * LICENSE file in the root directory of this source tree. */ -import makeDir = require('make-dir'); +import * as fs from 'graceful-fs'; import type {Config} from '@jest/types'; export default function createDirectory(path: Config.Path): void { try { - makeDir.sync(path); + fs.mkdirSync(path, {recursive: true}); } catch (e) { if (e.code !== 'EEXIST') { throw e; diff --git a/scripts/build.js b/scripts/build.js index d6d718cbe322..aa5a3bf1953c 100644 --- a/scripts/build.js +++ b/scripts/build.js @@ -23,7 +23,6 @@ const fs = require('fs'); const path = require('path'); const glob = require('glob'); -const makeDir = require('make-dir'); const babel = require('@babel/core'); const chalk = require('chalk'); @@ -83,7 +82,7 @@ function buildFile(file, silent) { return; } - makeDir.sync(path.dirname(destPath)); + fs.mkdirSync(path.dirname(destPath), {recursive: true}); if ( !micromatch.isMatch(file, JS_FILES_PATTERN) && !micromatch.isMatch(file, TS_FILES_PATTERN) From a1fa77696513f048f58bf833895da76224955af2 Mon Sep 17 00:00:00 2001 From: Simen Bekkhus Date: Tue, 23 Jun 2020 16:58:55 +0200 Subject: [PATCH 09/11] chore: quote globs in scripts (#10190) --- package.json | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/package.json b/package.json index 9fa3e18caf5d..64bc5cc438d8 100644 --- a/package.json +++ b/package.json @@ -77,12 +77,12 @@ "which": "^2.0.1" }, "scripts": { - "build-clean": "rimraf ./packages/*/build ./packages/*/build-es5 ./packages/*/tsconfig.tsbuildinfo", - "prebuild": "yarn build:ts", - "build": "node ./scripts/build.js", + "build-clean": "rimraf './packages/*/build' './packages/*/build-es5' './packages/*/tsconfig.tsbuildinfo'", + "build": "yarn build:js && yarn build:ts", + "build:js": "node ./scripts/build.js", "build:ts": "node ./scripts/buildTs.js", "check-copyright-headers": "node ./scripts/checkCopyrightHeaders.js", - "clean-all": "yarn clean-e2e && yarn build-clean && rimraf ./packages/*/node_modules && rimraf ./node_modules", + "clean-all": "yarn clean-e2e && yarn build-clean && rimraf './packages/*/node_modules' && rimraf './node_modules'", "clean-e2e": "node ./scripts/cleanE2e.js", "jest": "node ./packages/jest-cli/bin/jest.js", "jest-coverage": "yarn jest --coverage", From 30658c6fc0df37a758293f0731729dc764110963 Mon Sep 17 00:00:00 2001 From: Simen Bekkhus Date: Tue, 23 Jun 2020 17:05:54 +0200 Subject: [PATCH 10/11] chore: update changelog for release --- CHANGELOG.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 45a58b02ca70..0528254517c8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,16 @@ ### Features +### Fixes + +### Chore & Maintenance + +### Performance + +## 26.1.0 + +### Features + - `[jest-mock]` Export `Mock`, `MockInstance`, `SpyInstance` types ([#10138](https://github.com/facebook/jest/pull/10138)) - `[jest-config]` Support config files exporting (`async`) `function`s ([#10001](https://github.com/facebook/jest/pull/10001)) - `[jest-cli, jest-core]` Add `--selectProjects` CLI argument to filter test suites by project name ([#8612](https://github.com/facebook/jest/pull/8612)) From 817d8b6aca845dd4fcfd7f8316293e69f3a116c5 Mon Sep 17 00:00:00 2001 From: Simen Bekkhus Date: Tue, 23 Jun 2020 17:14:55 +0200 Subject: [PATCH 11/11] v26.1.0 --- lerna.json | 2 +- packages/babel-jest/package.json | 8 ++-- packages/babel-plugin-jest-hoist/package.json | 2 +- packages/babel-preset-jest/package.json | 4 +- packages/expect/package.json | 8 ++-- packages/jest-changed-files/package.json | 4 +- packages/jest-circus/package.json | 24 ++++++------ packages/jest-cli/package.json | 14 +++---- packages/jest-config/package.json | 22 +++++------ packages/jest-console/package.json | 8 ++-- packages/jest-core/package.json | 38 +++++++++---------- packages/jest-diff/package.json | 4 +- packages/jest-each/package.json | 8 ++-- packages/jest-environment-jsdom/package.json | 12 +++--- packages/jest-environment-node/package.json | 12 +++--- packages/jest-environment/package.json | 8 ++-- packages/jest-fake-timers/package.json | 10 ++--- packages/jest-globals/package.json | 8 ++-- packages/jest-haste-map/package.json | 10 ++--- packages/jest-jasmine2/package.json | 26 ++++++------- packages/jest-leak-detector/package.json | 4 +- packages/jest-matcher-utils/package.json | 6 +-- packages/jest-message-util/package.json | 4 +- packages/jest-mock/package.json | 4 +- packages/jest-phabricator/package.json | 4 +- packages/jest-repl/package.json | 12 +++--- packages/jest-reporters/package.json | 18 ++++----- .../jest-resolve-dependencies/package.json | 12 +++--- packages/jest-resolve/package.json | 8 ++-- packages/jest-runner/package.json | 30 +++++++-------- packages/jest-runtime/package.json | 36 +++++++++--------- packages/jest-serializer/package.json | 2 +- packages/jest-snapshot/package.json | 18 ++++----- packages/jest-source-map/package.json | 2 +- packages/jest-test-result/package.json | 6 +-- packages/jest-test-sequencer/package.json | 10 ++--- packages/jest-transform/package.json | 8 ++-- packages/jest-types/package.json | 2 +- packages/jest-util/package.json | 4 +- packages/jest-validate/package.json | 6 +-- packages/jest-watcher/package.json | 8 ++-- packages/jest-worker/package.json | 2 +- packages/jest/package.json | 6 +-- packages/pretty-format/package.json | 4 +- 44 files changed, 224 insertions(+), 224 deletions(-) diff --git a/lerna.json b/lerna.json index ece5879dd999..43a4a78a86fc 100644 --- a/lerna.json +++ b/lerna.json @@ -1,5 +1,5 @@ { - "version": "26.0.1", + "version": "26.1.0", "npmClient": "yarn", "packages": [ "packages/*" diff --git a/packages/babel-jest/package.json b/packages/babel-jest/package.json index 744ff284a94f..41086e447267 100644 --- a/packages/babel-jest/package.json +++ b/packages/babel-jest/package.json @@ -1,7 +1,7 @@ { "name": "babel-jest", "description": "Jest plugin to use babel for transformation.", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -11,11 +11,11 @@ "main": "build/index.js", "types": "build/index.d.ts", "dependencies": { - "@jest/transform": "^26.0.1", - "@jest/types": "^26.0.1", + "@jest/transform": "^26.1.0", + "@jest/types": "^26.1.0", "@types/babel__core": "^7.1.7", "babel-plugin-istanbul": "^6.0.0", - "babel-preset-jest": "^26.0.0", + "babel-preset-jest": "^26.1.0", "chalk": "^4.0.0", "graceful-fs": "^4.2.4", "slash": "^3.0.0" diff --git a/packages/babel-plugin-jest-hoist/package.json b/packages/babel-plugin-jest-hoist/package.json index 117ba679498c..4613ddcafae9 100644 --- a/packages/babel-plugin-jest-hoist/package.json +++ b/packages/babel-plugin-jest-hoist/package.json @@ -1,6 +1,6 @@ { "name": "babel-plugin-jest-hoist", - "version": "26.0.0", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", diff --git a/packages/babel-preset-jest/package.json b/packages/babel-preset-jest/package.json index c0ab101f6d72..d67149257a01 100644 --- a/packages/babel-preset-jest/package.json +++ b/packages/babel-preset-jest/package.json @@ -1,6 +1,6 @@ { "name": "babel-preset-jest", - "version": "26.0.0", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -9,7 +9,7 @@ "license": "MIT", "main": "index.js", "dependencies": { - "babel-plugin-jest-hoist": "^26.0.0", + "babel-plugin-jest-hoist": "^26.1.0", "babel-preset-current-node-syntax": "^0.1.2" }, "peerDependencies": { diff --git a/packages/expect/package.json b/packages/expect/package.json index 3df291ab87ef..76ce311ebffd 100644 --- a/packages/expect/package.json +++ b/packages/expect/package.json @@ -1,6 +1,6 @@ { "name": "expect", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -10,11 +10,11 @@ "main": "build/index.js", "types": "build/index.d.ts", "dependencies": { - "@jest/types": "^26.0.1", + "@jest/types": "^26.1.0", "ansi-styles": "^4.0.0", "jest-get-type": "^26.0.0", - "jest-matcher-utils": "^26.0.1", - "jest-message-util": "^26.0.1", + "jest-matcher-utils": "^26.1.0", + "jest-message-util": "^26.1.0", "jest-regex-util": "^26.0.0" }, "devDependencies": { diff --git a/packages/jest-changed-files/package.json b/packages/jest-changed-files/package.json index 174c99939b02..d7c5b03be8a6 100644 --- a/packages/jest-changed-files/package.json +++ b/packages/jest-changed-files/package.json @@ -1,6 +1,6 @@ { "name": "jest-changed-files", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -10,7 +10,7 @@ "main": "build/index.js", "types": "build/index.d.ts", "dependencies": { - "@jest/types": "^26.0.1", + "@jest/types": "^26.1.0", "execa": "^4.0.0", "throat": "^5.0.0" }, diff --git a/packages/jest-circus/package.json b/packages/jest-circus/package.json index 36061ed5f9e4..a99bb128c5e1 100644 --- a/packages/jest-circus/package.json +++ b/packages/jest-circus/package.json @@ -1,6 +1,6 @@ { "name": "jest-circus", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -11,21 +11,21 @@ "types": "build/index.d.ts", "dependencies": { "@babel/traverse": "^7.1.0", - "@jest/environment": "^26.0.1", - "@jest/test-result": "^26.0.1", - "@jest/types": "^26.0.1", + "@jest/environment": "^26.1.0", + "@jest/test-result": "^26.1.0", + "@jest/types": "^26.1.0", "chalk": "^4.0.0", "co": "^4.6.0", "dedent": "^0.7.0", - "expect": "^26.0.1", + "expect": "^26.1.0", "is-generator-fn": "^2.0.0", - "jest-each": "^26.0.1", - "jest-matcher-utils": "^26.0.1", - "jest-message-util": "^26.0.1", - "jest-runtime": "^26.0.1", - "jest-snapshot": "^26.0.1", - "jest-util": "^26.0.1", - "pretty-format": "^26.0.1", + "jest-each": "^26.1.0", + "jest-matcher-utils": "^26.1.0", + "jest-message-util": "^26.1.0", + "jest-runtime": "^26.1.0", + "jest-snapshot": "^26.1.0", + "jest-util": "^26.1.0", + "pretty-format": "^26.1.0", "stack-utils": "^2.0.2", "throat": "^5.0.0" }, diff --git a/packages/jest-cli/package.json b/packages/jest-cli/package.json index e66d72814cab..0c1dafe6f094 100644 --- a/packages/jest-cli/package.json +++ b/packages/jest-cli/package.json @@ -1,21 +1,21 @@ { "name": "jest-cli", "description": "Delightful JavaScript Testing.", - "version": "26.0.1", + "version": "26.1.0", "main": "build/index.js", "types": "build/index.d.ts", "dependencies": { - "@jest/core": "^26.0.1", - "@jest/test-result": "^26.0.1", - "@jest/types": "^26.0.1", + "@jest/core": "^26.1.0", + "@jest/test-result": "^26.1.0", + "@jest/types": "^26.1.0", "chalk": "^4.0.0", "exit": "^0.1.2", "graceful-fs": "^4.2.4", "import-local": "^3.0.2", "is-ci": "^2.0.0", - "jest-config": "^26.0.1", - "jest-util": "^26.0.1", - "jest-validate": "^26.0.1", + "jest-config": "^26.1.0", + "jest-util": "^26.1.0", + "jest-validate": "^26.1.0", "prompts": "^2.0.1", "yargs": "^15.3.1" }, diff --git a/packages/jest-config/package.json b/packages/jest-config/package.json index 93bf49c11e86..221df2f5957b 100644 --- a/packages/jest-config/package.json +++ b/packages/jest-config/package.json @@ -1,6 +1,6 @@ { "name": "jest-config", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -11,23 +11,23 @@ "types": "build/index.d.ts", "dependencies": { "@babel/core": "^7.1.0", - "@jest/test-sequencer": "^26.0.1", - "@jest/types": "^26.0.1", - "babel-jest": "^26.0.1", + "@jest/test-sequencer": "^26.1.0", + "@jest/types": "^26.1.0", + "babel-jest": "^26.1.0", "chalk": "^4.0.0", "deepmerge": "^4.2.2", "glob": "^7.1.1", "graceful-fs": "^4.2.4", - "jest-environment-jsdom": "^26.0.1", - "jest-environment-node": "^26.0.1", + "jest-environment-jsdom": "^26.1.0", + "jest-environment-node": "^26.1.0", "jest-get-type": "^26.0.0", - "jest-jasmine2": "^26.0.1", + "jest-jasmine2": "^26.1.0", "jest-regex-util": "^26.0.0", - "jest-resolve": "^26.0.1", - "jest-util": "^26.0.1", - "jest-validate": "^26.0.1", + "jest-resolve": "^26.1.0", + "jest-util": "^26.1.0", + "jest-validate": "^26.1.0", "micromatch": "^4.0.2", - "pretty-format": "^26.0.1" + "pretty-format": "^26.1.0" }, "devDependencies": { "@types/babel__core": "^7.0.4", diff --git a/packages/jest-console/package.json b/packages/jest-console/package.json index 2b216fdeeb36..493ea4921278 100644 --- a/packages/jest-console/package.json +++ b/packages/jest-console/package.json @@ -1,6 +1,6 @@ { "name": "@jest/console", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -10,10 +10,10 @@ "main": "build/index.js", "types": "build/index.d.ts", "dependencies": { - "@jest/types": "^26.0.1", + "@jest/types": "^26.1.0", "chalk": "^4.0.0", - "jest-message-util": "^26.0.1", - "jest-util": "^26.0.1", + "jest-message-util": "^26.1.0", + "jest-util": "^26.1.0", "slash": "^3.0.0" }, "devDependencies": { diff --git a/packages/jest-core/package.json b/packages/jest-core/package.json index 1b0e15b4b1ac..2cf64377f5af 100644 --- a/packages/jest-core/package.json +++ b/packages/jest-core/package.json @@ -1,32 +1,32 @@ { "name": "@jest/core", "description": "Delightful JavaScript Testing.", - "version": "26.0.1", + "version": "26.1.0", "main": "build/jest.js", "types": "build/jest.d.ts", "dependencies": { - "@jest/console": "^26.0.1", - "@jest/reporters": "^26.0.1", - "@jest/test-result": "^26.0.1", - "@jest/transform": "^26.0.1", - "@jest/types": "^26.0.1", + "@jest/console": "^26.1.0", + "@jest/reporters": "^26.1.0", + "@jest/test-result": "^26.1.0", + "@jest/transform": "^26.1.0", + "@jest/types": "^26.1.0", "ansi-escapes": "^4.2.1", "chalk": "^4.0.0", "exit": "^0.1.2", "graceful-fs": "^4.2.4", - "jest-changed-files": "^26.0.1", - "jest-config": "^26.0.1", - "jest-haste-map": "^26.0.1", - "jest-message-util": "^26.0.1", + "jest-changed-files": "^26.1.0", + "jest-config": "^26.1.0", + "jest-haste-map": "^26.1.0", + "jest-message-util": "^26.1.0", "jest-regex-util": "^26.0.0", - "jest-resolve": "^26.0.1", - "jest-resolve-dependencies": "^26.0.1", - "jest-runner": "^26.0.1", - "jest-runtime": "^26.0.1", - "jest-snapshot": "^26.0.1", - "jest-util": "^26.0.1", - "jest-validate": "^26.0.1", - "jest-watcher": "^26.0.1", + "jest-resolve": "^26.1.0", + "jest-resolve-dependencies": "^26.1.0", + "jest-runner": "^26.1.0", + "jest-runtime": "^26.1.0", + "jest-snapshot": "^26.1.0", + "jest-util": "^26.1.0", + "jest-validate": "^26.1.0", + "jest-watcher": "^26.1.0", "micromatch": "^4.0.2", "p-each-series": "^2.1.0", "rimraf": "^3.0.0", @@ -34,7 +34,7 @@ "strip-ansi": "^6.0.0" }, "devDependencies": { - "@jest/test-sequencer": "^26.0.1", + "@jest/test-sequencer": "^26.1.0", "@types/exit": "^0.1.30", "@types/graceful-fs": "^4.1.2", "@types/micromatch": "^4.0.0", diff --git a/packages/jest-diff/package.json b/packages/jest-diff/package.json index 18a3323d020c..7b36bdf5fddb 100644 --- a/packages/jest-diff/package.json +++ b/packages/jest-diff/package.json @@ -1,6 +1,6 @@ { "name": "jest-diff", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -13,7 +13,7 @@ "chalk": "^4.0.0", "diff-sequences": "^26.0.0", "jest-get-type": "^26.0.0", - "pretty-format": "^26.0.1" + "pretty-format": "^26.1.0" }, "devDependencies": { "@jest/test-utils": "^26.0.0", diff --git a/packages/jest-each/package.json b/packages/jest-each/package.json index 2612d2da714d..6c1fd820846d 100644 --- a/packages/jest-each/package.json +++ b/packages/jest-each/package.json @@ -1,6 +1,6 @@ { "name": "jest-each", - "version": "26.0.1", + "version": "26.1.0", "description": "Parameterised tests for Jest", "main": "build/index.js", "types": "build/index.d.ts", @@ -18,11 +18,11 @@ "author": "Matt Phillips (mattphillips)", "license": "MIT", "dependencies": { - "@jest/types": "^26.0.1", + "@jest/types": "^26.1.0", "chalk": "^4.0.0", "jest-get-type": "^26.0.0", - "jest-util": "^26.0.1", - "pretty-format": "^26.0.1" + "jest-util": "^26.1.0", + "pretty-format": "^26.1.0" }, "engines": { "node": ">= 10.14.2" diff --git a/packages/jest-environment-jsdom/package.json b/packages/jest-environment-jsdom/package.json index bea48a8e67fe..e21bd19afec1 100644 --- a/packages/jest-environment-jsdom/package.json +++ b/packages/jest-environment-jsdom/package.json @@ -1,6 +1,6 @@ { "name": "jest-environment-jsdom", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -10,11 +10,11 @@ "main": "build/index.js", "types": "build/index.d.ts", "dependencies": { - "@jest/environment": "^26.0.1", - "@jest/fake-timers": "^26.0.1", - "@jest/types": "^26.0.1", - "jest-mock": "^26.0.1", - "jest-util": "^26.0.1", + "@jest/environment": "^26.1.0", + "@jest/fake-timers": "^26.1.0", + "@jest/types": "^26.1.0", + "jest-mock": "^26.1.0", + "jest-util": "^26.1.0", "jsdom": "^16.2.2" }, "devDependencies": { diff --git a/packages/jest-environment-node/package.json b/packages/jest-environment-node/package.json index 4b5c5bac86ff..4406f44fe3c0 100644 --- a/packages/jest-environment-node/package.json +++ b/packages/jest-environment-node/package.json @@ -1,6 +1,6 @@ { "name": "jest-environment-node", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -10,11 +10,11 @@ "main": "build/index.js", "types": "build/index.d.ts", "dependencies": { - "@jest/environment": "^26.0.1", - "@jest/fake-timers": "^26.0.1", - "@jest/types": "^26.0.1", - "jest-mock": "^26.0.1", - "jest-util": "^26.0.1" + "@jest/environment": "^26.1.0", + "@jest/fake-timers": "^26.1.0", + "@jest/types": "^26.1.0", + "jest-mock": "^26.1.0", + "jest-util": "^26.1.0" }, "engines": { "node": ">= 10.14.2" diff --git a/packages/jest-environment/package.json b/packages/jest-environment/package.json index 2e20a43d3929..8a9d04b316ab 100644 --- a/packages/jest-environment/package.json +++ b/packages/jest-environment/package.json @@ -1,6 +1,6 @@ { "name": "@jest/environment", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -10,9 +10,9 @@ "main": "build/index.js", "types": "build/index.d.ts", "dependencies": { - "@jest/fake-timers": "^26.0.1", - "@jest/types": "^26.0.1", - "jest-mock": "^26.0.1" + "@jest/fake-timers": "^26.1.0", + "@jest/types": "^26.1.0", + "jest-mock": "^26.1.0" }, "devDependencies": { "@types/node": "*" diff --git a/packages/jest-fake-timers/package.json b/packages/jest-fake-timers/package.json index 38bf54d895fe..8f62d5f004a7 100644 --- a/packages/jest-fake-timers/package.json +++ b/packages/jest-fake-timers/package.json @@ -1,6 +1,6 @@ { "name": "@jest/fake-timers", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -10,11 +10,11 @@ "main": "build/index.js", "types": "build/index.d.ts", "dependencies": { - "@jest/types": "^26.0.1", + "@jest/types": "^26.1.0", "@sinonjs/fake-timers": "^6.0.1", - "jest-message-util": "^26.0.1", - "jest-mock": "^26.0.1", - "jest-util": "^26.0.1" + "jest-message-util": "^26.1.0", + "jest-mock": "^26.1.0", + "jest-util": "^26.1.0" }, "devDependencies": { "@types/node": "*", diff --git a/packages/jest-globals/package.json b/packages/jest-globals/package.json index 0e72b005f5c2..63680cbff0f5 100644 --- a/packages/jest-globals/package.json +++ b/packages/jest-globals/package.json @@ -1,6 +1,6 @@ { "name": "@jest/globals", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -13,9 +13,9 @@ "main": "build/index.js", "types": "build/index.d.ts", "dependencies": { - "@jest/environment": "^26.0.1", - "@jest/types": "^26.0.1", - "expect": "^26.0.1" + "@jest/environment": "^26.1.0", + "@jest/types": "^26.1.0", + "expect": "^26.1.0" }, "publishConfig": { "access": "public" diff --git a/packages/jest-haste-map/package.json b/packages/jest-haste-map/package.json index 27c83cc27d59..adaae2e44f74 100644 --- a/packages/jest-haste-map/package.json +++ b/packages/jest-haste-map/package.json @@ -1,6 +1,6 @@ { "name": "jest-haste-map", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -10,14 +10,14 @@ "main": "build/index.js", "types": "build/index.d.ts", "dependencies": { - "@jest/types": "^26.0.1", + "@jest/types": "^26.1.0", "@types/graceful-fs": "^4.1.2", "anymatch": "^3.0.3", "fb-watchman": "^2.0.0", "graceful-fs": "^4.2.4", - "jest-serializer": "^26.0.0", - "jest-util": "^26.0.1", - "jest-worker": "^26.0.0", + "jest-serializer": "^26.1.0", + "jest-util": "^26.1.0", + "jest-worker": "^26.1.0", "micromatch": "^4.0.2", "sane": "^4.0.3", "walker": "^1.0.7", diff --git a/packages/jest-jasmine2/package.json b/packages/jest-jasmine2/package.json index 4ecf77950a42..c9e52fb7490b 100644 --- a/packages/jest-jasmine2/package.json +++ b/packages/jest-jasmine2/package.json @@ -1,6 +1,6 @@ { "name": "jest-jasmine2", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -11,21 +11,21 @@ "types": "build/index.d.ts", "dependencies": { "@babel/traverse": "^7.1.0", - "@jest/environment": "^26.0.1", - "@jest/source-map": "^26.0.0", - "@jest/test-result": "^26.0.1", - "@jest/types": "^26.0.1", + "@jest/environment": "^26.1.0", + "@jest/source-map": "^26.1.0", + "@jest/test-result": "^26.1.0", + "@jest/types": "^26.1.0", "chalk": "^4.0.0", "co": "^4.6.0", - "expect": "^26.0.1", + "expect": "^26.1.0", "is-generator-fn": "^2.0.0", - "jest-each": "^26.0.1", - "jest-matcher-utils": "^26.0.1", - "jest-message-util": "^26.0.1", - "jest-runtime": "^26.0.1", - "jest-snapshot": "^26.0.1", - "jest-util": "^26.0.1", - "pretty-format": "^26.0.1", + "jest-each": "^26.1.0", + "jest-matcher-utils": "^26.1.0", + "jest-message-util": "^26.1.0", + "jest-runtime": "^26.1.0", + "jest-snapshot": "^26.1.0", + "jest-util": "^26.1.0", + "pretty-format": "^26.1.0", "throat": "^5.0.0" }, "devDependencies": { diff --git a/packages/jest-leak-detector/package.json b/packages/jest-leak-detector/package.json index c453f56aaae8..1af441209a3e 100644 --- a/packages/jest-leak-detector/package.json +++ b/packages/jest-leak-detector/package.json @@ -1,6 +1,6 @@ { "name": "jest-leak-detector", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -11,7 +11,7 @@ "types": "build/index.d.ts", "dependencies": { "jest-get-type": "^26.0.0", - "pretty-format": "^26.0.1" + "pretty-format": "^26.1.0" }, "devDependencies": { "@types/weak-napi": "^1.0.0", diff --git a/packages/jest-matcher-utils/package.json b/packages/jest-matcher-utils/package.json index 1ef5f889f1cf..4c06512408c8 100644 --- a/packages/jest-matcher-utils/package.json +++ b/packages/jest-matcher-utils/package.json @@ -1,7 +1,7 @@ { "name": "jest-matcher-utils", "description": "A set of utility functions for expect and related packages", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -15,9 +15,9 @@ "types": "build/index.d.ts", "dependencies": { "chalk": "^4.0.0", - "jest-diff": "^26.0.1", + "jest-diff": "^26.1.0", "jest-get-type": "^26.0.0", - "pretty-format": "^26.0.1" + "pretty-format": "^26.1.0" }, "devDependencies": { "@jest/test-utils": "^26.0.0", diff --git a/packages/jest-message-util/package.json b/packages/jest-message-util/package.json index a05bf137adde..d2303c9b7147 100644 --- a/packages/jest-message-util/package.json +++ b/packages/jest-message-util/package.json @@ -1,6 +1,6 @@ { "name": "jest-message-util", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -14,7 +14,7 @@ "types": "build/index.d.ts", "dependencies": { "@babel/code-frame": "^7.0.0", - "@jest/types": "^26.0.1", + "@jest/types": "^26.1.0", "@types/stack-utils": "^1.0.1", "chalk": "^4.0.0", "graceful-fs": "^4.2.4", diff --git a/packages/jest-mock/package.json b/packages/jest-mock/package.json index b883b188f2c4..49884eb6e748 100644 --- a/packages/jest-mock/package.json +++ b/packages/jest-mock/package.json @@ -1,6 +1,6 @@ { "name": "jest-mock", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -10,7 +10,7 @@ "node": ">= 10.14.2" }, "dependencies": { - "@jest/types": "^26.0.1" + "@jest/types": "^26.1.0" }, "devDependencies": { "@types/node": "*" diff --git a/packages/jest-phabricator/package.json b/packages/jest-phabricator/package.json index 927731a07662..5971fccb7cee 100644 --- a/packages/jest-phabricator/package.json +++ b/packages/jest-phabricator/package.json @@ -1,6 +1,6 @@ { "name": "jest-phabricator", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -8,7 +8,7 @@ }, "types": "build/index.d.ts", "dependencies": { - "@jest/test-result": "^26.0.1" + "@jest/test-result": "^26.1.0" }, "engines": { "node": ">= 10.14.2" diff --git a/packages/jest-repl/package.json b/packages/jest-repl/package.json index fd1b1d69f98e..f2ff983acfe9 100644 --- a/packages/jest-repl/package.json +++ b/packages/jest-repl/package.json @@ -1,6 +1,6 @@ { "name": "jest-repl", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -10,11 +10,11 @@ "main": "build/index.js", "types": "build/index.d.ts", "dependencies": { - "@jest/transform": "^26.0.1", - "@jest/types": "^26.0.1", - "jest-config": "^26.0.1", - "jest-runtime": "^26.0.1", - "jest-validate": "^26.0.1", + "@jest/transform": "^26.1.0", + "@jest/types": "^26.1.0", + "jest-config": "^26.1.0", + "jest-runtime": "^26.1.0", + "jest-validate": "^26.1.0", "repl": "^0.1.3", "yargs": "^15.3.1" }, diff --git a/packages/jest-reporters/package.json b/packages/jest-reporters/package.json index 02c2d0eff3ce..3d7134e35df5 100644 --- a/packages/jest-reporters/package.json +++ b/packages/jest-reporters/package.json @@ -1,15 +1,15 @@ { "name": "@jest/reporters", "description": "Jest's reporters", - "version": "26.0.1", + "version": "26.1.0", "main": "build/index.js", "types": "build/index.d.ts", "dependencies": { "@bcoe/v8-coverage": "^0.2.3", - "@jest/console": "^26.0.1", - "@jest/test-result": "^26.0.1", - "@jest/transform": "^26.0.1", - "@jest/types": "^26.0.1", + "@jest/console": "^26.1.0", + "@jest/test-result": "^26.1.0", + "@jest/transform": "^26.1.0", + "@jest/types": "^26.1.0", "chalk": "^4.0.0", "collect-v8-coverage": "^1.0.0", "exit": "^0.1.2", @@ -20,10 +20,10 @@ "istanbul-lib-report": "^3.0.0", "istanbul-lib-source-maps": "^4.0.0", "istanbul-reports": "^3.0.2", - "jest-haste-map": "^26.0.1", - "jest-resolve": "^26.0.1", - "jest-util": "^26.0.1", - "jest-worker": "^26.0.0", + "jest-haste-map": "^26.1.0", + "jest-resolve": "^26.1.0", + "jest-util": "^26.1.0", + "jest-worker": "^26.1.0", "slash": "^3.0.0", "source-map": "^0.6.0", "string-length": "^4.0.1", diff --git a/packages/jest-resolve-dependencies/package.json b/packages/jest-resolve-dependencies/package.json index f669ee56e6d3..c05172707857 100644 --- a/packages/jest-resolve-dependencies/package.json +++ b/packages/jest-resolve-dependencies/package.json @@ -1,6 +1,6 @@ { "name": "jest-resolve-dependencies", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -10,14 +10,14 @@ "main": "build/index.js", "types": "build/index.d.ts", "dependencies": { - "@jest/types": "^26.0.1", + "@jest/types": "^26.1.0", "jest-regex-util": "^26.0.0", - "jest-snapshot": "^26.0.1" + "jest-snapshot": "^26.1.0" }, "devDependencies": { - "jest-haste-map": "^26.0.1", - "jest-resolve": "^26.0.1", - "jest-runtime": "^26.0.1" + "jest-haste-map": "^26.1.0", + "jest-resolve": "^26.1.0", + "jest-runtime": "^26.1.0" }, "engines": { "node": ">= 10.14.2" diff --git a/packages/jest-resolve/package.json b/packages/jest-resolve/package.json index 2a5702e0ef43..62420e739a2b 100644 --- a/packages/jest-resolve/package.json +++ b/packages/jest-resolve/package.json @@ -1,6 +1,6 @@ { "name": "jest-resolve", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -10,11 +10,11 @@ "main": "build/index.js", "types": "build/index.d.ts", "dependencies": { - "@jest/types": "^26.0.1", + "@jest/types": "^26.1.0", "chalk": "^4.0.0", "graceful-fs": "^4.2.4", "jest-pnp-resolver": "^1.2.1", - "jest-util": "^26.0.1", + "jest-util": "^26.1.0", "read-pkg-up": "^7.0.1", "resolve": "^1.17.0", "slash": "^3.0.0" @@ -22,7 +22,7 @@ "devDependencies": { "@types/graceful-fs": "^4.1.3", "@types/resolve": "^1.17.0", - "jest-haste-map": "^26.0.1" + "jest-haste-map": "^26.1.0" }, "engines": { "node": ">= 10.14.2" diff --git a/packages/jest-runner/package.json b/packages/jest-runner/package.json index 9aa6d4dd1685..7865fcb759e6 100644 --- a/packages/jest-runner/package.json +++ b/packages/jest-runner/package.json @@ -1,6 +1,6 @@ { "name": "jest-runner", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -10,23 +10,23 @@ "main": "build/index.js", "types": "build/index.d.ts", "dependencies": { - "@jest/console": "^26.0.1", - "@jest/environment": "^26.0.1", - "@jest/test-result": "^26.0.1", - "@jest/types": "^26.0.1", + "@jest/console": "^26.1.0", + "@jest/environment": "^26.1.0", + "@jest/test-result": "^26.1.0", + "@jest/types": "^26.1.0", "chalk": "^4.0.0", "exit": "^0.1.2", "graceful-fs": "^4.2.4", - "jest-config": "^26.0.1", + "jest-config": "^26.1.0", "jest-docblock": "^26.0.0", - "jest-haste-map": "^26.0.1", - "jest-jasmine2": "^26.0.1", - "jest-leak-detector": "^26.0.1", - "jest-message-util": "^26.0.1", - "jest-resolve": "^26.0.1", - "jest-runtime": "^26.0.1", - "jest-util": "^26.0.1", - "jest-worker": "^26.0.0", + "jest-haste-map": "^26.1.0", + "jest-jasmine2": "^26.1.0", + "jest-leak-detector": "^26.1.0", + "jest-message-util": "^26.1.0", + "jest-resolve": "^26.1.0", + "jest-runtime": "^26.1.0", + "jest-util": "^26.1.0", + "jest-worker": "^26.1.0", "source-map-support": "^0.5.6", "throat": "^5.0.0" }, @@ -35,7 +35,7 @@ "@types/graceful-fs": "^4.1.2", "@types/node": "*", "@types/source-map-support": "^0.5.0", - "jest-circus": "^26.0.1" + "jest-circus": "^26.1.0" }, "engines": { "node": ">= 10.14.2" diff --git a/packages/jest-runtime/package.json b/packages/jest-runtime/package.json index e8c0ea9c80aa..8ff32b015983 100644 --- a/packages/jest-runtime/package.json +++ b/packages/jest-runtime/package.json @@ -1,6 +1,6 @@ { "name": "jest-runtime", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -10,29 +10,29 @@ "main": "build/index.js", "types": "build/index.d.ts", "dependencies": { - "@jest/console": "^26.0.1", - "@jest/environment": "^26.0.1", - "@jest/fake-timers": "^26.0.1", - "@jest/globals": "^26.0.1", - "@jest/source-map": "^26.0.0", - "@jest/test-result": "^26.0.1", - "@jest/transform": "^26.0.1", - "@jest/types": "^26.0.1", + "@jest/console": "^26.1.0", + "@jest/environment": "^26.1.0", + "@jest/fake-timers": "^26.1.0", + "@jest/globals": "^26.1.0", + "@jest/source-map": "^26.1.0", + "@jest/test-result": "^26.1.0", + "@jest/transform": "^26.1.0", + "@jest/types": "^26.1.0", "@types/yargs": "^15.0.0", "chalk": "^4.0.0", "collect-v8-coverage": "^1.0.0", "exit": "^0.1.2", "glob": "^7.1.3", "graceful-fs": "^4.2.4", - "jest-config": "^26.0.1", - "jest-haste-map": "^26.0.1", - "jest-message-util": "^26.0.1", - "jest-mock": "^26.0.1", + "jest-config": "^26.1.0", + "jest-haste-map": "^26.1.0", + "jest-message-util": "^26.1.0", + "jest-mock": "^26.1.0", "jest-regex-util": "^26.0.0", - "jest-resolve": "^26.0.1", - "jest-snapshot": "^26.0.1", - "jest-util": "^26.0.1", - "jest-validate": "^26.0.1", + "jest-resolve": "^26.1.0", + "jest-snapshot": "^26.1.0", + "jest-util": "^26.1.0", + "jest-validate": "^26.1.0", "slash": "^3.0.0", "strip-bom": "^4.0.0", "yargs": "^15.3.1" @@ -43,7 +43,7 @@ "@types/glob": "^7.1.1", "@types/graceful-fs": "^4.1.2", "execa": "^4.0.0", - "jest-environment-node": "^26.0.1", + "jest-environment-node": "^26.1.0", "jest-snapshot-serializer-raw": "^1.1.0" }, "bin": "./bin/jest-runtime.js", diff --git a/packages/jest-serializer/package.json b/packages/jest-serializer/package.json index 908d4913ebc9..8d7bd50f1493 100644 --- a/packages/jest-serializer/package.json +++ b/packages/jest-serializer/package.json @@ -1,6 +1,6 @@ { "name": "jest-serializer", - "version": "26.0.0", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", diff --git a/packages/jest-snapshot/package.json b/packages/jest-snapshot/package.json index 278988d20188..0cd196403d4e 100644 --- a/packages/jest-snapshot/package.json +++ b/packages/jest-snapshot/package.json @@ -1,6 +1,6 @@ { "name": "jest-snapshot", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -11,19 +11,19 @@ "types": "build/index.d.ts", "dependencies": { "@babel/types": "^7.0.0", - "@jest/types": "^26.0.1", + "@jest/types": "^26.1.0", "@types/prettier": "^2.0.0", "chalk": "^4.0.0", - "expect": "^26.0.1", + "expect": "^26.1.0", "graceful-fs": "^4.2.4", - "jest-diff": "^26.0.1", + "jest-diff": "^26.1.0", "jest-get-type": "^26.0.0", - "jest-haste-map": "^26.0.1", - "jest-matcher-utils": "^26.0.1", - "jest-message-util": "^26.0.1", - "jest-resolve": "^26.0.1", + "jest-haste-map": "^26.1.0", + "jest-matcher-utils": "^26.1.0", + "jest-message-util": "^26.1.0", + "jest-resolve": "^26.1.0", "natural-compare": "^1.4.0", - "pretty-format": "^26.0.1", + "pretty-format": "^26.1.0", "semver": "^7.3.2" }, "devDependencies": { diff --git a/packages/jest-source-map/package.json b/packages/jest-source-map/package.json index 75d347cdb343..355f9405a1e6 100644 --- a/packages/jest-source-map/package.json +++ b/packages/jest-source-map/package.json @@ -1,6 +1,6 @@ { "name": "@jest/source-map", - "version": "26.0.0", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", diff --git a/packages/jest-test-result/package.json b/packages/jest-test-result/package.json index 16d101b0d721..9da64be85195 100644 --- a/packages/jest-test-result/package.json +++ b/packages/jest-test-result/package.json @@ -1,6 +1,6 @@ { "name": "@jest/test-result", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -10,8 +10,8 @@ "main": "build/index.js", "types": "build/index.d.ts", "dependencies": { - "@jest/console": "^26.0.1", - "@jest/types": "^26.0.1", + "@jest/console": "^26.1.0", + "@jest/types": "^26.1.0", "@types/istanbul-lib-coverage": "^2.0.0", "collect-v8-coverage": "^1.0.0" }, diff --git a/packages/jest-test-sequencer/package.json b/packages/jest-test-sequencer/package.json index e770122a4b8f..e2df36e9f06d 100644 --- a/packages/jest-test-sequencer/package.json +++ b/packages/jest-test-sequencer/package.json @@ -1,6 +1,6 @@ { "name": "@jest/test-sequencer", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -10,11 +10,11 @@ "main": "build/index.js", "types": "build/index.d.ts", "dependencies": { - "@jest/test-result": "^26.0.1", + "@jest/test-result": "^26.1.0", "graceful-fs": "^4.2.4", - "jest-haste-map": "^26.0.1", - "jest-runner": "^26.0.1", - "jest-runtime": "^26.0.1" + "jest-haste-map": "^26.1.0", + "jest-runner": "^26.1.0", + "jest-runtime": "^26.1.0" }, "devDependencies": { "@types/graceful-fs": "^4.1.3" diff --git a/packages/jest-transform/package.json b/packages/jest-transform/package.json index 03ebfa288e7d..774a44ecc8f1 100644 --- a/packages/jest-transform/package.json +++ b/packages/jest-transform/package.json @@ -1,6 +1,6 @@ { "name": "@jest/transform", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -11,15 +11,15 @@ "types": "build/index.d.ts", "dependencies": { "@babel/core": "^7.1.0", - "@jest/types": "^26.0.1", + "@jest/types": "^26.1.0", "babel-plugin-istanbul": "^6.0.0", "chalk": "^4.0.0", "convert-source-map": "^1.4.0", "fast-json-stable-stringify": "^2.0.0", "graceful-fs": "^4.2.4", - "jest-haste-map": "^26.0.1", + "jest-haste-map": "^26.1.0", "jest-regex-util": "^26.0.0", - "jest-util": "^26.0.1", + "jest-util": "^26.1.0", "micromatch": "^4.0.2", "pirates": "^4.0.1", "slash": "^3.0.0", diff --git a/packages/jest-types/package.json b/packages/jest-types/package.json index 37ac76583ff3..3c568f119ae4 100644 --- a/packages/jest-types/package.json +++ b/packages/jest-types/package.json @@ -1,6 +1,6 @@ { "name": "@jest/types", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", diff --git a/packages/jest-util/package.json b/packages/jest-util/package.json index 24180e5a499b..342587f6bbf2 100644 --- a/packages/jest-util/package.json +++ b/packages/jest-util/package.json @@ -1,6 +1,6 @@ { "name": "jest-util", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -10,7 +10,7 @@ "main": "build/index.js", "types": "build/index.d.ts", "dependencies": { - "@jest/types": "^26.0.1", + "@jest/types": "^26.1.0", "chalk": "^4.0.0", "graceful-fs": "^4.2.4", "is-ci": "^2.0.0", diff --git a/packages/jest-validate/package.json b/packages/jest-validate/package.json index 10b4657088da..285063a5bd78 100644 --- a/packages/jest-validate/package.json +++ b/packages/jest-validate/package.json @@ -1,6 +1,6 @@ { "name": "jest-validate", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -10,12 +10,12 @@ "main": "build/index.js", "types": "build/index.d.ts", "dependencies": { - "@jest/types": "^26.0.1", + "@jest/types": "^26.1.0", "camelcase": "^6.0.0", "chalk": "^4.0.0", "jest-get-type": "^26.0.0", "leven": "^3.1.0", - "pretty-format": "^26.0.1" + "pretty-format": "^26.1.0" }, "devDependencies": { "@types/yargs": "^15.0.3" diff --git a/packages/jest-watcher/package.json b/packages/jest-watcher/package.json index d07444b635d1..d1c10ea44a57 100644 --- a/packages/jest-watcher/package.json +++ b/packages/jest-watcher/package.json @@ -1,15 +1,15 @@ { "name": "jest-watcher", "description": "Delightful JavaScript Testing.", - "version": "26.0.1", + "version": "26.1.0", "main": "build/index.js", "types": "build/index.d.ts", "dependencies": { - "@jest/test-result": "^26.0.1", - "@jest/types": "^26.0.1", + "@jest/test-result": "^26.1.0", + "@jest/types": "^26.1.0", "ansi-escapes": "^4.2.1", "chalk": "^4.0.0", - "jest-util": "^26.0.1", + "jest-util": "^26.1.0", "string-length": "^4.0.1" }, "devDependencies": { diff --git a/packages/jest-worker/package.json b/packages/jest-worker/package.json index 3ae7e37c53ef..a0b890832260 100644 --- a/packages/jest-worker/package.json +++ b/packages/jest-worker/package.json @@ -1,6 +1,6 @@ { "name": "jest-worker", - "version": "26.0.0", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", diff --git a/packages/jest/package.json b/packages/jest/package.json index 2fa45c69e1be..f4e5cd781828 100644 --- a/packages/jest/package.json +++ b/packages/jest/package.json @@ -1,13 +1,13 @@ { "name": "jest", "description": "Delightful JavaScript Testing.", - "version": "26.0.1", + "version": "26.1.0", "main": "build/jest.js", "types": "build/jest.d.ts", "dependencies": { - "@jest/core": "^26.0.1", + "@jest/core": "^26.1.0", "import-local": "^3.0.2", - "jest-cli": "^26.0.1" + "jest-cli": "^26.1.0" }, "bin": "./bin/jest.js", "engines": { diff --git a/packages/pretty-format/package.json b/packages/pretty-format/package.json index 15419caa53da..3aff77d65d70 100644 --- a/packages/pretty-format/package.json +++ b/packages/pretty-format/package.json @@ -1,6 +1,6 @@ { "name": "pretty-format", - "version": "26.0.1", + "version": "26.1.0", "repository": { "type": "git", "url": "https://github.com/facebook/jest.git", @@ -12,7 +12,7 @@ "types": "build/index.d.ts", "author": "James Kyle ", "dependencies": { - "@jest/types": "^26.0.1", + "@jest/types": "^26.1.0", "ansi-regex": "^5.0.0", "ansi-styles": "^4.0.0", "react-is": "^16.12.0"