@vitest/expect 3.2.1 → 3.2.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/index.d.ts +2 -1
  2. package/package.json +4 -4
package/dist/index.d.ts CHANGED
@@ -235,7 +235,8 @@ interface AsymmetricMatchersContaining extends CustomMatcher {
235
235
  */
236
236
  closeTo: (expected: number, precision?: number) => any;
237
237
  }
238
- type DeeplyAllowMatchers<T> = T extends Array<infer Element> ? (DeeplyAllowMatchers<Element> | Element)[] : T extends object ? { [K in keyof T] : DeeplyAllowMatchers<T[K]> | AsymmetricMatcher<unknown> } : T;
238
+ type WithAsymmetricMatcher<T> = T | AsymmetricMatcher<unknown>;
239
+ type DeeplyAllowMatchers<T> = T extends Array<infer Element> ? WithAsymmetricMatcher<T> | DeeplyAllowMatchers<Element>[] : T extends object ? WithAsymmetricMatcher<T> | { [K in keyof T] : DeeplyAllowMatchers<T[K]> } : WithAsymmetricMatcher<T>;
239
240
  interface JestAssertion<T = any> extends jest.Matchers<void, T>, CustomMatcher {
240
241
  /**
241
242
  * Used when you want to check that two objects have the same value.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@vitest/expect",
3
3
  "type": "module",
4
- "version": "3.2.1",
4
+ "version": "3.2.2",
5
5
  "description": "Jest's expect matchers as a Chai plugin",
6
6
  "license": "MIT",
7
7
  "funding": "https://opencollective.com/vitest",
@@ -32,12 +32,12 @@
32
32
  "@types/chai": "^5.2.2",
33
33
  "chai": "^5.2.0",
34
34
  "tinyrainbow": "^2.0.0",
35
- "@vitest/spy": "3.2.1",
36
- "@vitest/utils": "3.2.1"
35
+ "@vitest/spy": "3.2.2",
36
+ "@vitest/utils": "3.2.2"
37
37
  },
38
38
  "devDependencies": {
39
39
  "rollup-plugin-copy": "^3.5.0",
40
- "@vitest/runner": "3.2.1"
40
+ "@vitest/runner": "3.2.2"
41
41
  },
42
42
  "scripts": {
43
43
  "build": "rimraf dist && rollup -c",