bupkis 0.2.0 → 0.4.0
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.
- package/CHANGELOG.md +27 -0
- package/README.md +35 -11
- package/dist/commonjs/assertion/assertion-async.d.ts +2 -1
- package/dist/commonjs/assertion/assertion-async.d.ts.map +1 -1
- package/dist/commonjs/assertion/assertion-async.js +84 -2
- package/dist/commonjs/assertion/assertion-async.js.map +1 -1
- package/dist/commonjs/assertion/assertion-sync.d.ts +1 -1
- package/dist/commonjs/assertion/assertion-sync.d.ts.map +1 -1
- package/dist/commonjs/assertion/assertion-sync.js +5 -1
- package/dist/commonjs/assertion/assertion-sync.js.map +1 -1
- package/dist/commonjs/assertion/assertion-types.d.ts +6 -2
- package/dist/commonjs/assertion/assertion-types.d.ts.map +1 -1
- package/dist/commonjs/assertion/assertion.d.ts +1 -1
- package/dist/commonjs/assertion/assertion.d.ts.map +1 -1
- package/dist/commonjs/assertion/assertion.js +1 -14
- package/dist/commonjs/assertion/assertion.js.map +1 -1
- package/dist/commonjs/assertion/impl/async.d.ts +122 -21
- package/dist/commonjs/assertion/impl/async.d.ts.map +1 -1
- package/dist/commonjs/assertion/impl/async.js +118 -90
- package/dist/commonjs/assertion/impl/async.js.map +1 -1
- package/dist/commonjs/assertion/impl/callback.d.ts +104 -0
- package/dist/commonjs/assertion/impl/callback.d.ts.map +1 -0
- package/dist/commonjs/assertion/impl/callback.js +694 -0
- package/dist/commonjs/assertion/impl/callback.js.map +1 -0
- package/dist/commonjs/assertion/impl/index.d.ts +1 -1
- package/dist/commonjs/assertion/impl/index.d.ts.map +1 -1
- package/dist/commonjs/assertion/impl/index.js.map +1 -1
- package/dist/commonjs/assertion/impl/sync-basic.d.ts.map +1 -1
- package/dist/commonjs/assertion/impl/sync-basic.js +1 -1
- package/dist/commonjs/assertion/impl/sync-basic.js.map +1 -1
- package/dist/commonjs/assertion/impl/sync-collection.d.ts +1 -1
- package/dist/commonjs/assertion/impl/sync-collection.js +3 -3
- package/dist/commonjs/assertion/impl/sync-collection.js.map +1 -1
- package/dist/commonjs/assertion/impl/sync-esoteric.js +1 -1
- package/dist/commonjs/assertion/impl/sync-esoteric.js.map +1 -1
- package/dist/commonjs/assertion/impl/sync-parametric.d.ts +22 -28
- package/dist/commonjs/assertion/impl/sync-parametric.d.ts.map +1 -1
- package/dist/commonjs/assertion/impl/sync-parametric.js +35 -50
- package/dist/commonjs/assertion/impl/sync-parametric.js.map +1 -1
- package/dist/commonjs/assertion/impl/sync.d.ts +68 -30
- package/dist/commonjs/assertion/impl/sync.d.ts.map +1 -1
- package/dist/commonjs/assertion/impl/sync.js +4 -1
- package/dist/commonjs/assertion/impl/sync.js.map +1 -1
- package/dist/commonjs/bootstrap.d.ts +147 -52
- package/dist/commonjs/bootstrap.d.ts.map +1 -1
- package/dist/commonjs/bootstrap.js +2 -3
- package/dist/commonjs/bootstrap.js.map +1 -1
- package/dist/commonjs/constant.d.ts +1 -1
- package/dist/commonjs/constant.d.ts.map +1 -1
- package/dist/commonjs/constant.js +8 -1
- package/dist/commonjs/constant.js.map +1 -1
- package/dist/commonjs/error.d.ts +22 -2
- package/dist/commonjs/error.d.ts.map +1 -1
- package/dist/commonjs/error.js +44 -4
- package/dist/commonjs/error.js.map +1 -1
- package/dist/commonjs/expect.d.ts.map +1 -1
- package/dist/commonjs/expect.js +1 -1
- package/dist/commonjs/expect.js.map +1 -1
- package/dist/commonjs/guards.d.ts +96 -5
- package/dist/commonjs/guards.d.ts.map +1 -1
- package/dist/commonjs/guards.js +104 -25
- package/dist/commonjs/guards.js.map +1 -1
- package/dist/commonjs/index.d.ts +146 -51
- package/dist/commonjs/index.d.ts.map +1 -1
- package/dist/commonjs/index.js.map +1 -1
- package/dist/commonjs/schema.d.ts +84 -18
- package/dist/commonjs/schema.d.ts.map +1 -1
- package/dist/commonjs/schema.js +107 -22
- package/dist/commonjs/schema.js.map +1 -1
- package/dist/commonjs/types.d.ts +171 -9
- package/dist/commonjs/types.d.ts.map +1 -1
- package/dist/commonjs/use.d.ts.map +1 -1
- package/dist/commonjs/use.js +15 -1
- package/dist/commonjs/use.js.map +1 -1
- package/dist/commonjs/util.d.ts +66 -50
- package/dist/commonjs/util.d.ts.map +1 -1
- package/dist/commonjs/util.js +169 -156
- package/dist/commonjs/util.js.map +1 -1
- package/dist/commonjs/value-to-schema.d.ts +122 -0
- package/dist/commonjs/value-to-schema.d.ts.map +1 -0
- package/dist/commonjs/value-to-schema.js +329 -0
- package/dist/commonjs/value-to-schema.js.map +1 -0
- package/dist/esm/assertion/assertion-async.d.ts +2 -1
- package/dist/esm/assertion/assertion-async.d.ts.map +1 -1
- package/dist/esm/assertion/assertion-async.js +85 -3
- package/dist/esm/assertion/assertion-async.js.map +1 -1
- package/dist/esm/assertion/assertion-sync.d.ts +1 -1
- package/dist/esm/assertion/assertion-sync.d.ts.map +1 -1
- package/dist/esm/assertion/assertion-sync.js +6 -2
- package/dist/esm/assertion/assertion-sync.js.map +1 -1
- package/dist/esm/assertion/assertion-types.d.ts +6 -2
- package/dist/esm/assertion/assertion-types.d.ts.map +1 -1
- package/dist/esm/assertion/assertion.d.ts +1 -1
- package/dist/esm/assertion/assertion.d.ts.map +1 -1
- package/dist/esm/assertion/assertion.js +1 -14
- package/dist/esm/assertion/assertion.js.map +1 -1
- package/dist/esm/assertion/impl/async.d.ts +122 -21
- package/dist/esm/assertion/impl/async.d.ts.map +1 -1
- package/dist/esm/assertion/impl/async.js +118 -90
- package/dist/esm/assertion/impl/async.js.map +1 -1
- package/dist/esm/assertion/impl/callback.d.ts +104 -0
- package/dist/esm/assertion/impl/callback.d.ts.map +1 -0
- package/dist/esm/assertion/impl/callback.js +691 -0
- package/dist/esm/assertion/impl/callback.js.map +1 -0
- package/dist/esm/assertion/impl/index.d.ts +1 -1
- package/dist/esm/assertion/impl/index.d.ts.map +1 -1
- package/dist/esm/assertion/impl/index.js +1 -1
- package/dist/esm/assertion/impl/index.js.map +1 -1
- package/dist/esm/assertion/impl/sync-basic.d.ts.map +1 -1
- package/dist/esm/assertion/impl/sync-basic.js +2 -2
- package/dist/esm/assertion/impl/sync-basic.js.map +1 -1
- package/dist/esm/assertion/impl/sync-collection.d.ts +1 -1
- package/dist/esm/assertion/impl/sync-collection.js +3 -3
- package/dist/esm/assertion/impl/sync-collection.js.map +1 -1
- package/dist/esm/assertion/impl/sync-esoteric.js +2 -2
- package/dist/esm/assertion/impl/sync-esoteric.js.map +1 -1
- package/dist/esm/assertion/impl/sync-parametric.d.ts +22 -28
- package/dist/esm/assertion/impl/sync-parametric.d.ts.map +1 -1
- package/dist/esm/assertion/impl/sync-parametric.js +36 -51
- package/dist/esm/assertion/impl/sync-parametric.js.map +1 -1
- package/dist/esm/assertion/impl/sync.d.ts +68 -30
- package/dist/esm/assertion/impl/sync.d.ts.map +1 -1
- package/dist/esm/assertion/impl/sync.js +3 -1
- package/dist/esm/assertion/impl/sync.js.map +1 -1
- package/dist/esm/bootstrap.d.ts +147 -52
- package/dist/esm/bootstrap.d.ts.map +1 -1
- package/dist/esm/bootstrap.js +1 -2
- package/dist/esm/bootstrap.js.map +1 -1
- package/dist/esm/constant.d.ts +1 -1
- package/dist/esm/constant.d.ts.map +1 -1
- package/dist/esm/constant.js +7 -0
- package/dist/esm/constant.js.map +1 -1
- package/dist/esm/error.d.ts +22 -2
- package/dist/esm/error.d.ts.map +1 -1
- package/dist/esm/error.js +43 -4
- package/dist/esm/error.js.map +1 -1
- package/dist/esm/expect.d.ts.map +1 -1
- package/dist/esm/expect.js +2 -2
- package/dist/esm/expect.js.map +1 -1
- package/dist/esm/guards.d.ts +96 -5
- package/dist/esm/guards.d.ts.map +1 -1
- package/dist/esm/guards.js +98 -21
- package/dist/esm/guards.js.map +1 -1
- package/dist/esm/index.d.ts +146 -51
- package/dist/esm/index.d.ts.map +1 -1
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/schema.d.ts +84 -18
- package/dist/esm/schema.d.ts.map +1 -1
- package/dist/esm/schema.js +107 -22
- package/dist/esm/schema.js.map +1 -1
- package/dist/esm/types.d.ts +171 -9
- package/dist/esm/types.d.ts.map +1 -1
- package/dist/esm/use.d.ts.map +1 -1
- package/dist/esm/use.js +15 -1
- package/dist/esm/use.js.map +1 -1
- package/dist/esm/util.d.ts +66 -50
- package/dist/esm/util.d.ts.map +1 -1
- package/dist/esm/util.js +153 -154
- package/dist/esm/util.js.map +1 -1
- package/dist/esm/value-to-schema.d.ts +122 -0
- package/dist/esm/value-to-schema.d.ts.map +1 -0
- package/dist/esm/value-to-schema.js +325 -0
- package/dist/esm/value-to-schema.js.map +1 -0
- package/package.json +16 -13
- package/src/assertion/assertion-async.ts +113 -3
- package/src/assertion/assertion-sync.ts +5 -2
- package/src/assertion/assertion-types.ts +14 -4
- package/src/assertion/assertion.ts +2 -17
- package/src/assertion/impl/async.ts +137 -93
- package/src/assertion/impl/callback.ts +882 -0
- package/src/assertion/impl/index.ts +1 -1
- package/src/assertion/impl/sync-basic.ts +5 -2
- package/src/assertion/impl/sync-collection.ts +3 -3
- package/src/assertion/impl/sync-esoteric.ts +2 -2
- package/src/assertion/impl/sync-parametric.ts +47 -54
- package/src/assertion/impl/sync.ts +3 -0
- package/src/bootstrap.ts +1 -2
- package/src/constant.ts +10 -0
- package/src/error.ts +57 -3
- package/src/expect.ts +6 -2
- package/src/guards.ts +125 -18
- package/src/index.ts +3 -0
- package/src/schema.ts +121 -23
- package/src/types.ts +205 -10
- package/src/use.ts +22 -0
- package/src/util.ts +168 -223
- package/src/value-to-schema.ts +489 -0
|
@@ -14,7 +14,7 @@ declare const
|
|
|
14
14
|
*
|
|
15
15
|
* @function
|
|
16
16
|
*/
|
|
17
|
-
expect: Expect<readonly [import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").
|
|
17
|
+
expect: Expect<readonly [import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodCustom<Map<unknown, unknown>, Map<unknown, unknown>>, readonly ["to contain", "to include"], import("zod/v4").ZodAny], (subject: Map<unknown, unknown>, key: any) => boolean, readonly [import("zod/v4").ZodCustom<Map<unknown, unknown>, Map<unknown, unknown>>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to contain", "to include"]>, import("zod/v4").ZodAny]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodCustom<Map<unknown, unknown>, Map<unknown, unknown>>, "to have size", import("zod/v4").ZodNumber], (subject: Map<unknown, unknown>, expectedSize: number) => boolean, readonly [import("zod/v4").ZodCustom<Map<unknown, unknown>, Map<unknown, unknown>>, import("./types.js").PhraseLiteralSlot<"to have size">, import("zod/v4").ZodNumber]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodCustom<Map<unknown, unknown>, Map<unknown, unknown>>, "to be empty"], (subject: Map<unknown, unknown>) => boolean, readonly [import("zod/v4").ZodCustom<Map<unknown, unknown>, Map<unknown, unknown>>, import("./types.js").PhraseLiteralSlot<"to be empty">]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodCustom<Set<unknown>, Set<unknown>>, readonly ["to contain", "to include"], import("zod/v4").ZodAny], (subject: Set<unknown>, value: any) => boolean, readonly [import("zod/v4").ZodCustom<Set<unknown>, Set<unknown>>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to contain", "to include"]>, import("zod/v4").ZodAny]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodCustom<Set<unknown>, Set<unknown>>, "to have size", import("zod/v4").ZodNumber], (subject: Set<unknown>, expectedSize: number) => boolean, readonly [import("zod/v4").ZodCustom<Set<unknown>, Set<unknown>>, import("./types.js").PhraseLiteralSlot<"to have size">, import("zod/v4").ZodNumber]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodCustom<Set<unknown>, Set<unknown>>, "to be empty"], (subject: Set<unknown>) => boolean, readonly [import("zod/v4").ZodCustom<Set<unknown>, Set<unknown>>, import("./types.js").PhraseLiteralSlot<"to be empty">]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodCustom<WeakMap<WeakKey, unknown>, WeakMap<WeakKey, unknown>>, readonly ["to contain", "to include"], import("zod/v4").ZodAny], (subject: WeakMap<WeakKey, unknown>, key: any) => boolean, readonly [import("zod/v4").ZodCustom<WeakMap<WeakKey, unknown>, WeakMap<WeakKey, unknown>>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to contain", "to include"]>, import("zod/v4").ZodAny]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodCustom<WeakSet<WeakKey>, WeakSet<WeakKey>>, readonly ["to contain", "to include"], import("zod/v4").ZodAny], (subject: WeakSet<WeakKey>, value: any) => boolean, readonly [import("zod/v4").ZodCustom<WeakSet<WeakKey>, WeakSet<WeakKey>>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to contain", "to include"]>, import("zod/v4").ZodAny]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodArray<import("zod/v4").ZodAny>, readonly ["to contain", "to include"], import("zod/v4").ZodAny], (subject: any[], value: any) => boolean, readonly [import("zod/v4").ZodArray<import("zod/v4").ZodAny>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to contain", "to include"]>, import("zod/v4").ZodAny]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodArray<import("zod/v4").ZodAny>, "to have size", import("zod/v4").ZodNumber], (subject: any[], expectedSize: number) => boolean, readonly [import("zod/v4").ZodArray<import("zod/v4").ZodAny>, import("./types.js").PhraseLiteralSlot<"to have size">, import("zod/v4").ZodNumber]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodArray<import("zod/v4").ZodAny>, "to have length", import("zod/v4").ZodNumber], (subject: any[], expectedLength: number) => boolean, readonly [import("zod/v4").ZodArray<import("zod/v4").ZodAny>, import("./types.js").PhraseLiteralSlot<"to have length">, import("zod/v4").ZodNumber]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodArray<import("zod/v4").ZodAny>, "to be non-empty"], (subject: any[]) => {
|
|
18
18
|
actual: number;
|
|
19
19
|
expected: string;
|
|
20
20
|
message: string;
|
|
@@ -86,15 +86,21 @@ expect: Expect<readonly [import("./types.js").AssertionFunctionSync<readonly [im
|
|
|
86
86
|
actual: unknown;
|
|
87
87
|
expected: unknown;
|
|
88
88
|
message: string;
|
|
89
|
-
} | undefined, readonly [import("zod/v4").ZodUnknown, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to be", "to equal", "equals", "is", "is equal to", "to strictly equal"]>, import("zod/v4").ZodUnknown]>, import("./types.js").
|
|
90
|
-
|
|
91
|
-
},
|
|
92
|
-
|
|
93
|
-
}, import("zod/v4/core").$loose
|
|
89
|
+
} | undefined, readonly [import("zod/v4").ZodUnknown, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to be", "to equal", "equals", "is", "is equal to", "to strictly equal"]>, import("zod/v4").ZodUnknown]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>, readonly ["to deep equal", "to deeply equal"], import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>], (_: {
|
|
90
|
+
[x: string]: unknown;
|
|
91
|
+
}, expected: {
|
|
92
|
+
[x: string]: unknown;
|
|
93
|
+
}) => import("zod/v4").ZodType<any, unknown, import("zod/v4/core").$ZodTypeInternals<any, unknown>>, readonly [import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to deep equal", "to deeply equal"]>, import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodArray<import("zod/v4").ZodUnknown>, import("zod/v4").ZodTuple<[import("zod/v4").ZodUnknown], import("zod/v4").ZodUnknown>, import("zod/v4").ZodObject<{
|
|
94
94
|
length: import("zod/v4").ZodNumber;
|
|
95
95
|
}, import("zod/v4/core").$loose>]>, readonly ["to deep equal", "to deeply equal"], import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodArray<import("zod/v4").ZodUnknown>, import("zod/v4").ZodTuple<[import("zod/v4").ZodUnknown], import("zod/v4").ZodUnknown>, import("zod/v4").ZodObject<{
|
|
96
96
|
length: import("zod/v4").ZodNumber;
|
|
97
|
-
}, import("zod/v4/core").$loose>]>]
|
|
97
|
+
}, import("zod/v4/core").$loose>]>], (_: unknown[] | [unknown, ...unknown[]] | {
|
|
98
|
+
[x: string]: unknown;
|
|
99
|
+
length: number;
|
|
100
|
+
}, expected: unknown[] | [unknown, ...unknown[]] | {
|
|
101
|
+
[x: string]: unknown;
|
|
102
|
+
length: number;
|
|
103
|
+
}) => import("zod/v4").ZodType<any, unknown, import("zod/v4/core").$ZodTypeInternals<any, unknown>>, readonly [import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodArray<import("zod/v4").ZodUnknown>, import("zod/v4").ZodTuple<[import("zod/v4").ZodUnknown], import("zod/v4").ZodUnknown>, import("zod/v4").ZodObject<{
|
|
98
104
|
length: import("zod/v4").ZodNumber;
|
|
99
105
|
}, import("zod/v4/core").$loose>]>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to deep equal", "to deeply equal"]>, import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodArray<import("zod/v4").ZodUnknown>, import("zod/v4").ZodTuple<[import("zod/v4").ZodUnknown], import("zod/v4").ZodUnknown>, import("zod/v4").ZodObject<{
|
|
100
106
|
length: import("zod/v4").ZodNumber;
|
|
@@ -109,77 +115,166 @@ expect: Expect<readonly [import("./types.js").AssertionFunctionSync<readonly [im
|
|
|
109
115
|
[x: string]: unknown;
|
|
110
116
|
}) => boolean, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to throw"]>, import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodString, import("zod/v4").ZodCustom<RegExp, RegExp>, import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>]>]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to throw a", "to thrown an"], import("zod/v4").ZodCustom<import("./types.js").Constructor, import("./types.js").Constructor>, "satisfying", import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodString, import("zod/v4").ZodCustom<RegExp, RegExp>, import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>]>], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, ctor: import("./types.js").Constructor, param: string | RegExp | {
|
|
111
117
|
[x: string]: unknown;
|
|
112
|
-
}) => {
|
|
113
|
-
actual:
|
|
118
|
+
}) => import("zod/v4").ZodError<unknown> | {
|
|
119
|
+
actual: never;
|
|
114
120
|
expected: string;
|
|
115
121
|
message: string;
|
|
116
|
-
} | {
|
|
117
|
-
actual:
|
|
118
|
-
expected:
|
|
119
|
-
[x: string]: unknown;
|
|
120
|
-
};
|
|
122
|
+
} | undefined, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to throw a", "to thrown an"]>, import("zod/v4").ZodCustom<import("./types.js").Constructor, import("./types.js").Constructor>, import("./types.js").PhraseLiteralSlot<"satisfying">, import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodString, import("zod/v4").ZodCustom<RegExp, RegExp>, import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>]>]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodString, readonly ["includes", "contains", "to include", "to contain"], import("zod/v4").ZodString], (subject: string, expected: string) => {
|
|
123
|
+
actual: string;
|
|
124
|
+
expected: string;
|
|
121
125
|
message: string;
|
|
122
|
-
} | undefined, readonly [import("zod/v4").
|
|
126
|
+
} | undefined, readonly [import("zod/v4").ZodString, import("./types.js").PhraseLiteralChoiceSlot<readonly ["includes", "contains", "to include", "to contain"]>, import("zod/v4").ZodString]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodString, "to match", import("zod/v4").ZodCustom<RegExp, RegExp>], (subject: string, regex: RegExp) => boolean, readonly [import("zod/v4").ZodString, import("./types.js").PhraseLiteralSlot<"to match">, import("zod/v4").ZodCustom<RegExp, RegExp>]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodNonOptional<import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>>, readonly ["to satisfy", "to be like"], import("zod/v4").ZodType<import("./types.js").SatisfyPatternValue, unknown, import("zod/v4/core").$ZodTypeInternals<import("./types.js").SatisfyPatternValue, unknown>>], (_subject: {
|
|
123
127
|
[x: string]: unknown;
|
|
124
|
-
}, shape: {
|
|
125
|
-
[x: string]: unknown;
|
|
126
|
-
}) => import("zod/v4").ZodType<{}, import("zod/v4/core").$loose>, readonly [import("zod/v4").ZodNonOptional<import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to satisfy", "to be like"]>, import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodArray<import("zod/v4").ZodUnknown>, import("zod/v4").ZodTuple<[import("zod/v4").ZodUnknown], import("zod/v4").ZodUnknown>, import("zod/v4").ZodObject<{
|
|
127
|
-
length: import("zod/v4").ZodNumber;
|
|
128
|
-
}, import("zod/v4/core").$loose>]>, readonly ["to satisfy", "to be like"], import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodArray<import("zod/v4").ZodUnknown>, import("zod/v4").ZodTuple<[import("zod/v4").ZodUnknown], import("zod/v4").ZodUnknown>, import("zod/v4").ZodObject<{
|
|
128
|
+
}, shape: import("./types.js").SatisfyPatternValue) => import("zod/v4").ZodType<any, unknown, import("zod/v4/core").$ZodTypeInternals<any, unknown>>, readonly [import("zod/v4").ZodNonOptional<import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to satisfy", "to be like"]>, import("zod/v4").ZodType<import("./types.js").SatisfyPatternValue, unknown, import("zod/v4/core").$ZodTypeInternals<import("./types.js").SatisfyPatternValue, unknown>>]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodArray<import("zod/v4").ZodUnknown>, import("zod/v4").ZodTuple<[import("zod/v4").ZodUnknown], import("zod/v4").ZodUnknown>, import("zod/v4").ZodObject<{
|
|
129
129
|
length: import("zod/v4").ZodNumber;
|
|
130
|
-
}, import("zod/v4/core").$loose>]
|
|
131
|
-
[x: string]: unknown;
|
|
132
|
-
length: number;
|
|
133
|
-
}, shape: unknown[] | [unknown, ...unknown[]] | {
|
|
130
|
+
}, import("zod/v4/core").$loose>]>, readonly ["to satisfy", "to be like"], import("zod/v4").ZodType<import("./types.js").SatisfyPatternValue, unknown, import("zod/v4/core").$ZodTypeInternals<import("./types.js").SatisfyPatternValue, unknown>>], (_subject: unknown[] | [unknown, ...unknown[]] | {
|
|
134
131
|
[x: string]: unknown;
|
|
135
132
|
length: number;
|
|
136
|
-
}
|
|
133
|
+
}, shape: import("./types.js").SatisfyPatternValue) => import("zod/v4").ZodType<any, unknown, import("zod/v4/core").$ZodTypeInternals<any, unknown>>, readonly [import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodArray<import("zod/v4").ZodUnknown>, import("zod/v4").ZodTuple<[import("zod/v4").ZodUnknown], import("zod/v4").ZodUnknown>, import("zod/v4").ZodObject<{
|
|
137
134
|
length: import("zod/v4").ZodNumber;
|
|
138
|
-
}, import("zod/v4/core").$loose>]>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to satisfy", "to be like"]>, import("zod/v4").
|
|
139
|
-
length: import("zod/v4").ZodNumber;
|
|
140
|
-
}, import("zod/v4/core").$loose>]>]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, "to have arity", import("zod/v4").ZodNumber], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, expectedArity: number) => {
|
|
135
|
+
}, import("zod/v4/core").$loose>]>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to satisfy", "to be like"]>, import("zod/v4").ZodType<import("./types.js").SatisfyPatternValue, unknown, import("zod/v4/core").$ZodTypeInternals<import("./types.js").SatisfyPatternValue, unknown>>]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, "to have arity", import("zod/v4").ZodNumber], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, expectedArity: number) => {
|
|
141
136
|
actual: number;
|
|
142
137
|
expected: number;
|
|
143
138
|
message: string;
|
|
144
|
-
} | undefined, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralSlot<"to have arity">, import("zod/v4").ZodNumber]>]>,
|
|
139
|
+
} | undefined, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralSlot<"to have arity">, import("zod/v4").ZodNumber]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to call callback", "to invoke callback"]], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown) => boolean, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to call callback", "to invoke callback"]>]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to call nodeback", "to invoke nodeback"]], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown) => boolean, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to call nodeback", "to invoke nodeback"]>]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to call callback with", "to invoke callback with"], import("zod/v4").ZodUnknown], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, param: unknown) => {
|
|
140
|
+
actual: string;
|
|
141
|
+
expected: string;
|
|
142
|
+
message: string;
|
|
143
|
+
} | import("zod/v4").ZodError<any> | undefined, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to call callback with", "to invoke callback with"]>, import("zod/v4").ZodUnknown]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to call callback with exactly", "to call callback with exact value", "to invoke callback with exactly", "to invoke callback with exact value"], import("zod/v4").ZodUnknown], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, expected: unknown) => {
|
|
144
|
+
actual: unknown;
|
|
145
|
+
expected: unknown;
|
|
146
|
+
message: string;
|
|
147
|
+
} | undefined, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to call callback with exactly", "to call callback with exact value", "to invoke callback with exactly", "to invoke callback with exact value"]>, import("zod/v4").ZodUnknown]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to call nodeback with", "to invoke nodeback with"], import("zod/v4").ZodUnknown], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, param: unknown) => {
|
|
148
|
+
actual: string;
|
|
149
|
+
expected: string;
|
|
150
|
+
message: string;
|
|
151
|
+
} | import("zod/v4").ZodError<any> | undefined, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to call nodeback with", "to invoke nodeback with"]>, import("zod/v4").ZodUnknown]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to call nodeback with exactly", "to call nodeback with exact value", "to invoke nodeback with exactly", "to invoke nodeback with exact value"], import("zod/v4").ZodUnknown], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, expected: unknown) => {
|
|
152
|
+
actual: unknown;
|
|
153
|
+
expected: unknown;
|
|
154
|
+
message: string;
|
|
155
|
+
} | undefined, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to call nodeback with exactly", "to call nodeback with exact value", "to invoke nodeback with exactly", "to invoke nodeback with exact value"]>, import("zod/v4").ZodUnknown]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to call nodeback with error", "to invoke nodeback with error"]], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown) => {
|
|
156
|
+
actual: string;
|
|
157
|
+
expected: string;
|
|
158
|
+
message: string;
|
|
159
|
+
} | undefined, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to call nodeback with error", "to invoke nodeback with error"]>]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to call nodeback with a", "to call nodeback with an", "to invoke nodeback with a", "to invoke nodeback with an"], import("zod/v4").ZodCustom<import("./types.js").Constructor, import("./types.js").Constructor>], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, ctor: import("./types.js").Constructor) => {
|
|
160
|
+
actual: string;
|
|
161
|
+
expected: string;
|
|
162
|
+
message: string;
|
|
163
|
+
} | undefined, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to call nodeback with a", "to call nodeback with an", "to invoke nodeback with a", "to invoke nodeback with an"]>, import("zod/v4").ZodCustom<import("./types.js").Constructor, import("./types.js").Constructor>]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to call nodeback with error", "to invoke nodeback with error"], import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodString, import("zod/v4").ZodCustom<RegExp, RegExp>, import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>]>], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, param: string | RegExp | {
|
|
164
|
+
[x: string]: unknown;
|
|
165
|
+
}) => import("zod/v4").ZodError<unknown> | {
|
|
166
|
+
actual: string;
|
|
167
|
+
expected: string;
|
|
168
|
+
message: string;
|
|
169
|
+
} | undefined, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to call nodeback with error", "to invoke nodeback with error"]>, import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodString, import("zod/v4").ZodCustom<RegExp, RegExp>, import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>]>]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to call callback with value satisfying", "to invoke callback with value satisfying"], import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodString, import("zod/v4").ZodCustom<RegExp, RegExp>, import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>]>], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, param: string | RegExp | {
|
|
170
|
+
[x: string]: unknown;
|
|
171
|
+
}) => {
|
|
172
|
+
actual: string;
|
|
173
|
+
expected: string;
|
|
174
|
+
message: string;
|
|
175
|
+
} | import("zod/v4").ZodError<any> | undefined, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to call callback with value satisfying", "to invoke callback with value satisfying"]>, import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodString, import("zod/v4").ZodCustom<RegExp, RegExp>, import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>]>]>, import("./types.js").AssertionFunctionSync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to call nodeback with value satisfying", "to invoke nodeback with value satisfying"], import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodString, import("zod/v4").ZodCustom<RegExp, RegExp>, import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>]>], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, param: string | RegExp | {
|
|
176
|
+
[x: string]: unknown;
|
|
177
|
+
}) => {
|
|
178
|
+
actual: string;
|
|
179
|
+
expected: string;
|
|
180
|
+
message: string;
|
|
181
|
+
} | import("zod/v4").ZodError<any> | undefined, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to call nodeback with value satisfying", "to invoke nodeback with value satisfying"]>, import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodString, import("zod/v4").ZodCustom<RegExp, RegExp>, import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>]>]>]>,
|
|
145
182
|
/**
|
|
146
183
|
* The main asynchronous assertion function which can execute only built-in
|
|
147
184
|
* assertions.
|
|
148
185
|
*
|
|
149
186
|
* @function
|
|
150
187
|
*/
|
|
151
|
-
expectAsync: ExpectAsync<readonly [import("./types.js").AssertionFunctionAsync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to resolve", "to fulfill"]], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown) => Promise<
|
|
152
|
-
|
|
153
|
-
|
|
188
|
+
expectAsync: ExpectAsync<readonly [import("./types.js").AssertionFunctionAsync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to resolve", "to fulfill"]], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown) => Promise<{
|
|
189
|
+
actual: string;
|
|
190
|
+
expected: string;
|
|
191
|
+
message: string;
|
|
192
|
+
} | undefined>, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to resolve", "to fulfill"]>]>, import("./types.js").AssertionFunctionAsync<readonly [import("zod/v4").ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, readonly ["to resolve", "to fulfill"]], (subject: PromiseLike<unknown>) => Promise<{
|
|
193
|
+
actual: string;
|
|
194
|
+
expected: string;
|
|
195
|
+
message: string;
|
|
196
|
+
} | undefined>, readonly [import("zod/v4").ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to resolve", "to fulfill"]>]>, import("./types.js").AssertionFunctionAsync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, "to reject"], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown) => Promise<{
|
|
197
|
+
actual: string;
|
|
198
|
+
expected: string;
|
|
199
|
+
message: string;
|
|
200
|
+
} | undefined>, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralSlot<"to reject">]>, import("./types.js").AssertionFunctionAsync<readonly [import("zod/v4").ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, "to reject"], (subject: PromiseLike<unknown>) => Promise<{
|
|
201
|
+
actual: string;
|
|
202
|
+
expected: string;
|
|
203
|
+
message: string;
|
|
204
|
+
} | undefined>, readonly [import("zod/v4").ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, import("./types.js").PhraseLiteralSlot<"to reject">]>, import("./types.js").AssertionFunctionAsync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to reject with a", "to reject with an"], import("zod/v4").ZodCustom<import("./types.js").Constructor, import("./types.js").Constructor>], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, ctor: import("./types.js").Constructor) => Promise<boolean>, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to reject with a", "to reject with an"]>, import("zod/v4").ZodCustom<import("./types.js").Constructor, import("./types.js").Constructor>]>, import("./types.js").AssertionFunctionAsync<readonly [import("zod/v4").ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, readonly ["to reject with a", "to reject with an"], import("zod/v4").ZodCustom<import("./types.js").Constructor, import("./types.js").Constructor>], (subject: PromiseLike<unknown>, ctor: import("./types.js").Constructor) => Promise<boolean>, readonly [import("zod/v4").ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to reject with a", "to reject with an"]>, import("zod/v4").ZodCustom<import("./types.js").Constructor, import("./types.js").Constructor>]>, import("./types.js").AssertionFunctionAsync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to reject with error satisfying"], import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodString, import("zod/v4").ZodCustom<RegExp, RegExp>, import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>]>], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, param: string | RegExp | {
|
|
154
205
|
[x: string]: unknown;
|
|
155
|
-
}) => Promise<
|
|
206
|
+
}) => Promise<import("zod/v4").ZodError<unknown> | {
|
|
207
|
+
actual: string;
|
|
208
|
+
expect: string;
|
|
209
|
+
message: string;
|
|
210
|
+
} | undefined>, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to reject with error satisfying"]>, import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodString, import("zod/v4").ZodCustom<RegExp, RegExp>, import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>]>]>, import("./types.js").AssertionFunctionAsync<readonly [import("zod/v4").ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, readonly ["to reject with error satisfying"], import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodString, import("zod/v4").ZodCustom<RegExp, RegExp>, import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>]>], (subject: PromiseLike<unknown>, param: string | RegExp | {
|
|
156
211
|
[x: string]: unknown;
|
|
157
|
-
}) => Promise<
|
|
158
|
-
actual:
|
|
212
|
+
}) => Promise<import("zod/v4").ZodError<unknown> | {
|
|
213
|
+
actual: string;
|
|
159
214
|
expect: string;
|
|
160
215
|
message: string;
|
|
161
|
-
|
|
162
|
-
|
|
216
|
+
} | undefined>, readonly [import("zod/v4").ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to reject with error satisfying"]>, import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodString, import("zod/v4").ZodCustom<RegExp, RegExp>, import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>]>]>, import("./types.js").AssertionFunctionAsync<readonly [import("zod/v4").ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, readonly ["to fulfill with value satisfying", "to resolve with value satisfying"], import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodString, import("zod/v4").ZodCustom<RegExp, RegExp>, import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>]>], (promise: PromiseLike<unknown>, param: string | RegExp | {
|
|
217
|
+
[x: string]: unknown;
|
|
218
|
+
}) => Promise<import("zod/v4").ZodError<unknown> | {
|
|
163
219
|
actual: unknown;
|
|
164
|
-
|
|
165
|
-
[x: string]: unknown;
|
|
166
|
-
};
|
|
220
|
+
expect: string;
|
|
167
221
|
message: string;
|
|
168
|
-
|
|
169
|
-
}>, readonly [import("zod/v4").ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to fulfill with value satisfying", "to resolve with value satisfying"]>, import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodString, import("zod/v4").ZodCustom<RegExp, RegExp>, import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>]>]>, import("./types.js").AssertionFunctionAsync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to fulfill with value satisfying", "to resolve with value satisfying"], import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodString, import("zod/v4").ZodCustom<RegExp, RegExp>, import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>]>], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, param: string | RegExp | {
|
|
222
|
+
} | undefined>, readonly [import("zod/v4").ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to fulfill with value satisfying", "to resolve with value satisfying"]>, import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodString, import("zod/v4").ZodCustom<RegExp, RegExp>, import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>]>]>, import("./types.js").AssertionFunctionAsync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to fulfill with value satisfying", "to resolve with value satisfying"], import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodString, import("zod/v4").ZodCustom<RegExp, RegExp>, import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>]>], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, param: string | RegExp | {
|
|
170
223
|
[x: string]: unknown;
|
|
171
|
-
}) => Promise<
|
|
172
|
-
actual:
|
|
224
|
+
}) => Promise<import("zod/v4").ZodError<unknown> | {
|
|
225
|
+
actual: string;
|
|
173
226
|
expect: string;
|
|
174
227
|
message: string;
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
228
|
+
} | undefined>, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to fulfill with value satisfying", "to resolve with value satisfying"]>, import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodString, import("zod/v4").ZodCustom<RegExp, RegExp>, import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>]>]>, import("./types.js").AssertionFunctionAsync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to eventually call callback", "to eventually invoke callback"]], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown) => Promise<{
|
|
229
|
+
actual: string;
|
|
230
|
+
expected: string;
|
|
231
|
+
message: string;
|
|
232
|
+
} | undefined>, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to eventually call callback", "to eventually invoke callback"]>]>, import("./types.js").AssertionFunctionAsync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to eventually call nodeback", "to eventually invoke nodeback"]], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown) => Promise<{
|
|
233
|
+
actual: string;
|
|
234
|
+
expected: string;
|
|
235
|
+
message: string;
|
|
236
|
+
} | undefined>, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to eventually call nodeback", "to eventually invoke nodeback"]>]>, import("./types.js").AssertionFunctionAsync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to eventually call callback with", "to eventually invoke callback with"], import("zod/v4").ZodUnknown], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, param: unknown) => Promise<import("zod/v4").ZodError<any> | {
|
|
237
|
+
actual: string;
|
|
238
|
+
expected: string;
|
|
239
|
+
message: string;
|
|
240
|
+
} | undefined>, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to eventually call callback with", "to eventually invoke callback with"]>, import("zod/v4").ZodUnknown]>, import("./types.js").AssertionFunctionAsync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to eventually call callback with exactly", "to eventually call callback with exact value", "to eventually invoke callback with exactly", "to eventually invoke callback with exact value"], import("zod/v4").ZodUnknown], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, expected: unknown) => Promise<boolean | {
|
|
241
|
+
actual: string;
|
|
242
|
+
expected: string;
|
|
243
|
+
message: string;
|
|
244
|
+
}>, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to eventually call callback with exactly", "to eventually call callback with exact value", "to eventually invoke callback with exactly", "to eventually invoke callback with exact value"]>, import("zod/v4").ZodUnknown]>, import("./types.js").AssertionFunctionAsync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to eventually call nodeback with", "to eventually invoke nodeback with"], import("zod/v4").ZodUnknown], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, param: unknown) => Promise<import("zod/v4").ZodError<any> | {
|
|
245
|
+
actual: string;
|
|
246
|
+
expected: string;
|
|
247
|
+
message: string;
|
|
248
|
+
} | undefined>, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to eventually call nodeback with", "to eventually invoke nodeback with"]>, import("zod/v4").ZodUnknown]>, import("./types.js").AssertionFunctionAsync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to eventually call nodeback with exactly", "to eventually call nodeback with exact value", "to eventually invoke nodeback with exactly", "to eventually invoke nodeback with exact value"], import("zod/v4").ZodUnknown], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, expected: unknown) => Promise<boolean | {
|
|
249
|
+
actual: string;
|
|
250
|
+
expected: string;
|
|
251
|
+
message: string;
|
|
252
|
+
}>, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to eventually call nodeback with exactly", "to eventually call nodeback with exact value", "to eventually invoke nodeback with exactly", "to eventually invoke nodeback with exact value"]>, import("zod/v4").ZodUnknown]>, import("./types.js").AssertionFunctionAsync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to eventually call nodeback with error", "to eventually invoke nodeback with error"]], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown) => Promise<{
|
|
253
|
+
actual: string;
|
|
254
|
+
expected: string;
|
|
255
|
+
message: string;
|
|
256
|
+
} | undefined>, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to eventually call nodeback with error", "to eventually invoke nodeback with error"]>]>, import("./types.js").AssertionFunctionAsync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to eventually call nodeback with a", "to eventually call nodeback with an", "to eventually invoke nodeback with a", "to eventually invoke nodeback with an"], import("zod/v4").ZodCustom<import("./types.js").Constructor, import("./types.js").Constructor>], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, ctor: import("./types.js").Constructor) => Promise<{
|
|
257
|
+
actual: string;
|
|
258
|
+
expected: string;
|
|
259
|
+
message: string;
|
|
260
|
+
} | undefined>, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to eventually call nodeback with a", "to eventually call nodeback with an", "to eventually invoke nodeback with a", "to eventually invoke nodeback with an"]>, import("zod/v4").ZodCustom<import("./types.js").Constructor, import("./types.js").Constructor>]>, import("./types.js").AssertionFunctionAsync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to eventually call nodeback with error", "to eventually invoke nodeback with error"], import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodString, import("zod/v4").ZodCustom<RegExp, RegExp>, import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>]>], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, param: string | RegExp | {
|
|
261
|
+
[x: string]: unknown;
|
|
262
|
+
}) => Promise<import("zod/v4").ZodError<unknown> | {
|
|
263
|
+
actual: string;
|
|
264
|
+
expected: string;
|
|
265
|
+
message: string;
|
|
266
|
+
} | undefined>, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to eventually call nodeback with error", "to eventually invoke nodeback with error"]>, import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodString, import("zod/v4").ZodCustom<RegExp, RegExp>, import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>]>]>, import("./types.js").AssertionFunctionAsync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to eventually call callback with value satisfying", "to eventually invoke callback with value satisfying"], import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodString, import("zod/v4").ZodCustom<RegExp, RegExp>, import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>]>], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, param: string | RegExp | {
|
|
267
|
+
[x: string]: unknown;
|
|
268
|
+
}) => Promise<import("zod/v4").ZodError<any> | {
|
|
269
|
+
actual: string;
|
|
270
|
+
expected: string;
|
|
271
|
+
message: string;
|
|
272
|
+
} | undefined>, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to eventually call callback with value satisfying", "to eventually invoke callback with value satisfying"]>, import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodString, import("zod/v4").ZodCustom<RegExp, RegExp>, import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>]>]>, import("./types.js").AssertionFunctionAsync<readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to eventually call nodeback with value satisfying", "to eventually invoke nodeback with value satisfying"], import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodString, import("zod/v4").ZodCustom<RegExp, RegExp>, import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>]>], (subject: (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, param: string | RegExp | {
|
|
273
|
+
[x: string]: unknown;
|
|
274
|
+
}) => Promise<import("zod/v4").ZodError<any> | {
|
|
275
|
+
actual: string;
|
|
276
|
+
expected: string;
|
|
181
277
|
message: string;
|
|
182
|
-
|
|
183
|
-
}>, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to fulfill with value satisfying", "to resolve with value satisfying"]>, import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodString, import("zod/v4").ZodCustom<RegExp, RegExp>, import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>]>]>]>;
|
|
278
|
+
} | undefined>, readonly [import("zod/v4").ZodCustom<(...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("./types.js").MutableOrReadonly<unknown[]>) => unknown>, import("./types.js").PhraseLiteralChoiceSlot<readonly ["to eventually call nodeback with value satisfying", "to eventually invoke nodeback with value satisfying"]>, import("zod/v4").ZodUnion<readonly [import("zod/v4").ZodString, import("zod/v4").ZodCustom<RegExp, RegExp>, import("zod/v4").ZodObject<{}, import("zod/v4/core").$loose>]>]>]>;
|
|
184
279
|
export { expect, expectAsync };
|
|
185
280
|
//# sourceMappingURL=bootstrap.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"bootstrap.d.ts","sourceRoot":"","sources":["../../src/bootstrap.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;
|
|
1
|
+
{"version":3,"file":"bootstrap.d.ts","sourceRoot":"","sources":["../../src/bootstrap.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAGH,OAAO,EAAE,KAAK,MAAM,EAAE,KAAK,WAAW,EAAE,MAAM,YAAY,CAAC;AAwB3D,QAAA;AACE;;;;;GAKG;AACH,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACN;;;;;GAKG;AACH,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2hBACN,CAAC;AAER,OAAO,EAAE,MAAM,EAAE,WAAW,EAAE,CAAC"}
|
|
@@ -9,8 +9,7 @@
|
|
|
9
9
|
*/
|
|
10
10
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
11
11
|
exports.expectAsync = exports.expect = void 0;
|
|
12
|
-
const
|
|
13
|
-
const sync_js_1 = require("./assertion/impl/sync.js");
|
|
12
|
+
const index_js_1 = require("./assertion/index.js");
|
|
14
13
|
const use_js_1 = require("./use.js");
|
|
15
14
|
/**
|
|
16
15
|
* Factory function that creates both synchronous and asynchronous assertion
|
|
@@ -20,7 +19,7 @@ const use_js_1 = require("./use.js");
|
|
|
20
19
|
* @internal
|
|
21
20
|
*/
|
|
22
21
|
const bootstrap = () => {
|
|
23
|
-
const { expect, expectAsync } = (0, use_js_1.createUse)(
|
|
22
|
+
const { expect, expectAsync } = (0, use_js_1.createUse)(index_js_1.SyncAssertions, index_js_1.AsyncAssertions)([...index_js_1.SyncAssertions, ...index_js_1.AsyncAssertions]);
|
|
24
23
|
return { expect, expectAsync };
|
|
25
24
|
};
|
|
26
25
|
const api = bootstrap();
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"bootstrap.js","sourceRoot":"","sources":["../../src/bootstrap.ts"],"names":[],"mappings":";AAAA;;;;;;;GAOG;;;AAEH,
|
|
1
|
+
{"version":3,"file":"bootstrap.js","sourceRoot":"","sources":["../../src/bootstrap.ts"],"names":[],"mappings":";AAAA;;;;;;;GAOG;;;AAEH,mDAAuE;AAEvE,qCAAqC;AAErC;;;;;;GAMG;AACH,MAAM,SAAS,GAAG,GAGhB,EAAE;IACF,MAAM,EAAE,MAAM,EAAE,WAAW,EAAE,GAAG,IAAA,kBAAS,EACvC,yBAAc,EACd,0BAAe,CAChB,CAAC,CAAC,GAAG,yBAAc,EAAE,GAAG,0BAAe,CAAC,CAAC,CAAC;IAE3C,OAAO,EAAE,MAAM,EAAE,WAAW,EAAE,CAAC;AACjC,CAAC,CAAC;AAEF,MAAM,GAAG,GAAG,SAAS,EAAE,CAAC;AAExB,MAAM;AACJ;;;;;GAKG;AACH,MAAM;AACN;;;;;GAKG;AACH,WAAW,GACZ,GAAG,GAAG,CAAC;AAEC,wBAAM;AAAE,kCAAW"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constant.d.ts","sourceRoot":"","sources":["../../src/constant.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG"}
|
|
1
|
+
{"version":3,"file":"constant.d.ts","sourceRoot":"","sources":["../../src/constant.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAqCH,eAAO,MAAM,SAAS,EAAE,OAAO,MAAmC,CAAC"}
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
* @internal
|
|
11
11
|
*/
|
|
12
12
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
-
exports.kBupkisNegatedAssertionError = exports.kBupkisAssertionError = exports.kStringLiteral = void 0;
|
|
13
|
+
exports.kExpectIt = exports.kBupkisNegatedAssertionError = exports.kBupkisFailAssertionError = exports.kBupkisAssertionError = exports.kStringLiteral = void 0;
|
|
14
14
|
/**
|
|
15
15
|
* Symbol flagging the value as a Bupkis-created string literal, which will be
|
|
16
16
|
* omitted from the parameters to an `AssertionImpl`.
|
|
@@ -24,10 +24,17 @@ exports.kStringLiteral = Symbol('bupkis:string-literal');
|
|
|
24
24
|
* @internal
|
|
25
25
|
*/
|
|
26
26
|
exports.kBupkisAssertionError = Symbol('bupkis-error');
|
|
27
|
+
/**
|
|
28
|
+
* Symbol used to flag a `FailAssertionError`
|
|
29
|
+
*
|
|
30
|
+
* @internal
|
|
31
|
+
*/
|
|
32
|
+
exports.kBupkisFailAssertionError = Symbol('bupkis-fail-error');
|
|
27
33
|
/**
|
|
28
34
|
* Symbol used to flag a `NegatedAssertionError`
|
|
29
35
|
*
|
|
30
36
|
* @internal
|
|
31
37
|
*/
|
|
32
38
|
exports.kBupkisNegatedAssertionError = Symbol('bupkis-negated-error');
|
|
39
|
+
exports.kExpectIt = Symbol('bupkis-expect-it');
|
|
33
40
|
//# sourceMappingURL=constant.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constant.js","sourceRoot":"","sources":["../../src/constant.ts"],"names":[],"mappings":";AAAA;;;;;;;;;GASG;;;AAEH;;;;;GAKG;AAEU,QAAA,cAAc,GAAkB,MAAM,CAAC,uBAAuB,CAAC,CAAC;AAE7E;;;;GAIG;AAEU,QAAA,qBAAqB,GAAkB,MAAM,CAAC,cAAc,CAAC,CAAC;AAE3E;;;;GAIG;AAEU,QAAA,4BAA4B,GAAkB,MAAM,CAC/D,sBAAsB,CACvB,CAAC"}
|
|
1
|
+
{"version":3,"file":"constant.js","sourceRoot":"","sources":["../../src/constant.ts"],"names":[],"mappings":";AAAA;;;;;;;;;GASG;;;AAEH;;;;;GAKG;AAEU,QAAA,cAAc,GAAkB,MAAM,CAAC,uBAAuB,CAAC,CAAC;AAE7E;;;;GAIG;AAEU,QAAA,qBAAqB,GAAkB,MAAM,CAAC,cAAc,CAAC,CAAC;AAE3E;;;;GAIG;AACU,QAAA,yBAAyB,GACpC,MAAM,CAAC,mBAAmB,CAAC,CAAC;AAE9B;;;;GAIG;AAEU,QAAA,4BAA4B,GAAkB,MAAM,CAC/D,sBAAsB,CACvB,CAAC;AAEW,QAAA,SAAS,GAAkB,MAAM,CAAC,kBAAkB,CAAC,CAAC"}
|
package/dist/commonjs/error.d.ts
CHANGED
|
@@ -6,6 +6,8 @@
|
|
|
6
6
|
* @packageDocumentation
|
|
7
7
|
*/
|
|
8
8
|
import { AssertionError as NodeAssertionError } from 'node:assert';
|
|
9
|
+
import { z } from 'zod/v4';
|
|
10
|
+
import { type AssertionParts, type ParsedValues } from './types.js';
|
|
9
11
|
/**
|
|
10
12
|
* _BUPKIS_' s custom `AssertionError` class, which is just a thin wrapper
|
|
11
13
|
* around Node.js' {@link NodeAssertionError AssertionError}.
|
|
@@ -13,9 +15,19 @@ import { AssertionError as NodeAssertionError } from 'node:assert';
|
|
|
13
15
|
export declare class AssertionError extends NodeAssertionError {
|
|
14
16
|
name: string;
|
|
15
17
|
/**
|
|
16
|
-
* @
|
|
18
|
+
* Translates a {@link z.ZodError} into an {@link AssertionError} with a
|
|
19
|
+
* human-friendly message.
|
|
20
|
+
*
|
|
21
|
+
* @remarks
|
|
22
|
+
* This does not handle parameterized assertions with more than one parameter
|
|
23
|
+
* too cleanly; it's unclear how a test runner would display the expected
|
|
24
|
+
* values. This will probably need a fix in the future.
|
|
25
|
+
* @param stackStartFn The function to start the stack trace from
|
|
26
|
+
* @param zodError The original `ZodError`
|
|
27
|
+
* @param values Values which caused the error
|
|
28
|
+
* @returns New `AssertionError`
|
|
17
29
|
*/
|
|
18
|
-
|
|
30
|
+
static fromZodError<Parts extends AssertionParts>(zodError: z.ZodError, stackStartFn: (...args: any[]) => any, values: ParsedValues<Parts>): AssertionError;
|
|
19
31
|
/**
|
|
20
32
|
* Type guard for an instance of this error.
|
|
21
33
|
*
|
|
@@ -24,4 +36,12 @@ export declare class AssertionError extends NodeAssertionError {
|
|
|
24
36
|
*/
|
|
25
37
|
static isAssertionError(value: unknown): value is AssertionError;
|
|
26
38
|
}
|
|
39
|
+
/**
|
|
40
|
+
* Variant of an {@link AssertionError} that is thrown when
|
|
41
|
+
* {@link bupkis!expect.fail} is called.
|
|
42
|
+
*/
|
|
43
|
+
export declare class FailAssertionError extends AssertionError {
|
|
44
|
+
name: string;
|
|
45
|
+
static isFailAssertionError(err: unknown): err is FailAssertionError;
|
|
46
|
+
}
|
|
27
47
|
//# sourceMappingURL=error.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"error.d.ts","sourceRoot":"","sources":["../../src/error.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,cAAc,IAAI,kBAAkB,EAAE,MAAM,aAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"error.d.ts","sourceRoot":"","sources":["../../src/error.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,cAAc,IAAI,kBAAkB,EAAE,MAAM,aAAa,CAAC;AACnE,OAAO,EAAE,CAAC,EAAE,MAAM,QAAQ,CAAC;AAQ3B,OAAO,EAAE,KAAK,cAAc,EAAE,KAAK,YAAY,EAAE,MAAM,YAAY,CAAC;AAEpE;;;GAGG;AACH,qBAAa,cAAe,SAAQ,kBAAkB;IAM3C,IAAI,SAAoB;IAEjC;;;;;;;;;;;;OAYG;IACH,MAAM,CAAC,YAAY,CAAC,KAAK,SAAS,cAAc,EAC9C,QAAQ,EAAE,CAAC,CAAC,QAAQ,EACpB,YAAY,EAAE,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,GAAG,EACrC,MAAM,EAAE,YAAY,CAAC,KAAK,CAAC,GAC1B,cAAc;IAmBjB;;;;;OAKG;IACH,MAAM,CAAC,gBAAgB,CAAC,KAAK,EAAE,OAAO,GAAG,KAAK,IAAI,cAAc;CAMjE;AAED;;;GAGG;AACH,qBAAa,kBAAmB,SAAQ,cAAc;IAM3C,IAAI,SAAwB;IAErC,MAAM,CAAC,oBAAoB,CAAC,GAAG,EAAE,OAAO,GAAG,GAAG,IAAI,kBAAkB;CAMrE"}
|
package/dist/commonjs/error.js
CHANGED
|
@@ -7,8 +7,9 @@
|
|
|
7
7
|
* @packageDocumentation
|
|
8
8
|
*/
|
|
9
9
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
10
|
-
exports.NegatedAssertionError = exports.AssertionError = void 0;
|
|
10
|
+
exports.NegatedAssertionError = exports.FailAssertionError = exports.AssertionError = void 0;
|
|
11
11
|
const node_assert_1 = require("node:assert");
|
|
12
|
+
const v4_1 = require("zod/v4");
|
|
12
13
|
const constant_js_1 = require("./constant.js");
|
|
13
14
|
const guards_js_1 = require("./guards.js");
|
|
14
15
|
/**
|
|
@@ -22,10 +23,32 @@ class AssertionError extends node_assert_1.AssertionError {
|
|
|
22
23
|
[constant_js_1.kBupkisAssertionError] = true;
|
|
23
24
|
name = 'AssertionError';
|
|
24
25
|
/**
|
|
25
|
-
* @
|
|
26
|
+
* Translates a {@link z.ZodError} into an {@link AssertionError} with a
|
|
27
|
+
* human-friendly message.
|
|
28
|
+
*
|
|
29
|
+
* @remarks
|
|
30
|
+
* This does not handle parameterized assertions with more than one parameter
|
|
31
|
+
* too cleanly; it's unclear how a test runner would display the expected
|
|
32
|
+
* values. This will probably need a fix in the future.
|
|
33
|
+
* @param stackStartFn The function to start the stack trace from
|
|
34
|
+
* @param zodError The original `ZodError`
|
|
35
|
+
* @param values Values which caused the error
|
|
36
|
+
* @returns New `AssertionError`
|
|
26
37
|
*/
|
|
27
|
-
|
|
28
|
-
|
|
38
|
+
static fromZodError(zodError, stackStartFn, values) {
|
|
39
|
+
const flat = v4_1.z.flattenError(zodError);
|
|
40
|
+
let pretty = flat.formErrors.join('; ');
|
|
41
|
+
for (const [keypath, errors] of Object.entries(flat.fieldErrors)) {
|
|
42
|
+
pretty += `; ${keypath}: ${errors.join('; ')}`;
|
|
43
|
+
}
|
|
44
|
+
const [actual, ...expected] = values;
|
|
45
|
+
return new AssertionError({
|
|
46
|
+
actual,
|
|
47
|
+
expected: expected.length === 1 ? expected[0] : expected,
|
|
48
|
+
message: `Assertion ${this} failed: ${pretty}`,
|
|
49
|
+
operator: `${this}`,
|
|
50
|
+
stackStartFn,
|
|
51
|
+
});
|
|
29
52
|
}
|
|
30
53
|
/**
|
|
31
54
|
* Type guard for an instance of this error.
|
|
@@ -39,6 +62,22 @@ class AssertionError extends node_assert_1.AssertionError {
|
|
|
39
62
|
}
|
|
40
63
|
}
|
|
41
64
|
exports.AssertionError = AssertionError;
|
|
65
|
+
/**
|
|
66
|
+
* Variant of an {@link AssertionError} that is thrown when
|
|
67
|
+
* {@link bupkis!expect.fail} is called.
|
|
68
|
+
*/
|
|
69
|
+
class FailAssertionError extends AssertionError {
|
|
70
|
+
/**
|
|
71
|
+
* @internal
|
|
72
|
+
*/
|
|
73
|
+
[constant_js_1.kBupkisFailAssertionError] = true;
|
|
74
|
+
name = 'FailAssertionError';
|
|
75
|
+
static isFailAssertionError(err) {
|
|
76
|
+
return ((0, guards_js_1.isA)(err, FailAssertionError) &&
|
|
77
|
+
Object.hasOwn(err, constant_js_1.kBupkisFailAssertionError));
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
exports.FailAssertionError = FailAssertionError;
|
|
42
81
|
/**
|
|
43
82
|
* Error type used internally to catch failed negated assertions.
|
|
44
83
|
*
|
|
@@ -46,6 +85,7 @@ exports.AssertionError = AssertionError;
|
|
|
46
85
|
*/
|
|
47
86
|
class NegatedAssertionError extends AssertionError {
|
|
48
87
|
[constant_js_1.kBupkisNegatedAssertionError] = true;
|
|
88
|
+
name = 'NegatedAssertionError';
|
|
49
89
|
static isNegatedAssertionError(err) {
|
|
50
90
|
return ((0, guards_js_1.isA)(err, AssertionError) &&
|
|
51
91
|
Object.hasOwn(err, constant_js_1.kBupkisNegatedAssertionError));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"error.js","sourceRoot":"","sources":["../../src/error.ts"],"names":[],"mappings":";AAAA;;;;;;GAMG;;;AAEH,6CAAmE;
|
|
1
|
+
{"version":3,"file":"error.js","sourceRoot":"","sources":["../../src/error.ts"],"names":[],"mappings":";AAAA;;;;;;GAMG;;;AAEH,6CAAmE;AACnE,+BAA2B;AAE3B,+CAIuB;AACvB,2CAAkC;AAGlC;;;GAGG;AACH,MAAa,cAAe,SAAQ,4BAAkB;IACpD;;OAEG;IACH,CAAC,mCAAqB,CAAC,GAAG,IAAI,CAAC;IAEtB,IAAI,GAAG,gBAAgB,CAAC;IAEjC;;;;;;;;;;;;OAYG;IACH,MAAM,CAAC,YAAY,CACjB,QAAoB,EACpB,YAAqC,EACrC,MAA2B;QAE3B,MAAM,IAAI,GAAG,MAAC,CAAC,YAAY,CAAC,QAAQ,CAAC,CAAC;QAEtC,IAAI,MAAM,GAAG,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QACxC,KAAK,MAAM,CAAC,OAAO,EAAE,MAAM,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,IAAI,CAAC,WAAW,CAAC,EAAE,CAAC;YACjE,MAAM,IAAI,KAAK,OAAO,KAAM,MAAoB,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC;QAChE,CAAC;QAED,MAAM,CAAC,MAAM,EAAE,GAAG,QAAQ,CAAC,GAAG,MAA4C,CAAC;QAE3E,OAAO,IAAI,cAAc,CAAC;YACxB,MAAM;YACN,QAAQ,EAAE,QAAQ,CAAC,MAAM,KAAK,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,QAAQ;YACxD,OAAO,EAAE,aAAa,IAAI,YAAY,MAAM,EAAE;YAC9C,QAAQ,EAAE,GAAG,IAAI,EAAE;YACnB,YAAY;SACb,CAAC,CAAC;IACL,CAAC;IAED;;;;;OAKG;IACH,MAAM,CAAC,gBAAgB,CAAC,KAAc;QACpC,OAAO,CACL,IAAA,eAAG,EAAC,KAAK,EAAE,4BAAkB,CAAC;YAC9B,MAAM,CAAC,MAAM,CAAC,KAAK,EAAE,mCAAqB,CAAC,CAC5C,CAAC;IACJ,CAAC;CACF;AAxDD,wCAwDC;AAED;;;GAGG;AACH,MAAa,kBAAmB,SAAQ,cAAc;IACpD;;OAEG;IACH,CAAC,uCAAyB,CAAC,GAAG,IAAI,CAAC;IAE1B,IAAI,GAAG,oBAAoB,CAAC;IAErC,MAAM,CAAC,oBAAoB,CAAC,GAAY;QACtC,OAAO,CACL,IAAA,eAAG,EAAC,GAAG,EAAE,kBAAkB,CAAC;YAC5B,MAAM,CAAC,MAAM,CAAC,GAAG,EAAE,uCAAyB,CAAC,CAC9C,CAAC;IACJ,CAAC;CACF;AAdD,gDAcC;AAED;;;;GAIG;AACH,MAAa,qBAAsB,SAAQ,cAAc;IACvD,CAAC,0CAA4B,CAAC,GAAG,IAAI,CAAC;IAE7B,IAAI,GAAG,uBAAuB,CAAC;IAExC,MAAM,CAAC,uBAAuB,CAAC,GAAY;QACzC,OAAO,CACL,IAAA,eAAG,EAAC,GAAG,EAAE,cAAc,CAAC;YACxB,MAAM,CAAC,MAAM,CAAC,GAAG,EAAE,0CAA4B,CAAC,CACjD,CAAC;IACJ,CAAC;CACF;AAXD,sDAWC"}
|