From 8f14cbbde2dae020500444b9cf9f315d6476ef5a Mon Sep 17 00:00:00 2001 From: Maciej Radzikowski Date: Mon, 1 Jan 2024 22:19:07 +0100 Subject: [PATCH] feat: migrate Jest matchers to @jest/globals types (#198) Jest now includes own types in @jest/globals packages. Use it for custom Jest matchers types. Add declaration exposing custom matchers in the "expect" library types. Fixes #180 --- .../aws-sdk-client-mock-jest/package.json | 5 +- .../src/jestMatchers.ts | 59 +-- .../aws-sdk-client-mock-jest/test-d/types.ts | 5 + .../test/jestGlobals.test.ts | 14 + yarn.lock | 367 ++++++++++++++---- 5 files changed, 358 insertions(+), 92 deletions(-) create mode 100644 packages/aws-sdk-client-mock-jest/test/jestGlobals.test.ts diff --git a/packages/aws-sdk-client-mock-jest/package.json b/packages/aws-sdk-client-mock-jest/package.json index 3d23dc1..a420806 100644 --- a/packages/aws-sdk-client-mock-jest/package.json +++ b/packages/aws-sdk-client-mock-jest/package.json @@ -39,13 +39,16 @@ "dist" ], "dependencies": { - "@types/jest": "^28.1.3", + "expect": ">28.1.3", "tslib": "^2.1.0" }, "devDependencies": { "@aws-sdk/client-sns": "3.363.0", + "@jest/globals": "29.7.0", "@smithy/types": "1.1.0", + "@types/jest": "29.5.11", "aws-sdk-client-mock": "workspace:*", + "expect": "29.7.0", "jest-serializer-ansi-escapes": "2.0.1" }, "peerDependencies": { diff --git a/packages/aws-sdk-client-mock-jest/src/jestMatchers.ts b/packages/aws-sdk-client-mock-jest/src/jestMatchers.ts index f5ae0a6..bf39fcf 100644 --- a/packages/aws-sdk-client-mock-jest/src/jestMatchers.ts +++ b/packages/aws-sdk-client-mock-jest/src/jestMatchers.ts @@ -1,10 +1,12 @@ /* eslint-disable @typescript-eslint/no-explicit-any, @typescript-eslint/no-empty-interface */ import assert from 'assert'; import type {MetadataBearer} from '@smithy/types'; -import type {AwsCommand, AwsStub} from 'aws-sdk-client-mock'; +import {AwsCommand, AwsStub} from 'aws-sdk-client-mock'; import type {SinonSpyCall} from 'sinon'; +import {expect} from 'expect'; +import type {ExpectationResult, MatcherContext, MatcherFunction} from 'expect'; -interface AwsSdkJestMockBaseMatchers extends Record { +interface AwsSdkJestMockBaseMatchers extends Record { /** * Asserts {@link AwsStub Aws Client Mock} received a {@link command} exact number of {@link times} * @@ -69,7 +71,7 @@ interface AwsSdkJestMockBaseMatchers extends Record { ): R; } -interface AwsSdkJestMockAliasMatchers { +interface AwsSdkJestMockAliasMatchers extends Record { /** * Asserts {@link AwsStub Aws Client Mock} received a {@link command} exact number of {@link times} * @@ -162,9 +164,12 @@ interface AwsSdkJestMockAliasMatchers { * }); * ``` */ -export interface AwsSdkJestMockMatchers extends AwsSdkJestMockBaseMatchers, AwsSdkJestMockAliasMatchers, Record { +export interface AwsSdkJestMockMatchers extends AwsSdkJestMockBaseMatchers, AwsSdkJestMockAliasMatchers, Record { } +/** + * Types for @types/jest + */ declare global { namespace jest { interface Matchers extends AwsSdkJestMockMatchers { @@ -172,7 +177,14 @@ declare global { } } -type ClientMock = AwsStub; +/** + * Types for @jest/globals + */ +declare module 'expect' { + interface Matchers extends AwsSdkJestMockMatchers { + } +} + type AnyCommand = AwsCommand; type AnySpyCall = SinonSpyCall<[AnyCommand]>; type MessageFunctionParams = { @@ -186,7 +198,7 @@ type MessageFunctionParams = { /** * Prettyprints command calls for message */ -const printCalls = (ctx: jest.MatcherContext, calls: AnySpyCall[]): string[] => +const printCalls = (ctx: MatcherContext, calls: AnySpyCall[]): string[] => calls.length > 0 ? [ '', @@ -200,15 +212,16 @@ const printCalls = (ctx: jest.MatcherContext, calls: AnySpyCall[]): string[] => : []; const processMatch = ({ctx, mockClient, command, check, message}: { - ctx: jest.MatcherContext; - mockClient: ClientMock; + ctx: MatcherContext; + mockClient: unknown; command: new () => AnyCommand; check: (params: { calls: AnySpyCall[]; commandCalls: AnySpyCall[] }) => { pass: boolean; data: CheckData; }; message: (params: MessageFunctionParams) => string[]; -}): jest.CustomMatcherResult => { +}): ExpectationResult => { + assert(mockClient instanceof AwsStub, 'The actual must be a client mock instance'); assert( command && typeof command === 'function' && @@ -241,13 +254,13 @@ const processMatch = ({ctx, mockClient, command, check, m return {pass, message: msg}; }; -const baseMatchers: { [P in keyof AwsSdkJestMockBaseMatchers]: jest.CustomMatcher } = { +const baseMatchers: { [P in keyof AwsSdkJestMockBaseMatchers]: MatcherFunction } = { /** * implementation of {@link AwsSdkJestMockMatchers.toHaveReceivedCommand} matcher */ toHaveReceivedCommand( - this: jest.MatcherContext, - mockClient: ClientMock, + this: MatcherContext, + mockClient: unknown, command: new () => AnyCommand, ) { return processMatch({ @@ -265,8 +278,8 @@ const baseMatchers: { [P in keyof AwsSdkJestMockBaseMatchers]: jest.Cus * implementation of {@link AwsSdkJestMockMatchers.toHaveReceivedCommandTimes} matcher */ toHaveReceivedCommandTimes( - this: jest.MatcherContext, - mockClient: ClientMock, + this: MatcherContext, + mockClient: unknown, command: new () => AnyCommand, expectedCalls: number, ) { @@ -285,8 +298,8 @@ const baseMatchers: { [P in keyof AwsSdkJestMockBaseMatchers]: jest.Cus * implementation of {@link AwsSdkJestMockMatchers.toHaveReceivedCommandWith} matcher */ toHaveReceivedCommandWith( - this: jest.MatcherContext, - mockClient: ClientMock, + this: MatcherContext, + mockClient: unknown, command: new () => AnyCommand, input: Record, ) { @@ -321,11 +334,11 @@ const baseMatchers: { [P in keyof AwsSdkJestMockBaseMatchers]: jest.Cus * implementation of {@link AwsSdkJestMockMatchers.toHaveReceivedNthCommandWith} matcher */ toHaveReceivedNthCommandWith( - this: jest.MatcherContext, - mockClient: ClientMock, + this: MatcherContext, + mockClient: unknown, call: number, command: new () => AnyCommand, - input?: Record, + input: Record, ) { assert( call && typeof call === 'number' && call > 0, @@ -380,11 +393,11 @@ const baseMatchers: { [P in keyof AwsSdkJestMockBaseMatchers]: jest.Cus * implementation of {@link AwsSdkJestMockMatchers.toHaveReceivedNthSpecificCommandWith} matcher */ toHaveReceivedNthSpecificCommandWith( - this: jest.MatcherContext, - mockClient: ClientMock, + this: MatcherContext, + mockClient: unknown, call: number, command: new () => AnyCommand, - input?: Record, + input: Record, ) { assert( call && typeof call === 'number' && call > 0, @@ -438,7 +451,7 @@ const baseMatchers: { [P in keyof AwsSdkJestMockBaseMatchers]: jest.Cus }; /* typing ensures keys matching */ -const aliasMatchers: { [P in keyof AwsSdkJestMockAliasMatchers]: jest.CustomMatcher } = { +const aliasMatchers: { [P in keyof AwsSdkJestMockAliasMatchers]: MatcherFunction } = { toReceiveCommandTimes: baseMatchers.toHaveReceivedCommandTimes, toReceiveCommand: baseMatchers.toHaveReceivedCommand, toReceiveCommandWith: baseMatchers.toHaveReceivedCommandWith, diff --git a/packages/aws-sdk-client-mock-jest/test-d/types.ts b/packages/aws-sdk-client-mock-jest/test-d/types.ts index 7db88b2..c8aca39 100644 --- a/packages/aws-sdk-client-mock-jest/test-d/types.ts +++ b/packages/aws-sdk-client-mock-jest/test-d/types.ts @@ -1,8 +1,11 @@ import {mockClient} from 'aws-sdk-client-mock'; import {PublishCommand, SNSClient} from '@aws-sdk/client-sns'; +import {expect as globalsExpect} from '@jest/globals'; import {expectError} from 'tsd'; import '../src'; +expect(1).toHaveReceivedCommand(PublishCommand); + expect(mockClient(SNSClient)).toHaveReceivedCommand(PublishCommand); expectError(expect(mockClient(SNSClient)).toHaveReceivedCommand(String)); @@ -14,3 +17,5 @@ expectError(expect(mockClient(SNSClient)).toHaveReceivedCommandWith(PublishComma expect(mockClient(SNSClient)).toHaveReceivedNthCommandWith(1, PublishCommand, {Message: ''}); expectError(expect(mockClient(SNSClient)).toHaveReceivedNthCommandWith(1, PublishCommand, {Foo: ''})); + +globalsExpect(mockClient(SNSClient)).toHaveReceivedCommand(PublishCommand); diff --git a/packages/aws-sdk-client-mock-jest/test/jestGlobals.test.ts b/packages/aws-sdk-client-mock-jest/test/jestGlobals.test.ts new file mode 100644 index 0000000..e544c37 --- /dev/null +++ b/packages/aws-sdk-client-mock-jest/test/jestGlobals.test.ts @@ -0,0 +1,14 @@ +import {mockClient} from 'aws-sdk-client-mock'; +import {PublishCommand, SNSClient} from '@aws-sdk/client-sns'; +import {publishCmd1} from 'aws-sdk-client-mock/test/fixtures'; +import {expect, it} from '@jest/globals'; +import '../src'; + +const snsMock = mockClient(SNSClient); + +it('passes using @jest/globals', async () => { + const sns = new SNSClient({}); + await sns.send(publishCmd1); + + expect(() => expect(snsMock).toHaveReceivedCommand(PublishCommand)).not.toThrow(); +}); diff --git a/yarn.lock b/yarn.lock index 7503575..4fa056e 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1783,6 +1783,18 @@ __metadata: languageName: node linkType: hard +"@jest/environment@npm:^29.7.0": + version: 29.7.0 + resolution: "@jest/environment@npm:29.7.0" + dependencies: + "@jest/fake-timers": ^29.7.0 + "@jest/types": ^29.6.3 + "@types/node": "*" + jest-mock: ^29.7.0 + checksum: 6fb398143b2543d4b9b8d1c6dbce83fa5247f84f550330604be744e24c2bd2178bb893657d62d1b97cf2f24baf85c450223f8237cccb71192c36a38ea2272934 + languageName: node + linkType: hard + "@jest/expect-utils@npm:^29.5.0": version: 29.5.0 resolution: "@jest/expect-utils@npm:29.5.0" @@ -1792,6 +1804,15 @@ __metadata: languageName: node linkType: hard +"@jest/expect-utils@npm:^29.7.0": + version: 29.7.0 + resolution: "@jest/expect-utils@npm:29.7.0" + dependencies: + jest-get-type: ^29.6.3 + checksum: 75eb177f3d00b6331bcaa057e07c0ccb0733a1d0a1943e1d8db346779039cb7f103789f16e502f888a3096fb58c2300c38d1f3748b36a7fa762eb6f6d1b160ed + languageName: node + linkType: hard + "@jest/expect@npm:^29.5.0": version: 29.5.0 resolution: "@jest/expect@npm:29.5.0" @@ -1802,6 +1823,16 @@ __metadata: languageName: node linkType: hard +"@jest/expect@npm:^29.7.0": + version: 29.7.0 + resolution: "@jest/expect@npm:29.7.0" + dependencies: + expect: ^29.7.0 + jest-snapshot: ^29.7.0 + checksum: a01cb85fd9401bab3370618f4b9013b90c93536562222d920e702a0b575d239d74cecfe98010aaec7ad464f67cf534a353d92d181646a4b792acaa7e912ae55e + languageName: node + linkType: hard + "@jest/fake-timers@npm:^29.5.0": version: 29.5.0 resolution: "@jest/fake-timers@npm:29.5.0" @@ -1816,6 +1847,32 @@ __metadata: languageName: node linkType: hard +"@jest/fake-timers@npm:^29.7.0": + version: 29.7.0 + resolution: "@jest/fake-timers@npm:29.7.0" + dependencies: + "@jest/types": ^29.6.3 + "@sinonjs/fake-timers": ^10.0.2 + "@types/node": "*" + jest-message-util: ^29.7.0 + jest-mock: ^29.7.0 + jest-util: ^29.7.0 + checksum: caf2bbd11f71c9241b458d1b5a66cbe95debc5a15d96442444b5d5c7ba774f523c76627c6931cca5e10e76f0d08761f6f1f01a608898f4751a0eee54fc3d8d00 + languageName: node + linkType: hard + +"@jest/globals@npm:29.7.0": + version: 29.7.0 + resolution: "@jest/globals@npm:29.7.0" + dependencies: + "@jest/environment": ^29.7.0 + "@jest/expect": ^29.7.0 + "@jest/types": ^29.6.3 + jest-mock: ^29.7.0 + checksum: 97dbb9459135693ad3a422e65ca1c250f03d82b2a77f6207e7fa0edd2c9d2015fbe4346f3dc9ebff1678b9d8da74754d4d440b7837497f8927059c0642a22123 + languageName: node + linkType: hard + "@jest/globals@npm:^29.5.0": version: 29.5.0 resolution: "@jest/globals@npm:29.5.0" @@ -1865,15 +1922,6 @@ __metadata: languageName: node linkType: hard -"@jest/schemas@npm:^28.1.3": - version: 28.1.3 - resolution: "@jest/schemas@npm:28.1.3" - dependencies: - "@sinclair/typebox": ^0.24.1 - checksum: 3cf1d4b66c9c4ffda58b246de1ddcba8e6ad085af63dccdf07922511f13b68c0cc480a7bc620cb4f3099a6f134801c747e1df7bfc7a4ef4dceefbdea3e31e1de - languageName: node - linkType: hard - "@jest/schemas@npm:^29.4.3": version: 29.4.3 resolution: "@jest/schemas@npm:29.4.3" @@ -1883,6 +1931,15 @@ __metadata: languageName: node linkType: hard +"@jest/schemas@npm:^29.6.3": + version: 29.6.3 + resolution: "@jest/schemas@npm:29.6.3" + dependencies: + "@sinclair/typebox": ^0.27.8 + checksum: 910040425f0fc93cd13e68c750b7885590b8839066dfa0cd78e7def07bbb708ad869381f725945d66f2284de5663bbecf63e8fdd856e2ae6e261ba30b1687e93 + languageName: node + linkType: hard + "@jest/source-map@npm:^29.4.3": version: 29.4.3 resolution: "@jest/source-map@npm:29.4.3" @@ -1941,6 +1998,29 @@ __metadata: languageName: node linkType: hard +"@jest/transform@npm:^29.7.0": + version: 29.7.0 + resolution: "@jest/transform@npm:29.7.0" + dependencies: + "@babel/core": ^7.11.6 + "@jest/types": ^29.6.3 + "@jridgewell/trace-mapping": ^0.3.18 + babel-plugin-istanbul: ^6.1.1 + chalk: ^4.0.0 + convert-source-map: ^2.0.0 + fast-json-stable-stringify: ^2.1.0 + graceful-fs: ^4.2.9 + jest-haste-map: ^29.7.0 + jest-regex-util: ^29.6.3 + jest-util: ^29.7.0 + micromatch: ^4.0.4 + pirates: ^4.0.4 + slash: ^3.0.0 + write-file-atomic: ^4.0.2 + checksum: 0f8ac9f413903b3cb6d240102db848f2a354f63971ab885833799a9964999dd51c388162106a807f810071f864302cdd8e3f0c241c29ce02d85a36f18f3f40ab + languageName: node + linkType: hard + "@jest/types@npm:^29.5.0": version: 29.5.0 resolution: "@jest/types@npm:29.5.0" @@ -1955,6 +2035,20 @@ __metadata: languageName: node linkType: hard +"@jest/types@npm:^29.6.3": + version: 29.6.3 + resolution: "@jest/types@npm:29.6.3" + dependencies: + "@jest/schemas": ^29.6.3 + "@types/istanbul-lib-coverage": ^2.0.0 + "@types/istanbul-reports": ^3.0.0 + "@types/node": "*" + "@types/yargs": ^17.0.8 + chalk: ^4.0.0 + checksum: a0bcf15dbb0eca6bdd8ce61a3fb055349d40268622a7670a3b2eb3c3dbafe9eb26af59938366d520b86907b9505b0f9b29b85cec11579a9e580694b87cd90fcc + languageName: node + linkType: hard + "@jridgewell/gen-mapping@npm:^0.1.0": version: 0.1.1 resolution: "@jridgewell/gen-mapping@npm:0.1.1" @@ -2041,7 +2135,7 @@ __metadata: languageName: node linkType: hard -"@jridgewell/trace-mapping@npm:^0.3.17": +"@jridgewell/trace-mapping@npm:^0.3.17, @jridgewell/trace-mapping@npm:^0.3.18": version: 0.3.20 resolution: "@jridgewell/trace-mapping@npm:0.3.20" dependencies: @@ -2098,13 +2192,6 @@ __metadata: languageName: node linkType: hard -"@sinclair/typebox@npm:^0.24.1": - version: 0.24.28 - resolution: "@sinclair/typebox@npm:0.24.28" - checksum: adc1f06c548f0c495dad5a7124394242553e059c5ea3faa19f404b43958125366513240f17fa2b5272a3aec18618cab4137d5c85259e99ce9eaca67538af2732 - languageName: node - linkType: hard - "@sinclair/typebox@npm:^0.25.16": version: 0.25.24 resolution: "@sinclair/typebox@npm:0.25.24" @@ -2112,6 +2199,13 @@ __metadata: languageName: node linkType: hard +"@sinclair/typebox@npm:^0.27.8": + version: 0.27.8 + resolution: "@sinclair/typebox@npm:0.27.8" + checksum: 00bd7362a3439021aa1ea51b0e0d0a0e8ca1351a3d54c606b115fdcc49b51b16db6e5f43b4fe7a28c38688523e22a94d49dd31168868b655f0d4d50f032d07a1 + languageName: node + linkType: hard + "@sinonjs/commons@npm:^2.0.0": version: 2.0.0 resolution: "@sinonjs/commons@npm:2.0.0" @@ -2781,13 +2875,13 @@ __metadata: languageName: node linkType: hard -"@types/jest@npm:^28.1.3": - version: 28.1.6 - resolution: "@types/jest@npm:28.1.6" +"@types/jest@npm:29.5.11": + version: 29.5.11 + resolution: "@types/jest@npm:29.5.11" dependencies: - jest-matcher-utils: ^28.0.0 - pretty-format: ^28.0.0 - checksum: f2ba5fbefc8f44d1c16ee19d8d2811bca75754a2846e222287f2788d96062801c568215e6b81eb532a48e8cb2a7282729da1d4f6fb496831da8269c5abaad4c5 + expect: ^29.0.0 + pretty-format: ^29.0.0 + checksum: f892a06ec9f0afa9a61cd7fa316ec614e21d4df1ad301b5a837787e046fcb40dfdf7f264a55e813ac6b9b633cb9d366bd5b8d1cea725e84102477b366df23fdd languageName: node linkType: hard @@ -3420,9 +3514,11 @@ __metadata: resolution: "aws-sdk-client-mock-jest@workspace:packages/aws-sdk-client-mock-jest" dependencies: "@aws-sdk/client-sns": 3.363.0 + "@jest/globals": 29.7.0 "@smithy/types": 1.1.0 - "@types/jest": ^28.1.3 + "@types/jest": 29.5.11 aws-sdk-client-mock: "workspace:*" + expect: 29.7.0 jest-serializer-ansi-escapes: 2.0.1 tslib: ^2.1.0 peerDependencies: @@ -4567,13 +4663,6 @@ __metadata: languageName: node linkType: hard -"diff-sequences@npm:^28.1.1": - version: 28.1.1 - resolution: "diff-sequences@npm:28.1.1" - checksum: e2529036505567c7ca5a2dea86b6bcd1ca0e3ae63bf8ebf529b8a99cfa915bbf194b7021dc1c57361a4017a6d95578d4ceb29fabc3232a4f4cb866a2726c7690 - languageName: node - linkType: hard - "diff-sequences@npm:^29.4.3": version: 29.4.3 resolution: "diff-sequences@npm:29.4.3" @@ -4581,6 +4670,13 @@ __metadata: languageName: node linkType: hard +"diff-sequences@npm:^29.6.3": + version: 29.6.3 + resolution: "diff-sequences@npm:29.6.3" + checksum: f4914158e1f2276343d98ff5b31fc004e7304f5470bf0f1adb2ac6955d85a531a6458d33e87667f98f6ae52ebd3891bb47d420bb48a5bd8b7a27ee25b20e33aa + languageName: node + linkType: hard + "diff@npm:^4.0.1": version: 4.0.2 resolution: "diff@npm:4.0.2" @@ -5101,6 +5197,19 @@ __metadata: languageName: node linkType: hard +"expect@npm:29.7.0, expect@npm:^29.0.0, expect@npm:^29.7.0": + version: 29.7.0 + resolution: "expect@npm:29.7.0" + dependencies: + "@jest/expect-utils": ^29.7.0 + jest-get-type: ^29.6.3 + jest-matcher-utils: ^29.7.0 + jest-message-util: ^29.7.0 + jest-util: ^29.7.0 + checksum: 9257f10288e149b81254a0fda8ffe8d54a7061cd61d7515779998b012579d2b8c22354b0eb901daf0145f347403da582f75f359f4810c007182ad3fb318b5c0c + languageName: node + linkType: hard + "expect@npm:^29.5.0": version: 29.5.0 resolution: "expect@npm:29.5.0" @@ -6355,18 +6464,6 @@ __metadata: languageName: node linkType: hard -"jest-diff@npm:^28.1.3": - version: 28.1.3 - resolution: "jest-diff@npm:28.1.3" - dependencies: - chalk: ^4.0.0 - diff-sequences: ^28.1.1 - jest-get-type: ^28.0.2 - pretty-format: ^28.1.3 - checksum: fa8583e0ccbe775714ce850b009be1b0f6b17a4b6759f33ff47adef27942ebc610dbbcc8a5f7cfb7f12b3b3b05afc9fb41d5f766674616025032ff1e4f9866e0 - languageName: node - linkType: hard - "jest-diff@npm:^29.5.0": version: 29.5.0 resolution: "jest-diff@npm:29.5.0" @@ -6379,6 +6476,18 @@ __metadata: languageName: node linkType: hard +"jest-diff@npm:^29.7.0": + version: 29.7.0 + resolution: "jest-diff@npm:29.7.0" + dependencies: + chalk: ^4.0.0 + diff-sequences: ^29.6.3 + jest-get-type: ^29.6.3 + pretty-format: ^29.7.0 + checksum: 08e24a9dd43bfba1ef07a6374e5af138f53137b79ec3d5cc71a2303515335898888fa5409959172e1e05de966c9e714368d15e8994b0af7441f0721ee8e1bb77 + languageName: node + linkType: hard + "jest-docblock@npm:^29.4.3": version: 29.4.3 resolution: "jest-docblock@npm:29.4.3" @@ -6415,13 +6524,6 @@ __metadata: languageName: node linkType: hard -"jest-get-type@npm:^28.0.2": - version: 28.0.2 - resolution: "jest-get-type@npm:28.0.2" - checksum: 5281d7c89bc8156605f6d15784f45074f4548501195c26e9b188742768f72d40948252d13230ea905b5349038865a1a8eeff0e614cc530ff289dfc41fe843abd - languageName: node - linkType: hard - "jest-get-type@npm:^29.4.3": version: 29.4.3 resolution: "jest-get-type@npm:29.4.3" @@ -6429,6 +6531,13 @@ __metadata: languageName: node linkType: hard +"jest-get-type@npm:^29.6.3": + version: 29.6.3 + resolution: "jest-get-type@npm:29.6.3" + checksum: 88ac9102d4679d768accae29f1e75f592b760b44277df288ad76ce5bf038c3f5ce3719dea8aa0f035dac30e9eb034b848ce716b9183ad7cc222d029f03e92205 + languageName: node + linkType: hard + "jest-haste-map@npm:^29.5.0": version: 29.5.0 resolution: "jest-haste-map@npm:29.5.0" @@ -6452,6 +6561,29 @@ __metadata: languageName: node linkType: hard +"jest-haste-map@npm:^29.7.0": + version: 29.7.0 + resolution: "jest-haste-map@npm:29.7.0" + dependencies: + "@jest/types": ^29.6.3 + "@types/graceful-fs": ^4.1.3 + "@types/node": "*" + anymatch: ^3.0.3 + fb-watchman: ^2.0.0 + fsevents: ^2.3.2 + graceful-fs: ^4.2.9 + jest-regex-util: ^29.6.3 + jest-util: ^29.7.0 + jest-worker: ^29.7.0 + micromatch: ^4.0.4 + walker: ^1.0.8 + dependenciesMeta: + fsevents: + optional: true + checksum: c2c8f2d3e792a963940fbdfa563ce14ef9e14d4d86da645b96d3cd346b8d35c5ce0b992ee08593939b5f718cf0a1f5a90011a056548a1dbf58397d4356786f01 + languageName: node + linkType: hard + "jest-leak-detector@npm:^29.5.0": version: 29.5.0 resolution: "jest-leak-detector@npm:29.5.0" @@ -6462,18 +6594,6 @@ __metadata: languageName: node linkType: hard -"jest-matcher-utils@npm:^28.0.0": - version: 28.1.3 - resolution: "jest-matcher-utils@npm:28.1.3" - dependencies: - chalk: ^4.0.0 - jest-diff: ^28.1.3 - jest-get-type: ^28.0.2 - pretty-format: ^28.1.3 - checksum: 6b34f0cf66f6781e92e3bec97bf27796bd2ba31121e5c5997218d9adba6deea38a30df5203937d6785b68023ed95cbad73663cc9aad6fb0cb59aeb5813a58daf - languageName: node - linkType: hard - "jest-matcher-utils@npm:^29.5.0": version: 29.5.0 resolution: "jest-matcher-utils@npm:29.5.0" @@ -6486,6 +6606,18 @@ __metadata: languageName: node linkType: hard +"jest-matcher-utils@npm:^29.7.0": + version: 29.7.0 + resolution: "jest-matcher-utils@npm:29.7.0" + dependencies: + chalk: ^4.0.0 + jest-diff: ^29.7.0 + jest-get-type: ^29.6.3 + pretty-format: ^29.7.0 + checksum: d7259e5f995d915e8a37a8fd494cb7d6af24cd2a287b200f831717ba0d015190375f9f5dc35393b8ba2aae9b2ebd60984635269c7f8cff7d85b077543b7744cd + languageName: node + linkType: hard + "jest-message-util@npm:^29.5.0": version: 29.5.0 resolution: "jest-message-util@npm:29.5.0" @@ -6503,6 +6635,23 @@ __metadata: languageName: node linkType: hard +"jest-message-util@npm:^29.7.0": + version: 29.7.0 + resolution: "jest-message-util@npm:29.7.0" + dependencies: + "@babel/code-frame": ^7.12.13 + "@jest/types": ^29.6.3 + "@types/stack-utils": ^2.0.0 + chalk: ^4.0.0 + graceful-fs: ^4.2.9 + micromatch: ^4.0.4 + pretty-format: ^29.7.0 + slash: ^3.0.0 + stack-utils: ^2.0.3 + checksum: a9d025b1c6726a2ff17d54cc694de088b0489456c69106be6b615db7a51b7beb66788bea7a59991a019d924fbf20f67d085a445aedb9a4d6760363f4d7d09930 + languageName: node + linkType: hard + "jest-mock@npm:^29.5.0": version: 29.5.0 resolution: "jest-mock@npm:29.5.0" @@ -6514,6 +6663,17 @@ __metadata: languageName: node linkType: hard +"jest-mock@npm:^29.7.0": + version: 29.7.0 + resolution: "jest-mock@npm:29.7.0" + dependencies: + "@jest/types": ^29.6.3 + "@types/node": "*" + jest-util: ^29.7.0 + checksum: 81ba9b68689a60be1482212878973700347cb72833c5e5af09895882b9eb5c4e02843a1bbdf23f94c52d42708bab53a30c45a3482952c9eec173d1eaac5b86c5 + languageName: node + linkType: hard + "jest-pnp-resolver@npm:^1.2.2": version: 1.2.2 resolution: "jest-pnp-resolver@npm:1.2.2" @@ -6533,6 +6693,13 @@ __metadata: languageName: node linkType: hard +"jest-regex-util@npm:^29.6.3": + version: 29.6.3 + resolution: "jest-regex-util@npm:29.6.3" + checksum: 0518beeb9bf1228261695e54f0feaad3606df26a19764bc19541e0fc6e2a3737191904607fb72f3f2ce85d9c16b28df79b7b1ec9443aa08c3ef0e9efda6f8f2a + languageName: node + linkType: hard + "jest-resolve-dependencies@npm:^29.5.0": version: 29.5.0 resolution: "jest-resolve-dependencies@npm:29.5.0" @@ -6657,6 +6824,34 @@ __metadata: languageName: node linkType: hard +"jest-snapshot@npm:^29.7.0": + version: 29.7.0 + resolution: "jest-snapshot@npm:29.7.0" + dependencies: + "@babel/core": ^7.11.6 + "@babel/generator": ^7.7.2 + "@babel/plugin-syntax-jsx": ^7.7.2 + "@babel/plugin-syntax-typescript": ^7.7.2 + "@babel/types": ^7.3.3 + "@jest/expect-utils": ^29.7.0 + "@jest/transform": ^29.7.0 + "@jest/types": ^29.6.3 + babel-preset-current-node-syntax: ^1.0.0 + chalk: ^4.0.0 + expect: ^29.7.0 + graceful-fs: ^4.2.9 + jest-diff: ^29.7.0 + jest-get-type: ^29.6.3 + jest-matcher-utils: ^29.7.0 + jest-message-util: ^29.7.0 + jest-util: ^29.7.0 + natural-compare: ^1.4.0 + pretty-format: ^29.7.0 + semver: ^7.5.3 + checksum: 86821c3ad0b6899521ce75ee1ae7b01b17e6dfeff9166f2cf17f012e0c5d8c798f30f9e4f8f7f5bed01ea7b55a6bc159f5eda778311162cbfa48785447c237ad + languageName: node + linkType: hard + "jest-util@npm:^29.0.0, jest-util@npm:^29.5.0": version: 29.5.0 resolution: "jest-util@npm:29.5.0" @@ -6671,6 +6866,20 @@ __metadata: languageName: node linkType: hard +"jest-util@npm:^29.7.0": + version: 29.7.0 + resolution: "jest-util@npm:29.7.0" + dependencies: + "@jest/types": ^29.6.3 + "@types/node": "*" + chalk: ^4.0.0 + ci-info: ^3.2.0 + graceful-fs: ^4.2.9 + picomatch: ^2.2.3 + checksum: 042ab4980f4ccd4d50226e01e5c7376a8556b472442ca6091a8f102488c0f22e6e8b89ea874111d2328a2080083bf3225c86f3788c52af0bd0345a00eb57a3ca + languageName: node + linkType: hard + "jest-validate@npm:^29.5.0": version: 29.5.0 resolution: "jest-validate@npm:29.5.0" @@ -6713,6 +6922,18 @@ __metadata: languageName: node linkType: hard +"jest-worker@npm:^29.7.0": + version: 29.7.0 + resolution: "jest-worker@npm:29.7.0" + dependencies: + "@types/node": "*" + jest-util: ^29.7.0 + merge-stream: ^2.0.0 + supports-color: ^8.0.0 + checksum: 30fff60af49675273644d408b650fc2eb4b5dcafc5a0a455f238322a8f9d8a98d847baca9d51ff197b6747f54c7901daa2287799230b856a0f48287d131f8c13 + languageName: node + linkType: hard + "jest@npm:29.5.0": version: 29.5.0 resolution: "jest@npm:29.5.0" @@ -8439,15 +8660,14 @@ __metadata: languageName: node linkType: hard -"pretty-format@npm:^28.0.0, pretty-format@npm:^28.1.3": - version: 28.1.3 - resolution: "pretty-format@npm:28.1.3" +"pretty-format@npm:^29.0.0, pretty-format@npm:^29.7.0": + version: 29.7.0 + resolution: "pretty-format@npm:29.7.0" dependencies: - "@jest/schemas": ^28.1.3 - ansi-regex: ^5.0.1 + "@jest/schemas": ^29.6.3 ansi-styles: ^5.0.0 react-is: ^18.0.0 - checksum: e69f857358a3e03d271252d7524bec758c35e44680287f36c1cb905187fbc82da9981a6eb07edfd8a03bc3cbeebfa6f5234c13a3d5b59f2bbdf9b4c4053e0a7f + checksum: 032c1602383e71e9c0c02a01bbd25d6759d60e9c7cf21937dde8357aa753da348fcec5def5d1002c9678a8524d5fe099ad98861286550ef44de8808cc61e43b6 languageName: node linkType: hard @@ -9016,6 +9236,17 @@ __metadata: languageName: node linkType: hard +"semver@npm:^7.5.3": + version: 7.5.4 + resolution: "semver@npm:7.5.4" + dependencies: + lru-cache: ^6.0.0 + bin: + semver: bin/semver.js + checksum: 12d8ad952fa353b0995bf180cdac205a4068b759a140e5d3c608317098b3575ac2f1e09182206bf2eb26120e1c0ed8fb92c48c592f6099680de56bb071423ca3 + languageName: node + linkType: hard + "send@npm:0.17.2": version: 0.17.2 resolution: "send@npm:0.17.2"