bupkis 0.1.2 → 0.3.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 +28 -0
- package/README.md +16 -16
- 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 +39 -84
- 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/create.d.ts +5 -33
- package/dist/commonjs/assertion/create.d.ts.map +1 -1
- package/dist/commonjs/assertion/create.js +17 -6
- package/dist/commonjs/assertion/create.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 +114 -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-esoteric.js +1 -1
- package/dist/commonjs/assertion/impl/sync-esoteric.js.map +1 -1
- package/dist/commonjs/assertion/impl/sync-parametric.d.ts +37 -34
- package/dist/commonjs/assertion/impl/sync-parametric.d.ts.map +1 -1
- package/dist/commonjs/assertion/impl/sync-parametric.js +32 -47
- package/dist/commonjs/assertion/impl/sync-parametric.js.map +1 -1
- package/dist/commonjs/assertion/impl/sync.d.ts +105 -58
- 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 +199 -85
- package/dist/commonjs/bootstrap.d.ts.map +1 -1
- package/dist/commonjs/bootstrap.js +19 -10
- package/dist/commonjs/bootstrap.js.map +1 -1
- package/dist/commonjs/constant.js +7 -1
- package/dist/commonjs/constant.js.map +1 -1
- package/dist/commonjs/error.d.ts +32 -5
- package/dist/commonjs/error.d.ts.map +1 -1
- package/dist/commonjs/error.js +60 -5
- package/dist/commonjs/error.js.map +1 -1
- package/dist/commonjs/expect.d.ts +130 -3
- package/dist/commonjs/expect.d.ts.map +1 -1
- package/dist/commonjs/expect.js +116 -1
- package/dist/commonjs/expect.js.map +1 -1
- package/dist/commonjs/guards.d.ts +45 -20
- package/dist/commonjs/guards.d.ts.map +1 -1
- package/dist/commonjs/guards.js +56 -40
- package/dist/commonjs/guards.js.map +1 -1
- package/dist/commonjs/index.d.ts +241 -86
- package/dist/commonjs/index.d.ts.map +1 -1
- package/dist/commonjs/index.js +44 -42
- package/dist/commonjs/index.js.map +1 -1
- package/dist/commonjs/metadata.d.ts +1 -27
- package/dist/commonjs/metadata.d.ts.map +1 -1
- package/dist/commonjs/metadata.js +16 -15
- package/dist/commonjs/metadata.js.map +1 -1
- package/dist/commonjs/schema.d.ts +76 -33
- package/dist/commonjs/schema.d.ts.map +1 -1
- package/dist/commonjs/schema.js +77 -34
- package/dist/commonjs/schema.js.map +1 -1
- package/dist/commonjs/types.d.ts +480 -39
- package/dist/commonjs/types.d.ts.map +1 -1
- package/dist/commonjs/types.js +12 -2
- package/dist/commonjs/types.js.map +1 -1
- package/dist/commonjs/util.d.ts +72 -49
- package/dist/commonjs/util.d.ts.map +1 -1
- package/dist/commonjs/util.js +175 -155
- 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 +309 -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 +39 -84
- 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/create.d.ts +5 -33
- package/dist/esm/assertion/create.d.ts.map +1 -1
- package/dist/esm/assertion/create.js +14 -4
- package/dist/esm/assertion/create.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 +113 -89
- 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-esoteric.js +2 -2
- package/dist/esm/assertion/impl/sync-esoteric.js.map +1 -1
- package/dist/esm/assertion/impl/sync-parametric.d.ts +37 -34
- package/dist/esm/assertion/impl/sync-parametric.d.ts.map +1 -1
- package/dist/esm/assertion/impl/sync-parametric.js +32 -47
- package/dist/esm/assertion/impl/sync-parametric.js.map +1 -1
- package/dist/esm/assertion/impl/sync.d.ts +105 -58
- 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 +199 -85
- package/dist/esm/bootstrap.d.ts.map +1 -1
- package/dist/esm/bootstrap.js +19 -10
- package/dist/esm/bootstrap.js.map +1 -1
- package/dist/esm/constant.js +6 -0
- package/dist/esm/constant.js.map +1 -1
- package/dist/esm/error.d.ts +32 -5
- package/dist/esm/error.d.ts.map +1 -1
- package/dist/esm/error.js +59 -5
- package/dist/esm/error.js.map +1 -1
- package/dist/esm/expect.d.ts +130 -3
- package/dist/esm/expect.d.ts.map +1 -1
- package/dist/esm/expect.js +117 -2
- package/dist/esm/expect.js.map +1 -1
- package/dist/esm/guards.d.ts +45 -20
- package/dist/esm/guards.d.ts.map +1 -1
- package/dist/esm/guards.js +48 -31
- package/dist/esm/guards.js.map +1 -1
- package/dist/esm/index.d.ts +241 -86
- package/dist/esm/index.d.ts.map +1 -1
- package/dist/esm/index.js +46 -7
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/metadata.d.ts +1 -27
- package/dist/esm/metadata.d.ts.map +1 -1
- package/dist/esm/metadata.js +2 -1
- package/dist/esm/metadata.js.map +1 -1
- package/dist/esm/schema.d.ts +76 -33
- package/dist/esm/schema.d.ts.map +1 -1
- package/dist/esm/schema.js +77 -34
- package/dist/esm/schema.js.map +1 -1
- package/dist/esm/types.d.ts +480 -39
- package/dist/esm/types.d.ts.map +1 -1
- package/dist/esm/types.js +12 -2
- package/dist/esm/types.js.map +1 -1
- package/dist/esm/util.d.ts +72 -49
- package/dist/esm/util.d.ts.map +1 -1
- package/dist/esm/util.js +159 -153
- 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 +305 -0
- package/dist/esm/value-to-schema.js.map +1 -0
- package/package.json +94 -17
- package/src/assertion/assertion-async.ts +113 -3
- package/src/assertion/assertion-sync.ts +5 -2
- package/src/assertion/assertion-types.ts +52 -45
- package/src/assertion/assertion.ts +2 -17
- package/src/assertion/create.ts +16 -65
- package/src/assertion/impl/async.ts +132 -92
- package/src/assertion/impl/callback.ts +882 -0
- package/src/assertion/impl/index.ts +1 -1
- package/src/assertion/impl/sync-esoteric.ts +2 -2
- package/src/assertion/impl/sync-parametric.ts +41 -49
- package/src/assertion/impl/sync.ts +3 -0
- package/src/bootstrap.ts +21 -11
- package/src/constant.ts +8 -0
- package/src/error.ts +75 -4
- package/src/expect.ts +275 -20
- package/src/guards.ts +74 -69
- package/src/index.ts +72 -11
- package/src/metadata.ts +3 -4
- package/src/schema.ts +80 -36
- package/src/types.ts +625 -72
- package/src/util.ts +174 -222
- package/src/value-to-schema.ts +464 -0
- package/dist/commonjs/api.d.ts +0 -93
- package/dist/commonjs/api.d.ts.map +0 -1
- package/dist/commonjs/api.js +0 -8
- package/dist/commonjs/api.js.map +0 -1
- package/dist/esm/api.d.ts +0 -93
- package/dist/esm/api.d.ts.map +0 -1
- package/dist/esm/api.js +0 -7
- package/dist/esm/api.js.map +0 -1
- package/src/api.ts +0 -149
- package/src/schema.md +0 -15
|
@@ -9,37 +9,138 @@
|
|
|
9
9
|
* @packageDocumentation
|
|
10
10
|
*/
|
|
11
11
|
import { z } from 'zod/v4';
|
|
12
|
-
|
|
12
|
+
import { CallbackAsyncAssertions } from './callback.js';
|
|
13
|
+
export declare const PromiseAssertions: readonly [import("../assertion-types.js").AssertionFunctionAsync<readonly [z.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<{
|
|
14
|
+
actual: string;
|
|
15
|
+
expected: string;
|
|
16
|
+
message: string;
|
|
17
|
+
} | undefined>, readonly [z.ZodCustom<(...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown>, import("../assertion-types.js").PhraseLiteralChoiceSlot<readonly ["to resolve", "to fulfill"]>]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, readonly ["to resolve", "to fulfill"]], (subject: PromiseLike<unknown>) => Promise<{
|
|
18
|
+
actual: string;
|
|
19
|
+
expected: string;
|
|
20
|
+
message: string;
|
|
21
|
+
} | undefined>, readonly [z.ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, import("../assertion-types.js").PhraseLiteralChoiceSlot<readonly ["to resolve", "to fulfill"]>]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.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<{
|
|
22
|
+
actual: string;
|
|
23
|
+
expected: string;
|
|
24
|
+
message: string;
|
|
25
|
+
} | undefined>, readonly [z.ZodCustom<(...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown>, import("../assertion-types.js").PhraseLiteralSlot<"to reject">]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, "to reject"], (subject: PromiseLike<unknown>) => Promise<{
|
|
26
|
+
actual: string;
|
|
27
|
+
expected: string;
|
|
28
|
+
message: string;
|
|
29
|
+
} | undefined>, readonly [z.ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, import("../assertion-types.js").PhraseLiteralSlot<"to reject">]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.ZodCustom<(...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to reject with a", "to reject with an"], z.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 [z.ZodCustom<(...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown>, import("../assertion-types.js").PhraseLiteralChoiceSlot<readonly ["to reject with a", "to reject with an"]>, z.ZodCustom<import("../../types.js").Constructor, import("../../types.js").Constructor>]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, readonly ["to reject with a", "to reject with an"], z.ZodCustom<import("../../types.js").Constructor, import("../../types.js").Constructor>], (subject: PromiseLike<unknown>, ctor: import("../../types.js").Constructor) => Promise<boolean>, readonly [z.ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, import("../assertion-types.js").PhraseLiteralChoiceSlot<readonly ["to reject with a", "to reject with an"]>, z.ZodCustom<import("../../types.js").Constructor, import("../../types.js").Constructor>]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.ZodCustom<(...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to reject with error satisfying"], z.ZodUnion<readonly [z.ZodString, z.ZodCustom<RegExp, RegExp>, z.ZodObject<{}, z.core.$loose>]>], (subject: (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, param: string | RegExp | {
|
|
13
30
|
[x: string]: unknown;
|
|
14
|
-
}) => Promise<
|
|
31
|
+
}) => Promise<z.ZodError<unknown> | {
|
|
32
|
+
actual: string;
|
|
33
|
+
expect: string;
|
|
34
|
+
message: string;
|
|
35
|
+
} | undefined>, readonly [z.ZodCustom<(...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown>, import("../assertion-types.js").PhraseLiteralChoiceSlot<readonly ["to reject with error satisfying"]>, z.ZodUnion<readonly [z.ZodString, z.ZodCustom<RegExp, RegExp>, z.ZodObject<{}, z.core.$loose>]>]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, readonly ["to reject with error satisfying"], z.ZodUnion<readonly [z.ZodString, z.ZodCustom<RegExp, RegExp>, z.ZodObject<{}, z.core.$loose>]>], (subject: PromiseLike<unknown>, param: string | RegExp | {
|
|
15
36
|
[x: string]: unknown;
|
|
16
|
-
}) => Promise<
|
|
37
|
+
}) => Promise<z.ZodError<unknown> | {
|
|
38
|
+
actual: string;
|
|
39
|
+
expect: string;
|
|
40
|
+
message: string;
|
|
41
|
+
} | undefined>, readonly [z.ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, import("../assertion-types.js").PhraseLiteralChoiceSlot<readonly ["to reject with error satisfying"]>, z.ZodUnion<readonly [z.ZodString, z.ZodCustom<RegExp, RegExp>, z.ZodObject<{}, z.core.$loose>]>]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, readonly ["to fulfill with value satisfying", "to resolve with value satisfying"], z.ZodUnion<readonly [z.ZodString, z.ZodCustom<RegExp, RegExp>, z.ZodObject<{}, z.core.$loose>]>], (promise: PromiseLike<unknown>, param: string | RegExp | {
|
|
17
42
|
[x: string]: unknown;
|
|
18
|
-
}) => Promise<
|
|
43
|
+
}) => Promise<z.ZodError<unknown> | {
|
|
19
44
|
actual: unknown;
|
|
20
45
|
expect: string;
|
|
21
46
|
message: string;
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
47
|
+
} | undefined>, readonly [z.ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, import("../assertion-types.js").PhraseLiteralChoiceSlot<readonly ["to fulfill with value satisfying", "to resolve with value satisfying"]>, z.ZodUnion<readonly [z.ZodString, z.ZodCustom<RegExp, RegExp>, z.ZodObject<{}, z.core.$loose>]>]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.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"], z.ZodUnion<readonly [z.ZodString, z.ZodCustom<RegExp, RegExp>, z.ZodObject<{}, z.core.$loose>]>], (subject: (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, param: string | RegExp | {
|
|
48
|
+
[x: string]: unknown;
|
|
49
|
+
}) => Promise<z.ZodError<unknown> | {
|
|
50
|
+
actual: string;
|
|
51
|
+
expect: string;
|
|
52
|
+
message: string;
|
|
53
|
+
} | undefined>, readonly [z.ZodCustom<(...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown>, import("../assertion-types.js").PhraseLiteralChoiceSlot<readonly ["to fulfill with value satisfying", "to resolve with value satisfying"]>, z.ZodUnion<readonly [z.ZodString, z.ZodCustom<RegExp, RegExp>, z.ZodObject<{}, z.core.$loose>]>]>];
|
|
54
|
+
export declare const AsyncAssertions: readonly [import("../assertion-types.js").AssertionFunctionAsync<readonly [z.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<{
|
|
55
|
+
actual: string;
|
|
56
|
+
expected: string;
|
|
57
|
+
message: string;
|
|
58
|
+
} | undefined>, readonly [z.ZodCustom<(...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown>, import("../assertion-types.js").PhraseLiteralChoiceSlot<readonly ["to resolve", "to fulfill"]>]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, readonly ["to resolve", "to fulfill"]], (subject: PromiseLike<unknown>) => Promise<{
|
|
59
|
+
actual: string;
|
|
60
|
+
expected: string;
|
|
61
|
+
message: string;
|
|
62
|
+
} | undefined>, readonly [z.ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, import("../assertion-types.js").PhraseLiteralChoiceSlot<readonly ["to resolve", "to fulfill"]>]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.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<{
|
|
63
|
+
actual: string;
|
|
64
|
+
expected: string;
|
|
65
|
+
message: string;
|
|
66
|
+
} | undefined>, readonly [z.ZodCustom<(...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown>, import("../assertion-types.js").PhraseLiteralSlot<"to reject">]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, "to reject"], (subject: PromiseLike<unknown>) => Promise<{
|
|
67
|
+
actual: string;
|
|
68
|
+
expected: string;
|
|
28
69
|
message: string;
|
|
29
|
-
|
|
30
|
-
}>, readonly [z.ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, import("../assertion-types.js").PhraseLiteralChoiceSlot<readonly ["to fulfill with value satisfying", "to resolve to value satisfying"]>, z.ZodUnion<readonly [z.ZodString, z.ZodCustom<RegExp, RegExp>, z.ZodObject<{}, z.core.$loose>]>]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.ZodCustom<(...args: any[]) => any, (...args: any[]) => any>, readonly ["to fulfill with value satisfying", "to resolve to value satisfying"], z.ZodUnion<readonly [z.ZodString, z.ZodCustom<RegExp, RegExp>, z.ZodObject<{}, z.core.$loose>]>], (subject: (...args: any[]) => any, param: string | RegExp | {
|
|
70
|
+
} | undefined>, readonly [z.ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, import("../assertion-types.js").PhraseLiteralSlot<"to reject">]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.ZodCustom<(...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to reject with a", "to reject with an"], z.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 [z.ZodCustom<(...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown>, import("../assertion-types.js").PhraseLiteralChoiceSlot<readonly ["to reject with a", "to reject with an"]>, z.ZodCustom<import("../../types.js").Constructor, import("../../types.js").Constructor>]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, readonly ["to reject with a", "to reject with an"], z.ZodCustom<import("../../types.js").Constructor, import("../../types.js").Constructor>], (subject: PromiseLike<unknown>, ctor: import("../../types.js").Constructor) => Promise<boolean>, readonly [z.ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, import("../assertion-types.js").PhraseLiteralChoiceSlot<readonly ["to reject with a", "to reject with an"]>, z.ZodCustom<import("../../types.js").Constructor, import("../../types.js").Constructor>]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.ZodCustom<(...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown>, readonly ["to reject with error satisfying"], z.ZodUnion<readonly [z.ZodString, z.ZodCustom<RegExp, RegExp>, z.ZodObject<{}, z.core.$loose>]>], (subject: (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, param: string | RegExp | {
|
|
31
71
|
[x: string]: unknown;
|
|
32
|
-
}) => Promise<
|
|
33
|
-
actual:
|
|
72
|
+
}) => Promise<z.ZodError<unknown> | {
|
|
73
|
+
actual: string;
|
|
74
|
+
expect: string;
|
|
75
|
+
message: string;
|
|
76
|
+
} | undefined>, readonly [z.ZodCustom<(...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown>, import("../assertion-types.js").PhraseLiteralChoiceSlot<readonly ["to reject with error satisfying"]>, z.ZodUnion<readonly [z.ZodString, z.ZodCustom<RegExp, RegExp>, z.ZodObject<{}, z.core.$loose>]>]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, readonly ["to reject with error satisfying"], z.ZodUnion<readonly [z.ZodString, z.ZodCustom<RegExp, RegExp>, z.ZodObject<{}, z.core.$loose>]>], (subject: PromiseLike<unknown>, param: string | RegExp | {
|
|
77
|
+
[x: string]: unknown;
|
|
78
|
+
}) => Promise<z.ZodError<unknown> | {
|
|
79
|
+
actual: string;
|
|
34
80
|
expect: string;
|
|
35
81
|
message: string;
|
|
36
|
-
|
|
37
|
-
|
|
82
|
+
} | undefined>, readonly [z.ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, import("../assertion-types.js").PhraseLiteralChoiceSlot<readonly ["to reject with error satisfying"]>, z.ZodUnion<readonly [z.ZodString, z.ZodCustom<RegExp, RegExp>, z.ZodObject<{}, z.core.$loose>]>]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, readonly ["to fulfill with value satisfying", "to resolve with value satisfying"], z.ZodUnion<readonly [z.ZodString, z.ZodCustom<RegExp, RegExp>, z.ZodObject<{}, z.core.$loose>]>], (promise: PromiseLike<unknown>, param: string | RegExp | {
|
|
83
|
+
[x: string]: unknown;
|
|
84
|
+
}) => Promise<z.ZodError<unknown> | {
|
|
38
85
|
actual: unknown;
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
86
|
+
expect: string;
|
|
87
|
+
message: string;
|
|
88
|
+
} | undefined>, readonly [z.ZodCustom<PromiseLike<unknown>, PromiseLike<unknown>>, import("../assertion-types.js").PhraseLiteralChoiceSlot<readonly ["to fulfill with value satisfying", "to resolve with value satisfying"]>, z.ZodUnion<readonly [z.ZodString, z.ZodCustom<RegExp, RegExp>, z.ZodObject<{}, z.core.$loose>]>]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.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"], z.ZodUnion<readonly [z.ZodString, z.ZodCustom<RegExp, RegExp>, z.ZodObject<{}, z.core.$loose>]>], (subject: (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, param: string | RegExp | {
|
|
89
|
+
[x: string]: unknown;
|
|
90
|
+
}) => Promise<z.ZodError<unknown> | {
|
|
91
|
+
actual: string;
|
|
92
|
+
expect: string;
|
|
93
|
+
message: string;
|
|
94
|
+
} | undefined>, readonly [z.ZodCustom<(...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown>, import("../assertion-types.js").PhraseLiteralChoiceSlot<readonly ["to fulfill with value satisfying", "to resolve with value satisfying"]>, z.ZodUnion<readonly [z.ZodString, z.ZodCustom<RegExp, RegExp>, z.ZodObject<{}, z.core.$loose>]>]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.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<{
|
|
95
|
+
actual: string;
|
|
96
|
+
expected: string;
|
|
97
|
+
message: string;
|
|
98
|
+
} | undefined>, readonly [z.ZodCustom<(...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown>, import("../assertion-types.js").PhraseLiteralChoiceSlot<readonly ["to eventually call callback", "to eventually invoke callback"]>]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.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<{
|
|
99
|
+
actual: string;
|
|
100
|
+
expected: string;
|
|
101
|
+
message: string;
|
|
102
|
+
} | undefined>, readonly [z.ZodCustom<(...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown>, import("../assertion-types.js").PhraseLiteralChoiceSlot<readonly ["to eventually call nodeback", "to eventually invoke nodeback"]>]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.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"], z.ZodUnknown], (subject: (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, param: unknown) => Promise<z.ZodError<any> | {
|
|
103
|
+
actual: string;
|
|
104
|
+
expected: string;
|
|
105
|
+
message: string;
|
|
106
|
+
} | undefined>, readonly [z.ZodCustom<(...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown>, import("../assertion-types.js").PhraseLiteralChoiceSlot<readonly ["to eventually call callback with", "to eventually invoke callback with"]>, z.ZodUnknown]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.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"], z.ZodUnknown], (subject: (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, expected: unknown) => Promise<boolean | {
|
|
107
|
+
actual: string;
|
|
108
|
+
expected: string;
|
|
109
|
+
message: string;
|
|
110
|
+
}>, readonly [z.ZodCustom<(...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown>, import("../assertion-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"]>, z.ZodUnknown]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.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"], z.ZodUnknown], (subject: (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, param: unknown) => Promise<z.ZodError<any> | {
|
|
111
|
+
actual: string;
|
|
112
|
+
expected: string;
|
|
113
|
+
message: string;
|
|
114
|
+
} | undefined>, readonly [z.ZodCustom<(...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown>, import("../assertion-types.js").PhraseLiteralChoiceSlot<readonly ["to eventually call nodeback with", "to eventually invoke nodeback with"]>, z.ZodUnknown]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.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"], z.ZodUnknown], (subject: (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, expected: unknown) => Promise<boolean | {
|
|
115
|
+
actual: string;
|
|
116
|
+
expected: string;
|
|
117
|
+
message: string;
|
|
118
|
+
}>, readonly [z.ZodCustom<(...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown>, import("../assertion-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"]>, z.ZodUnknown]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.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<{
|
|
119
|
+
actual: string;
|
|
120
|
+
expected: string;
|
|
121
|
+
message: string;
|
|
122
|
+
} | undefined>, readonly [z.ZodCustom<(...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown>, import("../assertion-types.js").PhraseLiteralChoiceSlot<readonly ["to eventually call nodeback with error", "to eventually invoke nodeback with error"]>]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.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"], z.ZodCustom<import("../../types.js").Constructor, import("../../types.js").Constructor>], (subject: (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, ctor: import("../../types.js").Constructor) => Promise<{
|
|
123
|
+
actual: string;
|
|
124
|
+
expected: string;
|
|
125
|
+
message: string;
|
|
126
|
+
} | undefined>, readonly [z.ZodCustom<(...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown>, import("../assertion-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"]>, z.ZodCustom<import("../../types.js").Constructor, import("../../types.js").Constructor>]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.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"], z.ZodUnion<readonly [z.ZodString, z.ZodCustom<RegExp, RegExp>, z.ZodObject<{}, z.core.$loose>]>], (subject: (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, param: string | RegExp | {
|
|
127
|
+
[x: string]: unknown;
|
|
128
|
+
}) => Promise<z.ZodError<unknown> | {
|
|
129
|
+
actual: string;
|
|
130
|
+
expected: string;
|
|
131
|
+
message: string;
|
|
132
|
+
} | undefined>, readonly [z.ZodCustom<(...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown>, import("../assertion-types.js").PhraseLiteralChoiceSlot<readonly ["to eventually call nodeback with error", "to eventually invoke nodeback with error"]>, z.ZodUnion<readonly [z.ZodString, z.ZodCustom<RegExp, RegExp>, z.ZodObject<{}, z.core.$loose>]>]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.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"], z.ZodUnion<readonly [z.ZodString, z.ZodCustom<RegExp, RegExp>, z.ZodObject<{}, z.core.$loose>]>], (subject: (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, param: string | RegExp | {
|
|
133
|
+
[x: string]: unknown;
|
|
134
|
+
}) => Promise<z.ZodError<any> | {
|
|
135
|
+
actual: string;
|
|
136
|
+
expected: string;
|
|
137
|
+
message: string;
|
|
138
|
+
} | undefined>, readonly [z.ZodCustom<(...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown>, import("../assertion-types.js").PhraseLiteralChoiceSlot<readonly ["to eventually call callback with value satisfying", "to eventually invoke callback with value satisfying"]>, z.ZodUnion<readonly [z.ZodString, z.ZodCustom<RegExp, RegExp>, z.ZodObject<{}, z.core.$loose>]>]>, import("../assertion-types.js").AssertionFunctionAsync<readonly [z.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"], z.ZodUnion<readonly [z.ZodString, z.ZodCustom<RegExp, RegExp>, z.ZodObject<{}, z.core.$loose>]>], (subject: (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, param: string | RegExp | {
|
|
139
|
+
[x: string]: unknown;
|
|
140
|
+
}) => Promise<z.ZodError<any> | {
|
|
141
|
+
actual: string;
|
|
142
|
+
expected: string;
|
|
42
143
|
message: string;
|
|
43
|
-
|
|
44
|
-
|
|
144
|
+
} | undefined>, readonly [z.ZodCustom<(...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown, (...args: import("../../types.js").MutableOrReadonly<unknown[]>) => unknown>, import("../assertion-types.js").PhraseLiteralChoiceSlot<readonly ["to eventually call nodeback with value satisfying", "to eventually invoke nodeback with value satisfying"]>, z.ZodUnion<readonly [z.ZodString, z.ZodCustom<RegExp, RegExp>, z.ZodObject<{}, z.core.$loose>]>]>];
|
|
145
|
+
export { CallbackAsyncAssertions };
|
|
45
146
|
//# sourceMappingURL=async.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"async.d.ts","sourceRoot":"","sources":["../../../../src/assertion/impl/async.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAGH,OAAO,EAAE,CAAC,EAAE,MAAM,QAAQ,CAAC;
|
|
1
|
+
{"version":3,"file":"async.d.ts","sourceRoot":"","sources":["../../../../src/assertion/impl/async.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAGH,OAAO,EAAE,CAAC,EAAE,MAAM,QAAQ,CAAC;AAa3B,OAAO,EAAE,uBAAuB,EAAE,MAAM,eAAe,CAAC;AAkBxD,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;+aAiRpB,CAAC;AAEX,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;mdAGlB,CAAC;AAEX,OAAO,EAAE,uBAAuB,EAAE,CAAC"}
|
|
@@ -10,13 +10,15 @@
|
|
|
10
10
|
* @packageDocumentation
|
|
11
11
|
*/
|
|
12
12
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
-
exports.AsyncAssertions = void 0;
|
|
13
|
+
exports.CallbackAsyncAssertions = exports.AsyncAssertions = exports.PromiseAssertions = void 0;
|
|
14
14
|
const node_util_1 = require("node:util");
|
|
15
15
|
const v4_1 = require("zod/v4");
|
|
16
16
|
const guards_js_1 = require("../../guards.js");
|
|
17
17
|
const schema_js_1 = require("../../schema.js");
|
|
18
|
-
const
|
|
18
|
+
const value_to_schema_js_1 = require("../../value-to-schema.js");
|
|
19
19
|
const create_js_1 = require("../create.js");
|
|
20
|
+
const callback_js_1 = require("./callback.js");
|
|
21
|
+
Object.defineProperty(exports, "CallbackAsyncAssertions", { enumerable: true, get: function () { return callback_js_1.CallbackAsyncAssertions; } });
|
|
20
22
|
const trapAsyncFnError = async (fn) => {
|
|
21
23
|
try {
|
|
22
24
|
await fn();
|
|
@@ -33,45 +35,53 @@ const trapPromiseError = async (promise) => {
|
|
|
33
35
|
return err;
|
|
34
36
|
}
|
|
35
37
|
};
|
|
36
|
-
exports.
|
|
38
|
+
exports.PromiseAssertions = [
|
|
37
39
|
(0, create_js_1.createAsyncAssertion)([schema_js_1.FunctionSchema, ['to resolve', 'to fulfill']], async (subject) => {
|
|
38
40
|
try {
|
|
39
41
|
await subject();
|
|
40
|
-
return true;
|
|
41
42
|
}
|
|
42
43
|
catch {
|
|
43
|
-
return
|
|
44
|
+
return {
|
|
45
|
+
actual: 'function rejected',
|
|
46
|
+
expected: 'function to fulfill',
|
|
47
|
+
message: 'Expected function to fulfill, but it rejected instead',
|
|
48
|
+
};
|
|
44
49
|
}
|
|
45
50
|
}),
|
|
46
51
|
(0, create_js_1.createAsyncAssertion)([schema_js_1.WrappedPromiseLikeSchema, ['to resolve', 'to fulfill']], async (subject) => {
|
|
47
52
|
try {
|
|
48
53
|
await subject;
|
|
49
|
-
return true;
|
|
50
54
|
}
|
|
51
55
|
catch {
|
|
52
|
-
return
|
|
56
|
+
return {
|
|
57
|
+
actual: 'promise rejected',
|
|
58
|
+
expected: 'promise to not reject',
|
|
59
|
+
message: 'Expected promise to fulfill, but it rejected instead',
|
|
60
|
+
};
|
|
53
61
|
}
|
|
54
62
|
}),
|
|
55
63
|
// Non-parameterized "to reject" assertions
|
|
56
64
|
(0, create_js_1.createAsyncAssertion)([schema_js_1.FunctionSchema, 'to reject'], async (subject) => {
|
|
57
|
-
let rejected = false;
|
|
58
65
|
try {
|
|
59
66
|
await subject();
|
|
67
|
+
return {
|
|
68
|
+
actual: 'function fulfilled',
|
|
69
|
+
expected: 'function to reject',
|
|
70
|
+
message: 'Expected function to reject, but it fulfilled instead',
|
|
71
|
+
};
|
|
60
72
|
}
|
|
61
|
-
catch {
|
|
62
|
-
rejected = true;
|
|
63
|
-
}
|
|
64
|
-
return rejected;
|
|
73
|
+
catch { }
|
|
65
74
|
}),
|
|
66
75
|
(0, create_js_1.createAsyncAssertion)([schema_js_1.WrappedPromiseLikeSchema, 'to reject'], async (subject) => {
|
|
67
|
-
let rejected = false;
|
|
68
76
|
try {
|
|
69
77
|
await subject;
|
|
78
|
+
return {
|
|
79
|
+
actual: 'function fulfilled',
|
|
80
|
+
expected: 'function to reject',
|
|
81
|
+
message: 'Expected function to reject, but it fulfilled instead',
|
|
82
|
+
};
|
|
70
83
|
}
|
|
71
|
-
catch {
|
|
72
|
-
rejected = true;
|
|
73
|
-
}
|
|
74
|
-
return rejected;
|
|
84
|
+
catch { }
|
|
75
85
|
}),
|
|
76
86
|
// Parameterized "to reject" with class constructor
|
|
77
87
|
(0, create_js_1.createAsyncAssertion)([schema_js_1.FunctionSchema, ['to reject with a', 'to reject with an'], schema_js_1.ClassSchema], async (subject, ctor) => {
|
|
@@ -95,71 +105,89 @@ exports.AsyncAssertions = [
|
|
|
95
105
|
// Parameterized "to reject" with string, RegExp, or object patterns
|
|
96
106
|
(0, create_js_1.createAsyncAssertion)([
|
|
97
107
|
schema_js_1.FunctionSchema,
|
|
98
|
-
['to reject with'],
|
|
108
|
+
['to reject with error satisfying'],
|
|
99
109
|
v4_1.z.union([v4_1.z.string(), v4_1.z.instanceof(RegExp), v4_1.z.looseObject({})]),
|
|
100
110
|
], async (subject, param) => {
|
|
101
111
|
const error = await trapAsyncFnError(subject);
|
|
102
112
|
if (!error) {
|
|
103
|
-
return
|
|
113
|
+
return {
|
|
114
|
+
actual: 'function fulfilled',
|
|
115
|
+
expect: 'function to reject',
|
|
116
|
+
message: 'Expected function to reject, but it fulfilled instead',
|
|
117
|
+
};
|
|
104
118
|
}
|
|
119
|
+
let schema;
|
|
120
|
+
// TODO: can valueToSchema handle the first two conditional branches?
|
|
105
121
|
if ((0, guards_js_1.isString)(param)) {
|
|
106
|
-
|
|
107
|
-
.
|
|
122
|
+
schema = v4_1.z
|
|
123
|
+
.looseObject({
|
|
108
124
|
message: v4_1.z.coerce.string().pipe(v4_1.z.literal(param)),
|
|
109
125
|
})
|
|
110
|
-
.or(v4_1.z.coerce.string().pipe(v4_1.z.literal(param)))
|
|
111
|
-
.safeParse(error).success;
|
|
126
|
+
.or(v4_1.z.coerce.string().pipe(v4_1.z.literal(param)));
|
|
112
127
|
}
|
|
113
128
|
else if ((0, guards_js_1.isA)(param, RegExp)) {
|
|
114
|
-
|
|
115
|
-
.
|
|
129
|
+
schema = v4_1.z
|
|
130
|
+
.looseObject({
|
|
116
131
|
message: v4_1.z.coerce.string().regex(param),
|
|
117
132
|
})
|
|
118
|
-
.or(v4_1.z.coerce.string().regex(param))
|
|
119
|
-
.safeParse(error).success;
|
|
133
|
+
.or(v4_1.z.coerce.string().regex(param));
|
|
120
134
|
}
|
|
121
135
|
else if ((0, guards_js_1.isNonNullObject)(param)) {
|
|
122
|
-
|
|
136
|
+
schema = (0, value_to_schema_js_1.valueToSchema)(param, value_to_schema_js_1.valueToSchemaOptionsForSatisfies);
|
|
137
|
+
}
|
|
138
|
+
/* c8 ignore next 5 */
|
|
139
|
+
if (!schema) {
|
|
140
|
+
throw new TypeError(`Invalid parameter schema: ${(0, node_util_1.inspect)(param, { depth: 2 })}`);
|
|
123
141
|
}
|
|
124
|
-
|
|
125
|
-
|
|
142
|
+
const result = schema.safeParse(error);
|
|
143
|
+
if (!result.success) {
|
|
144
|
+
return result.error;
|
|
126
145
|
}
|
|
127
146
|
}),
|
|
128
147
|
(0, create_js_1.createAsyncAssertion)([
|
|
129
148
|
schema_js_1.WrappedPromiseLikeSchema,
|
|
130
|
-
['to reject with'],
|
|
149
|
+
['to reject with error satisfying'],
|
|
131
150
|
v4_1.z.union([v4_1.z.string(), v4_1.z.instanceof(RegExp), v4_1.z.looseObject({})]),
|
|
132
151
|
], async (subject, param) => {
|
|
133
152
|
const error = await trapPromiseError(subject);
|
|
134
153
|
if (!error) {
|
|
135
|
-
return
|
|
154
|
+
return {
|
|
155
|
+
actual: 'promise fulfilled',
|
|
156
|
+
expect: 'promise to reject',
|
|
157
|
+
message: 'Expected promise to reject, but it fulfilled instead',
|
|
158
|
+
};
|
|
136
159
|
}
|
|
160
|
+
let schema;
|
|
161
|
+
// TODO: can valueToSchema handle the first two conditional branches?
|
|
137
162
|
if ((0, guards_js_1.isString)(param)) {
|
|
138
|
-
|
|
139
|
-
.
|
|
163
|
+
schema = v4_1.z
|
|
164
|
+
.looseObject({
|
|
140
165
|
message: v4_1.z.coerce.string().pipe(v4_1.z.literal(param)),
|
|
141
166
|
})
|
|
142
|
-
.or(v4_1.z.coerce.string().pipe(v4_1.z.literal(param)))
|
|
143
|
-
.safeParse(error).success;
|
|
167
|
+
.or(v4_1.z.coerce.string().pipe(v4_1.z.literal(param)));
|
|
144
168
|
}
|
|
145
169
|
else if ((0, guards_js_1.isA)(param, RegExp)) {
|
|
146
|
-
|
|
147
|
-
.
|
|
170
|
+
schema = v4_1.z
|
|
171
|
+
.looseObject({
|
|
148
172
|
message: v4_1.z.coerce.string().regex(param),
|
|
149
173
|
})
|
|
150
|
-
.or(v4_1.z.coerce.string().regex(param))
|
|
151
|
-
.safeParse(error).success;
|
|
174
|
+
.or(v4_1.z.coerce.string().regex(param));
|
|
152
175
|
}
|
|
153
176
|
else if ((0, guards_js_1.isNonNullObject)(param)) {
|
|
154
|
-
|
|
177
|
+
schema = (0, value_to_schema_js_1.valueToSchema)(param, value_to_schema_js_1.valueToSchemaOptionsForSatisfies);
|
|
178
|
+
}
|
|
179
|
+
/* c8 ignore next 5 */
|
|
180
|
+
if (!schema) {
|
|
181
|
+
throw new TypeError(`Invalid parameter schema: ${(0, node_util_1.inspect)(param, { depth: 2 })}`);
|
|
155
182
|
}
|
|
156
|
-
|
|
157
|
-
|
|
183
|
+
const result = schema.safeParse(error);
|
|
184
|
+
if (!result.success) {
|
|
185
|
+
return result.error;
|
|
158
186
|
}
|
|
159
187
|
}),
|
|
160
188
|
(0, create_js_1.createAsyncAssertion)([
|
|
161
189
|
schema_js_1.WrappedPromiseLikeSchema,
|
|
162
|
-
['to fulfill with value satisfying', 'to resolve
|
|
190
|
+
['to fulfill with value satisfying', 'to resolve with value satisfying'],
|
|
163
191
|
v4_1.z.union([v4_1.z.string(), v4_1.z.instanceof(RegExp), v4_1.z.looseObject({})]),
|
|
164
192
|
], async (promise, param) => {
|
|
165
193
|
let value;
|
|
@@ -173,41 +201,37 @@ exports.AsyncAssertions = [
|
|
|
173
201
|
message: `Expected promise to not reject, but it rejected with ${(0, node_util_1.inspect)(err)}`,
|
|
174
202
|
};
|
|
175
203
|
}
|
|
204
|
+
let schema;
|
|
205
|
+
// TODO: can valueToSchema handle the first two conditional branches?
|
|
176
206
|
if ((0, guards_js_1.isString)(param)) {
|
|
177
|
-
|
|
178
|
-
.
|
|
207
|
+
schema = v4_1.z
|
|
208
|
+
.looseObject({
|
|
179
209
|
message: v4_1.z.coerce.string().pipe(v4_1.z.literal(param)),
|
|
180
210
|
})
|
|
181
|
-
.or(v4_1.z.coerce.string().pipe(v4_1.z.literal(param)))
|
|
182
|
-
.safeParse(value).success;
|
|
211
|
+
.or(v4_1.z.coerce.string().pipe(v4_1.z.literal(param)));
|
|
183
212
|
}
|
|
184
213
|
else if ((0, guards_js_1.isA)(param, RegExp)) {
|
|
185
|
-
|
|
186
|
-
.
|
|
214
|
+
schema = v4_1.z
|
|
215
|
+
.looseObject({
|
|
187
216
|
message: v4_1.z.coerce.string().regex(param),
|
|
188
217
|
})
|
|
189
|
-
.or(v4_1.z.coerce.string().regex(param))
|
|
190
|
-
.safeParse(value).success;
|
|
218
|
+
.or(v4_1.z.coerce.string().regex(param));
|
|
191
219
|
}
|
|
192
220
|
else if ((0, guards_js_1.isNonNullObject)(param)) {
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
return true;
|
|
203
|
-
}
|
|
204
|
-
else {
|
|
205
|
-
throw new TypeError(`Invalid parameter schema: ${(0, node_util_1.inspect)(param)}`);
|
|
221
|
+
schema = (0, value_to_schema_js_1.valueToSchema)(param, value_to_schema_js_1.valueToSchemaOptionsForSatisfies);
|
|
222
|
+
}
|
|
223
|
+
/* c8 ignore next 5 */
|
|
224
|
+
if (!schema) {
|
|
225
|
+
throw new TypeError(`Invalid parameter schema: ${(0, node_util_1.inspect)(param, { depth: 2 })}`);
|
|
226
|
+
}
|
|
227
|
+
const result = schema.safeParse(value);
|
|
228
|
+
if (!result.success) {
|
|
229
|
+
return result.error;
|
|
206
230
|
}
|
|
207
231
|
}),
|
|
208
232
|
(0, create_js_1.createAsyncAssertion)([
|
|
209
233
|
schema_js_1.FunctionSchema,
|
|
210
|
-
['to fulfill with value satisfying', 'to resolve
|
|
234
|
+
['to fulfill with value satisfying', 'to resolve with value satisfying'],
|
|
211
235
|
v4_1.z.union([v4_1.z.string(), v4_1.z.instanceof(RegExp), v4_1.z.looseObject({})]),
|
|
212
236
|
], async (subject, param) => {
|
|
213
237
|
let value;
|
|
@@ -216,42 +240,42 @@ exports.AsyncAssertions = [
|
|
|
216
240
|
}
|
|
217
241
|
catch (err) {
|
|
218
242
|
return {
|
|
219
|
-
actual:
|
|
220
|
-
expect: 'function to
|
|
221
|
-
message: `Expected function to
|
|
243
|
+
actual: 'function rejected',
|
|
244
|
+
expect: 'function to fulfill',
|
|
245
|
+
message: `Expected function to fulfill, but it rejected with ${(0, node_util_1.inspect)(err)}`,
|
|
222
246
|
};
|
|
223
247
|
}
|
|
248
|
+
let schema;
|
|
249
|
+
// TODO: can valueToSchema handle the first two conditional branches?
|
|
224
250
|
if ((0, guards_js_1.isString)(param)) {
|
|
225
|
-
|
|
226
|
-
.
|
|
251
|
+
schema = v4_1.z
|
|
252
|
+
.looseObject({
|
|
227
253
|
message: v4_1.z.coerce.string().pipe(v4_1.z.literal(param)),
|
|
228
254
|
})
|
|
229
|
-
.or(v4_1.z.coerce.string().pipe(v4_1.z.literal(param)))
|
|
230
|
-
.safeParse(value).success;
|
|
255
|
+
.or(v4_1.z.coerce.string().pipe(v4_1.z.literal(param)));
|
|
231
256
|
}
|
|
232
257
|
else if ((0, guards_js_1.isA)(param, RegExp)) {
|
|
233
|
-
|
|
234
|
-
.
|
|
258
|
+
schema = v4_1.z
|
|
259
|
+
.looseObject({
|
|
235
260
|
message: v4_1.z.coerce.string().regex(param),
|
|
236
261
|
})
|
|
237
|
-
.or(v4_1.z.coerce.string().regex(param))
|
|
238
|
-
.safeParse(value).success;
|
|
262
|
+
.or(v4_1.z.coerce.string().regex(param));
|
|
239
263
|
}
|
|
240
264
|
else if ((0, guards_js_1.isNonNullObject)(param)) {
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
return true;
|
|
251
|
-
}
|
|
252
|
-
else {
|
|
253
|
-
throw new TypeError(`Invalid parameter schema: ${(0, node_util_1.inspect)(param)}`);
|
|
265
|
+
schema = (0, value_to_schema_js_1.valueToSchema)(param, value_to_schema_js_1.valueToSchemaOptionsForSatisfies);
|
|
266
|
+
}
|
|
267
|
+
/* c8 ignore next 5 */
|
|
268
|
+
if (!schema) {
|
|
269
|
+
throw new TypeError(`Invalid parameter schema: ${(0, node_util_1.inspect)(param, { depth: 2 })}`);
|
|
270
|
+
}
|
|
271
|
+
const result = schema.safeParse(value);
|
|
272
|
+
if (!result.success) {
|
|
273
|
+
return result.error;
|
|
254
274
|
}
|
|
255
275
|
}),
|
|
256
276
|
];
|
|
277
|
+
exports.AsyncAssertions = [
|
|
278
|
+
...exports.PromiseAssertions,
|
|
279
|
+
...callback_js_1.CallbackAsyncAssertions,
|
|
280
|
+
];
|
|
257
281
|
//# sourceMappingURL=async.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"async.js","sourceRoot":"","sources":["../../../../src/assertion/impl/async.ts"],"names":[],"mappings":";AAAA;;;;;;;;;GASG;;;AAEH,yCAAoC;AACpC,+BAA2B;AAE3B,+CAAiE;AACjE,+CAIyB;AACzB,
|
|
1
|
+
{"version":3,"file":"async.js","sourceRoot":"","sources":["../../../../src/assertion/impl/async.ts"],"names":[],"mappings":";AAAA;;;;;;;;;GASG;;;AAEH,yCAAoC;AACpC,+BAA2B;AAE3B,+CAAiE;AACjE,+CAIyB;AACzB,iEAGkC;AAClC,4CAAoD;AACpD,+CAAwD;AA0S/C,wGA1SA,qCAAuB,OA0SA;AAxShC,MAAM,gBAAgB,GAAG,KAAK,EAAE,EAAiB,EAAE,EAAE;IACnD,IAAI,CAAC;QACH,MAAM,EAAE,EAAE,CAAC;IACb,CAAC;IAAC,OAAO,GAAG,EAAE,CAAC;QACb,OAAO,GAAG,CAAC;IACb,CAAC;AACH,CAAC,CAAC;AAEF,MAAM,gBAAgB,GAAG,KAAK,EAAE,OAA6B,EAAE,EAAE;IAC/D,IAAI,CAAC;QACH,MAAM,OAAO,CAAC;IAChB,CAAC;IAAC,OAAO,GAAG,EAAE,CAAC;QACb,OAAO,GAAG,CAAC;IACb,CAAC;AACH,CAAC,CAAC;AAEW,QAAA,iBAAiB,GAAG;IAC/B,IAAA,gCAAoB,EAClB,CAAC,0BAAc,EAAE,CAAC,YAAY,EAAE,YAAY,CAAC,CAAC,EAC9C,KAAK,EAAE,OAAO,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