@overkill-dev/doubles 0.0.2 → 0.0.3
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/assert/assertion-extension.d.ts +4 -4
- package/assert/assertion-extension.js +3 -3
- package/assert/assertion-extension.js.map +1 -1
- package/doubles/double-behavior.js +1 -1
- package/doubles/double-usage-argument-assertion.js +1 -1
- package/doubles/double-usage-contract.d.ts +2 -2
- package/package.json +4 -2
- package/sbom.cdx.json +26 -6
- package/assertion-protocol/assertion-evaluation.d.ts +0 -13
- package/assertion-protocol/assertion-evaluation.d.ts.map +0 -1
- package/assertion-protocol/assertion-node-shape.d.ts +0 -71
- package/assertion-protocol/assertion-node-shape.d.ts.map +0 -1
- package/assertion-protocol/assertion-node.d.ts +0 -97
- package/assertion-protocol/assertion-node.d.ts.map +0 -1
- package/assertion-protocol/assertion-reference.d.ts +0 -73
- package/assertion-protocol/assertion-reference.d.ts.map +0 -1
- package/assertion-protocol/assertion-reference.js +0 -49
- package/assertion-protocol/assertion-reference.js.map +0 -1
- package/assertion-protocol/assertions/boolean.d.ts +0 -11
- package/assertion-protocol/assertions/boolean.d.ts.map +0 -1
- package/assertion-protocol/assertions/collection.d.ts +0 -22
- package/assertion-protocol/assertions/collection.d.ts.map +0 -1
- package/assertion-protocol/assertions/equality.d.ts +0 -17
- package/assertion-protocol/assertions/equality.d.ts.map +0 -1
- package/assertion-protocol/assertions/fail.d.ts +0 -13
- package/assertion-protocol/assertions/fail.d.ts.map +0 -1
- package/assertion-protocol/assertions/numeric.d.ts +0 -29
- package/assertion-protocol/assertions/numeric.d.ts.map +0 -1
- package/assertion-protocol/assertions/partial.d.ts +0 -14
- package/assertion-protocol/assertions/partial.d.ts.map +0 -1
- package/assertion-protocol/assertions/presence.d.ts +0 -17
- package/assertion-protocol/assertions/presence.d.ts.map +0 -1
- package/assertion-protocol/assertions/string.d.ts +0 -28
- package/assertion-protocol/assertions/string.d.ts.map +0 -1
- package/assertion-protocol/assertions/type-shape.d.ts +0 -42
- package/assertion-protocol/assertions/type-shape.d.ts.map +0 -1
- package/assertion-protocol/thrown-error-record.d.ts +0 -8
- package/assertion-protocol/thrown-error-record.d.ts.map +0 -1
- package/assertion-protocol/thrown-error-record.js +0 -17
- package/assertion-protocol/thrown-error-record.js.map +0 -1
- package/assertion-protocol/thrown-matcher.d.ts +0 -51
- package/assertion-protocol/thrown-matcher.d.ts.map +0 -1
- package/assertion-protocol/thrown-matcher.js +0 -186
- package/assertion-protocol/thrown-matcher.js.map +0 -1
- package/compare/comparison-result.d.ts +0 -25
- package/compare/comparison-result.d.ts.map +0 -1
- package/compare/comparison-state.d.ts +0 -7
- package/compare/comparison-state.d.ts.map +0 -1
- package/compare/comparison-state.js +0 -20
- package/compare/comparison-state.js.map +0 -1
- package/compare/comparison.d.ts +0 -12
- package/compare/comparison.d.ts.map +0 -1
- package/compare/raw-comparison.d.ts +0 -24
- package/compare/raw-comparison.d.ts.map +0 -1
- package/compare/raw-comparison.js +0 -285
- package/compare/raw-comparison.js.map +0 -1
- package/compare/serialized-value-shape.d.ts +0 -143
- package/compare/serialized-value-shape.d.ts.map +0 -1
- package/compare/serialized-value.d.ts +0 -11
- package/compare/serialized-value.d.ts.map +0 -1
- package/compare/value-classification.d.ts +0 -26
- package/compare/value-classification.d.ts.map +0 -1
- package/compare/value-classification.js +0 -110
- package/compare/value-classification.js.map +0 -1
- package/diff/diff-shape.d.ts +0 -117
- package/diff/diff-shape.d.ts.map +0 -1
- package/doubles/disposal-symbol.d.ts +0 -3
- package/doubles/disposal-symbol.d.ts.map +0 -1
- package/doubles/double-chronology.d.ts +0 -21
- package/doubles/double-chronology.d.ts.map +0 -1
- package/doubles/double-history-api.d.ts +0 -33
- package/doubles/double-history-api.d.ts.map +0 -1
- package/doubles/double-runtime.d.ts +0 -9
- package/doubles/double-runtime.d.ts.map +0 -1
- package/doubles/double-usage-argument-assertion.d.ts +0 -27
- package/doubles/double-usage-argument-assertion.d.ts.map +0 -1
- package/doubles/double-usage-count-assertion.d.ts +0 -6
- package/doubles/double-usage-count-assertion.d.ts.map +0 -1
- package/doubles/double-usage-disposal-assertion.d.ts +0 -7
- package/doubles/double-usage-disposal-assertion.d.ts.map +0 -1
- package/doubles/double-usage-inspection.d.ts +0 -22
- package/doubles/double-usage-inspection.d.ts.map +0 -1
- package/doubles/double-usage-iterator-assertion.d.ts +0 -7
- package/doubles/double-usage-iterator-assertion.d.ts.map +0 -1
- package/doubles/double-usage-order-assertion.d.ts +0 -3
- package/doubles/double-usage-order-assertion.d.ts.map +0 -1
- package/doubles/protocol-double-metadata.d.ts +0 -15
- package/doubles/protocol-double-metadata.d.ts.map +0 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { type CompositeAssertionGroup, type CompositeAssertionReference, type CompositeAssertionSummaryContext, type AssertCompositeAssertionReturn, type NarrowingCompositeAssertionReference } from '
|
|
2
|
-
import type { BuiltInAssertAssertionNode, CompositeAssertionChildNode, ForeignAssertionNode } from '
|
|
3
|
-
import type { AssertionSource, DeepComparable, InstanceConstructor, NonEmptyReadonlyArray, ResolvableSourceLocation } from '
|
|
4
|
-
import { type SynchronousCallback, type ThrownMatcher } from '
|
|
1
|
+
import { type CompositeAssertionGroup, type CompositeAssertionReference, type CompositeAssertionSummaryContext, type AssertCompositeAssertionReturn, type NarrowingCompositeAssertionReference } from '@overkill-dev/engine/packages/engine/assertion-protocol.entry-point.js';
|
|
2
|
+
import type { BuiltInAssertAssertionNode, CompositeAssertionChildNode, ForeignAssertionNode } from '@overkill-dev/engine/assertion-protocol/assertion-node.js';
|
|
3
|
+
import type { AssertionSource, DeepComparable, InstanceConstructor, NonEmptyReadonlyArray, ResolvableSourceLocation } from '@overkill-dev/engine/assertion-protocol/assertion-node-shape.d.ts';
|
|
4
|
+
import { type SynchronousCallback, type ThrownMatcher } from '@overkill-dev/engine/packages/engine/assertion-protocol.entry-point.js';
|
|
5
5
|
type GroupItem<Source extends AssertionSource> = CompositeAssertionChildNode<Source> | CompositeAssertionGroup<Source>;
|
|
6
6
|
type CompositeAssertionSummaryFormatter<Arguments extends readonly unknown[]> = (context: CompositeAssertionSummaryContext, ...parameters: Arguments) => string;
|
|
7
7
|
type NarrowingCompositeAssertionSummaryFormatter<Actual, Arguments extends readonly unknown[]> = (context: CompositeAssertionSummaryContext, actual: Actual, ...parameters: Arguments) => string;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { createAssertionReferenceRecord, createCompositeAssertionGroup, isCompositeAssertionGroup } from "
|
|
2
|
-
import { createThrownErrorRecord } from "
|
|
3
|
-
import { thrownMatcherChildren } from "
|
|
1
|
+
import { createAssertionReferenceRecord, createCompositeAssertionGroup, isCompositeAssertionGroup } from "@overkill-dev/engine/packages/engine/assertion-protocol.entry-point.js";
|
|
2
|
+
import { createThrownErrorRecord } from "@overkill-dev/engine/packages/engine/assertion-protocol.entry-point.js";
|
|
3
|
+
import { thrownMatcherChildren } from "@overkill-dev/engine/packages/engine/assertion-protocol.entry-point.js";
|
|
4
4
|
function createForeignAssertionNode(input) {
|
|
5
5
|
return {
|
|
6
6
|
check: 'foreign',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"assertion-extension.js","sourceRoot":"","sources":["../../../../source/assert/assertion-extension.ts"],"names":[],"mappings":"AAAA,OAAO,EACH,8BAA8B,EAC9B,6BAA6B,EAC7B,yBAAyB,EAM5B,MAAM,8CAA8C;
|
|
1
|
+
{"version":3,"file":"assertion-extension.js","sourceRoot":"","sources":["../../../../source/assert/assertion-extension.ts"],"names":[],"mappings":"AAAA,OAAO,EACH,8BAA8B,EAC9B,6BAA6B,EAC7B,yBAAyB,EAM5B,MAAM,8CAA8C,CAAC;AAatD,OAAO,EAAE,uBAAuB,EAAE,MAAM,8CAA8C,CAAC;AACvF,OAAO,EAGH,qBAAqB,EACxB,MAAM,yCAAyC,CAAC;AA6GjD,SAAS,0BAA0B,CAC/B,KAAwC;IAExC,OAAO;QACH,KAAK,EA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AwB,CAGtC,UAA2D;IACzD,OAAO,8BAA8B,CAAC;QAClC,aAAa,EAAE,UAAU,CAAC,aAAa,IAAI,IAAI;QAC/C,IAAI,EAAE,WAAW;QACjB,IAAI,EAAE,UAAU,CAAC,IAAI;QACrB,GAAG,CAAC,KAAK;YACL,OAAO,UAAU,CAAC,MAAM,CACpB,2BAA2B,CAAC,KAAK,CAAC,MAAM,EAAE,KAAK,CAAC,OAAO,EAAE,KAAK,CAAC,QAAQ,CAAC,EACxE,GAAG,KAAK,CAAC,UAAU,CACtB,CAAC;QACN,CAAC;KACJ,CAAC,CAAC;AACP,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { comparePartially } from "
|
|
1
|
+
import { comparePartially } from "@overkill-dev/engine/compare/raw-comparison.js";
|
|
2
2
|
const unanswered = { answered: false };
|
|
3
3
|
export function isUnknownFunction(value) {
|
|
4
4
|
return typeof value === 'function';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { defineCompositeAssertion } from "../assert/assertion-extension.js";
|
|
2
|
-
import { compareExactly, comparePartially } from "
|
|
2
|
+
import { compareExactly, comparePartially } from "@overkill-dev/engine/compare/raw-comparison.js";
|
|
3
3
|
import { groupChildren, modeNoun } from "./double-usage-contract.js";
|
|
4
4
|
import { inspectedDouble, recordsFor, validNonNegativeInteger } from "./double-usage-inspection.js";
|
|
5
5
|
function partialArgumentsMatch(actual, expected) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { CompositeCheckBuilder } from '../assert/assertion-extension.ts';
|
|
2
|
-
import type { CompositeAssertionReference, CompositeAssertionReturn } from '
|
|
3
|
-
import type { CompositeAssertionChildNode } from '
|
|
2
|
+
import type { CompositeAssertionReference, CompositeAssertionReturn } from '@overkill-dev/engine/packages/engine/assertion-protocol.entry-point.js';
|
|
3
|
+
import type { CompositeAssertionChildNode } from '@overkill-dev/engine/assertion-protocol/assertion-node.js';
|
|
4
4
|
export type UsageMode = 'call' | 'construction' | 'interaction';
|
|
5
5
|
export type ArgumentMatch = 'exact' | 'partial' | 'prefix';
|
|
6
6
|
export type AssertionCheck = CompositeCheckBuilder<'assert'>;
|
package/package.json
CHANGED
|
@@ -21,17 +21,19 @@
|
|
|
21
21
|
],
|
|
22
22
|
"license": "MIT",
|
|
23
23
|
"name": "@overkill-dev/doubles",
|
|
24
|
+
"peerDependencies": {
|
|
25
|
+
"@overkill-dev/engine": "0.0.5"
|
|
26
|
+
},
|
|
24
27
|
"repository": {
|
|
25
28
|
"type": "git",
|
|
26
29
|
"url": "git+https://github.com/enormora/overkill.git"
|
|
27
30
|
},
|
|
28
31
|
"sideEffects": [
|
|
29
|
-
"./assertion-protocol/assertion-reference.js",
|
|
30
32
|
"./doubles/disposal-symbol.js",
|
|
31
33
|
"./doubles/double-usage.js",
|
|
32
34
|
"./doubles/protocol-double.js",
|
|
33
35
|
"./doubles/test-double.js"
|
|
34
36
|
],
|
|
35
37
|
"type": "module",
|
|
36
|
-
"version": "0.0.
|
|
38
|
+
"version": "0.0.3"
|
|
37
39
|
}
|
package/sbom.cdx.json
CHANGED
|
@@ -9,22 +9,42 @@
|
|
|
9
9
|
{
|
|
10
10
|
"type": "application",
|
|
11
11
|
"name": "packtory",
|
|
12
|
-
"version": "0.0.
|
|
12
|
+
"version": "0.0.86"
|
|
13
13
|
}
|
|
14
14
|
]
|
|
15
15
|
},
|
|
16
16
|
"component": {
|
|
17
17
|
"type": "library",
|
|
18
18
|
"name": "@overkill-dev/doubles",
|
|
19
|
-
"version": "0.0.
|
|
20
|
-
"bom-ref": "pkg:npm/@overkill-dev/doubles@0.0.
|
|
21
|
-
"purl": "pkg:npm/@overkill-dev/doubles@0.0.
|
|
19
|
+
"version": "0.0.3",
|
|
20
|
+
"bom-ref": "pkg:npm/@overkill-dev/doubles@0.0.3",
|
|
21
|
+
"purl": "pkg:npm/@overkill-dev/doubles@0.0.3"
|
|
22
22
|
}
|
|
23
23
|
},
|
|
24
|
-
"components": [
|
|
24
|
+
"components": [
|
|
25
|
+
{
|
|
26
|
+
"type": "library",
|
|
27
|
+
"name": "@overkill-dev/engine",
|
|
28
|
+
"version": "0.0.5",
|
|
29
|
+
"bom-ref": "pkg:npm/@overkill-dev/engine@0.0.5",
|
|
30
|
+
"scope": "optional",
|
|
31
|
+
"licenses": [
|
|
32
|
+
{
|
|
33
|
+
"expression": "MIT"
|
|
34
|
+
}
|
|
35
|
+
],
|
|
36
|
+
"purl": "pkg:npm/@overkill-dev/engine@0.0.5"
|
|
37
|
+
}
|
|
38
|
+
],
|
|
25
39
|
"dependencies": [
|
|
26
40
|
{
|
|
27
|
-
"ref": "pkg:npm/@overkill-dev/doubles@0.0.
|
|
41
|
+
"ref": "pkg:npm/@overkill-dev/doubles@0.0.3",
|
|
42
|
+
"dependsOn": [
|
|
43
|
+
"pkg:npm/@overkill-dev/engine@0.0.5"
|
|
44
|
+
]
|
|
45
|
+
},
|
|
46
|
+
{
|
|
47
|
+
"ref": "pkg:npm/@overkill-dev/engine@0.0.5"
|
|
28
48
|
}
|
|
29
49
|
]
|
|
30
50
|
}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { type ComparisonResult } from '../compare/comparison.ts';
|
|
2
|
-
import type { SerializedValue } from '../compare/serialized-value.ts';
|
|
3
|
-
import type { Diff, DiffPathSegment } from '../diff/diff-shape.ts';
|
|
4
|
-
export type AssertionOutcome = {
|
|
5
|
-
readonly actual: SerializedValue;
|
|
6
|
-
readonly diff: Diff | null;
|
|
7
|
-
readonly expected: SerializedValue;
|
|
8
|
-
readonly passed: boolean;
|
|
9
|
-
readonly path: readonly DiffPathSegment[];
|
|
10
|
-
};
|
|
11
|
-
export declare const assertionOutcome: (actual: unknown, expected: unknown, passed: boolean) => AssertionOutcome;
|
|
12
|
-
export declare function comparisonOutcome(comparison: ComparisonResult): AssertionOutcome;
|
|
13
|
-
//# sourceMappingURL=assertion-evaluation.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"assertion-evaluation.d.ts","sourceRoot":"","sources":["../../../../source/assertion-protocol/assertion-evaluation.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,gBAAgB,EAAqB,MAAM,0BAA0B,CAAC;AACpF,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,gCAAgC,CAAC;AACtE,OAAO,KAAK,EAAE,IAAI,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAEnE,MAAM,MAAM,gBAAgB,GAAG;IAC3B,QAAQ,CAAC,MAAM,EAAE,eAAe,CAAC;IACjC,QAAQ,CAAC,IAAI,EAAE,IAAI,GAAG,IAAI,CAAC;IAC3B,QAAQ,CAAC,QAAQ,EAAE,eAAe,CAAC;IACnC,QAAQ,CAAC,MAAM,EAAE,OAAO,CAAC;IACzB,QAAQ,CAAC,IAAI,EAAE,SAAS,eAAe,EAAE,CAAC;CAC7C,CAAC;AAEF,eAAO,MAAM,gBAAgB,EAAE,CAAC,MAAM,EAAE,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,MAAM,EAAE,OAAO,KAAK,gBACnE,CAAC;AAEtB,wBAAgB,iBAAiB,CAAC,UAAU,EAAE,gBAAgB,GAAG,gBAAgB,CAEhF"}
|
|
@@ -1,71 +0,0 @@
|
|
|
1
|
-
import type { SerializedValue } from '../compare/serialized-value.ts';
|
|
2
|
-
import type { Diff, DiffPathSegment } from '../diff/diff-shape.ts';
|
|
3
|
-
import type { ThrownErrorRecord } from './thrown-error-record.ts';
|
|
4
|
-
export declare const assertionSources: readonly ["assert", "require"];
|
|
5
|
-
export type NonEmptyReadonlyArray<Item> = readonly [Item, ...(readonly Item[])];
|
|
6
|
-
export type AssertionSource = (typeof assertionSources)[number];
|
|
7
|
-
type PrimitiveValueByType = {
|
|
8
|
-
readonly bigint: bigint;
|
|
9
|
-
readonly boolean: boolean;
|
|
10
|
-
readonly null: null;
|
|
11
|
-
readonly number: number;
|
|
12
|
-
readonly string: string;
|
|
13
|
-
readonly symbol: symbol;
|
|
14
|
-
readonly undefined: undefined;
|
|
15
|
-
};
|
|
16
|
-
type PrimitiveValue = PrimitiveValueByType[keyof PrimitiveValueByType];
|
|
17
|
-
type IsAny<Value> = 0 extends Value & 1 ? true : false;
|
|
18
|
-
type DeepComparableKnownValue<Value> = [Extract<Value, PrimitiveValue>] extends [never] ? Value : never;
|
|
19
|
-
type DeepComparableUnknownValue<Value> = unknown extends Value ? unknown : DeepComparableKnownValue<Value>;
|
|
20
|
-
export type DeepComparable<Value = unknown> = IsAny<Value> extends true ? never : DeepComparableUnknownValue<Value>;
|
|
21
|
-
export type AssertionOptions = {
|
|
22
|
-
readonly message: string;
|
|
23
|
-
};
|
|
24
|
-
export type SourceLocation = {
|
|
25
|
-
readonly column: number | null;
|
|
26
|
-
readonly file: string;
|
|
27
|
-
readonly line: number | null;
|
|
28
|
-
};
|
|
29
|
-
export type SourceLocationProvider = () => SourceLocation;
|
|
30
|
-
export type ResolvableSourceLocation = SourceLocation | SourceLocationProvider;
|
|
31
|
-
type FailedCheckBase = {
|
|
32
|
-
readonly actual: SerializedValue;
|
|
33
|
-
readonly diff: Diff | null;
|
|
34
|
-
readonly expected: SerializedValue;
|
|
35
|
-
readonly id: string;
|
|
36
|
-
readonly location: SourceLocation;
|
|
37
|
-
readonly path: readonly DiffPathSegment[];
|
|
38
|
-
readonly source: AssertionSource;
|
|
39
|
-
readonly summary: string;
|
|
40
|
-
};
|
|
41
|
-
export type FailedLeafCheck = FailedCheckBase & {
|
|
42
|
-
readonly kind: 'leaf';
|
|
43
|
-
};
|
|
44
|
-
export type FailedCompositeCheck = FailedCheckBase & {
|
|
45
|
-
readonly children: NonEmptyReadonlyArray<FailedCheck>;
|
|
46
|
-
readonly kind: 'composite';
|
|
47
|
-
};
|
|
48
|
-
export type FailedForeignCheck = FailedCheckBase & {
|
|
49
|
-
readonly error: ThrownErrorRecord;
|
|
50
|
-
readonly kind: 'foreign';
|
|
51
|
-
readonly label: string;
|
|
52
|
-
};
|
|
53
|
-
export type FailedCheck = FailedCompositeCheck | FailedForeignCheck | FailedLeafCheck;
|
|
54
|
-
export type InstanceConstructor = abstract new (...args: never[]) => unknown;
|
|
55
|
-
export type ActualAssertionNode<Source extends AssertionSource, Check extends string> = {
|
|
56
|
-
readonly actual: unknown;
|
|
57
|
-
readonly check: Check;
|
|
58
|
-
readonly location: ResolvableSourceLocation;
|
|
59
|
-
readonly message: string | null;
|
|
60
|
-
readonly source: Source;
|
|
61
|
-
};
|
|
62
|
-
export type ExpectedAssertionNode<Source extends AssertionSource, Check extends string> = {
|
|
63
|
-
readonly actual: unknown;
|
|
64
|
-
readonly check: Check;
|
|
65
|
-
readonly expected: unknown;
|
|
66
|
-
readonly location: ResolvableSourceLocation;
|
|
67
|
-
readonly message: string | null;
|
|
68
|
-
readonly source: Source;
|
|
69
|
-
};
|
|
70
|
-
export {};
|
|
71
|
-
//# sourceMappingURL=assertion-node-shape.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"assertion-node-shape.d.ts","sourceRoot":"","sources":["../../../../source/assertion-protocol/assertion-node-shape.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,gCAAgC,CAAC;AACtE,OAAO,KAAK,EAAE,IAAI,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AACnE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,0BAA0B,CAAC;AAElE,eAAO,MAAM,gBAAgB,gCAAmC,CAAC;AAEjE,MAAM,MAAM,qBAAqB,CAAC,IAAI,IAAI,SAAS,CAAC,IAAI,EAAE,GAAG,CAAC,SAAS,IAAI,EAAE,CAAC,CAAC,CAAC;AAEhF,MAAM,MAAM,eAAe,GAAG,CAAC,OAAO,gBAAgB,CAAC,CAAC,MAAM,CAAC,CAAC;AAEhE,KAAK,oBAAoB,GAAG;IACxB,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,OAAO,EAAE,OAA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AAO,EAAE,MAAM,GAAG,IAAI,CAAC;IAChC,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;CAC3B,CAAC;AAEF,MAAM,MAAM,qBAAqB,CAAC,MAAM,SAAS,eAAe,EAAE,KAAK,SAAS,MAAM,IAAI;IACtF,QAAQ,CAAC,MAAM,EAAE,OAAO,CAAC;IACzB,QAAQ,CAAC,KAAK,EAAE,KAAK,CAAC;IACtB,QAAQ,CAAC,QAAQ,EAAE,OAAO,CAAC;IAC3B,QAAQ,CAAC,QAAQ,EAAE,wBAAwB,CAAC;IAC5C,QAAQ,CAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IAChC,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;CAC3B,CAAC"}
|
|
@@ -1,97 +0,0 @@
|
|
|
1
|
-
import { type FalseAssertionNode, type TrueAssertionNode } from './assertions/boolean.ts';
|
|
2
|
-
import { type EmptinessAssertionNode, type LengthAssertionNode } from './assertions/collection.ts';
|
|
3
|
-
import { type DeepEqualAssertionNode, type EqualAssertionNode, type NotDeepEqualAssertionNode, type NotEqualAssertionNode } from './assertions/equality.ts';
|
|
4
|
-
import { type FailAssertionNode } from './assertions/fail.ts';
|
|
5
|
-
import { type BetweenAssertionNode, type NumericComparisonAssertionNode } from './assertions/numeric.ts';
|
|
6
|
-
import { type ArrayContainsPartialAssertionNode, type MembersPartialDeepEqualAssertionNode, type PartialDeepEqualAssertionNode } from './assertions/partial.ts';
|
|
7
|
-
import { type DefinedAssertionNode, type NotNullAssertionNode, type NullAssertionNode, type UndefinedAssertionNode } from './assertions/presence.ts';
|
|
8
|
-
import { type MatchAssertionNode, type StringContainsAssertionNode } from './assertions/string.ts';
|
|
9
|
-
import { type HasPropertyAssertionNode, type InstanceOfAssertionNode, type TypeAssertionNode } from './assertions/type-shape.ts';
|
|
10
|
-
import type { AssertionSource, NonEmptyReadonlyArray, ResolvableSourceLocation } from './assertion-node-shape.ts';
|
|
11
|
-
type ForeignAssertionErrorRecord = {
|
|
12
|
-
readonly message: string;
|
|
13
|
-
readonly name: string;
|
|
14
|
-
readonly stack: string | null;
|
|
15
|
-
readonly thrown: unknown;
|
|
16
|
-
};
|
|
17
|
-
type RequireAssertionNodeByName = {
|
|
18
|
-
readonly defined: DefinedAssertionNode<'require'>;
|
|
19
|
-
readonly hasProperty: HasPropertyAssertionNode<'require'>;
|
|
20
|
-
readonly instanceOf: InstanceOfAssertionNode<'require'>;
|
|
21
|
-
readonly notNull: NotNullAssertionNode<'require'>;
|
|
22
|
-
readonly null: NullAssertionNode<'require'>;
|
|
23
|
-
readonly type: TypeAssertionNode<'require'>;
|
|
24
|
-
};
|
|
25
|
-
type BuiltInAssertAssertionNodeByName<Source extends AssertionSource> = {
|
|
26
|
-
readonly arrayContainsPartial: ArrayContainsPartialAssertionNode<Source>;
|
|
27
|
-
readonly between: BetweenAssertionNode<Source>;
|
|
28
|
-
readonly deepEqual: DeepEqualAssertionNode<Source>;
|
|
29
|
-
readonly defined: DefinedAssertionNode<Source>;
|
|
30
|
-
readonly emptiness: EmptinessAssertionNode<Source>;
|
|
31
|
-
readonly equal: EqualAssertionNode<Source>;
|
|
32
|
-
readonly fail: FailAssertionNode<Source>;
|
|
33
|
-
readonly false: FalseAssertionNode<Source>;
|
|
34
|
-
readonly hasProperty: HasPropertyNode<Source>;
|
|
35
|
-
readonly instanceOf: InstanceOfAssertionNode<Source>;
|
|
36
|
-
readonly length: LengthAssertionNode<Source>;
|
|
37
|
-
readonly match: MatchAssertionNode<Source>;
|
|
38
|
-
readonly membersPartialDeepEqual: MembersPartialDeepEqualAssertionNode<Source>;
|
|
39
|
-
readonly notDeepEqual: NotDeepEqualAssertionNode<Source>;
|
|
40
|
-
readonly notEqual: NotEqualAssertionNode<Source>;
|
|
41
|
-
readonly notNull: NotNullAssertionNode<Source>;
|
|
42
|
-
readonly null: NullAssertionNode<Source>;
|
|
43
|
-
readonly numericComparison: NumericComparisonAssertionNode<Source>;
|
|
44
|
-
readonly partialDeepEqual: PartialDeepEqualAssertionNode<Source>;
|
|
45
|
-
readonly stringContains: StringContainsAssertionNode<Source>;
|
|
46
|
-
readonly true: TrueAssertionNode<Source>;
|
|
47
|
-
readonly type: TypeAssertionNode<Source>;
|
|
48
|
-
readonly undefined: UndefinedAssertionNode<Source>;
|
|
49
|
-
};
|
|
50
|
-
type HasPropertyNode<Source extends AssertionSource> = HasPropertyAssertionNode<Source>;
|
|
51
|
-
export type BuiltInAssertAssertionNode<Source extends AssertionSource = 'assert'> = BuiltInAssertAssertionNodeByName<Source>[keyof BuiltInAssertAssertionNodeByName<Source>];
|
|
52
|
-
type ForeignAssertionResultByOutcome = {
|
|
53
|
-
readonly fail: {
|
|
54
|
-
readonly error: ForeignAssertionErrorRecord;
|
|
55
|
-
readonly passed: false;
|
|
56
|
-
};
|
|
57
|
-
readonly pass: {
|
|
58
|
-
readonly passed: true;
|
|
59
|
-
};
|
|
60
|
-
};
|
|
61
|
-
export type ForeignAssertionResult = ForeignAssertionResultByOutcome[keyof ForeignAssertionResultByOutcome];
|
|
62
|
-
export type ForeignAssertionNode<Source extends AssertionSource = AssertionSource> = {
|
|
63
|
-
readonly check: 'foreign';
|
|
64
|
-
readonly label: string;
|
|
65
|
-
readonly location: ResolvableSourceLocation;
|
|
66
|
-
readonly message: string | null;
|
|
67
|
-
readonly result: ForeignAssertionResult;
|
|
68
|
-
readonly source: Source;
|
|
69
|
-
readonly summary: string;
|
|
70
|
-
};
|
|
71
|
-
type CompositeAssertionChildNodeByKind<Source extends AssertionSource> = {
|
|
72
|
-
readonly builtIn: BuiltInAssertAssertionNode<Source>;
|
|
73
|
-
readonly foreign: ForeignAssertionNode<Source>;
|
|
74
|
-
};
|
|
75
|
-
export type CompositeAssertionChildNode<Source extends AssertionSource = AssertionSource> = CompositeAssertionChildNodeByKind<Source>[keyof CompositeAssertionChildNodeByKind<Source>];
|
|
76
|
-
export type CompositeAssertionNode<Source extends AssertionSource = AssertionSource> = {
|
|
77
|
-
readonly actual: unknown;
|
|
78
|
-
readonly check: 'composite';
|
|
79
|
-
readonly children: NonEmptyReadonlyArray<CompositeAssertionChildNode<Source>>;
|
|
80
|
-
readonly expected: unknown;
|
|
81
|
-
readonly location: ResolvableSourceLocation;
|
|
82
|
-
readonly message: string | null;
|
|
83
|
-
readonly name: string;
|
|
84
|
-
readonly source: Source;
|
|
85
|
-
readonly summary: string;
|
|
86
|
-
};
|
|
87
|
-
type RequireAssertionNodeByKind = RequireAssertionNodeByName & {
|
|
88
|
-
readonly composite: CompositeAssertionNode<'require'>;
|
|
89
|
-
};
|
|
90
|
-
export type RequireAssertionNode = RequireAssertionNodeByKind[keyof RequireAssertionNodeByKind];
|
|
91
|
-
export type AssertAssertionNode = BuiltInAssertAssertionNode | CompositeAssertionNode<'assert'>;
|
|
92
|
-
export type AssertionNode = AssertAssertionNode | RequireAssertionNode;
|
|
93
|
-
export type AssertionResult = AssertAssertionNode | NonEmptyReadonlyArray<AssertAssertionNode>;
|
|
94
|
-
type SummarizedAssertionNode = AssertionNode | CompositeAssertionChildNode | CompositeAssertionNode;
|
|
95
|
-
export declare function assertionSummary(assertion: SummarizedAssertionNode): string;
|
|
96
|
-
export {};
|
|
97
|
-
//# sourceMappingURL=assertion-node.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"assertion-node.d.ts","sourceRoot":"","sources":["../../../../source/assertion-protocol/assertion-node.ts"],"names":[],"mappings":"AAAA,OAAO,EAAyB,KAAK,kBAAkB,EAAE,KAAK,iBAAiB,EAAE,MAAM,yBAAyB,CAAC;AACjH,OAAO,EAEH,KAAK,sBAAsB,EAC3B,KAAK,mBAAmB,EAC3B,MAAM,4BAA4B,CAAC;AACpC,OAAO,EAEH,KAAK,sBAAsB,EAC3B,KAAK,kBAAkB,EACvB,KAAK,yBAAyB,EAC9B,KAAK,qBAAqB,EAC7B,MAAM,0BAA0B,CAAC;AAClC,OAAO,EAAsB,KAAK,iBAAiB,EAAE,MAAM,sBAAsB,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,oBAAoB,CAAC;AAEvE,MAAM,MAAM,eAAe,GAAG,mBAAmB,GAAG,qBAAqB,CAAC,mBAAmB,CAAC,CAAC;AAc/F,KAAK,uBAAuB,GAAG,aAAa,GAAG,2BAA2B,GAAG,sBAAsB,CAAC;AAQpG,wBAAgB,gBAAgB,CAAC,SAAS,EAAE,uBAAuB,GAAG,MAAM,CAU3E"}
|
|
@@ -1,73 +0,0 @@
|
|
|
1
|
-
import type { CompositeAssertionChildNode } from './assertion-node.ts';
|
|
2
|
-
import type { AssertionSource, NonEmptyReadonlyArray, ResolvableSourceLocation } from './assertion-node-shape.ts';
|
|
3
|
-
declare const assertionReferenceIdentity: unique symbol;
|
|
4
|
-
declare const assertionReferenceRecordIdentity: unique symbol;
|
|
5
|
-
declare const compositeGroupIdentity: unique symbol;
|
|
6
|
-
export type CompositeAssertionSummaryContext = {
|
|
7
|
-
readonly name: string;
|
|
8
|
-
readonly source: AssertionSource;
|
|
9
|
-
};
|
|
10
|
-
export type CompositeAssertionGroup<Source extends AssertionSource = AssertionSource> = {
|
|
11
|
-
readonly [compositeGroupIdentity]: true;
|
|
12
|
-
readonly children: NonEmptyReadonlyArray<CompositeAssertionChildNode<Source>>;
|
|
13
|
-
};
|
|
14
|
-
type CompositeAssertionReturnByKind<Source extends AssertionSource> = {
|
|
15
|
-
readonly child: CompositeAssertionChildNode<Source>;
|
|
16
|
-
readonly group: CompositeAssertionGroup<Source>;
|
|
17
|
-
};
|
|
18
|
-
export type CompositeAssertionReturn<Source extends AssertionSource = AssertionSource> = CompositeAssertionReturnByKind<Source>[keyof CompositeAssertionReturnByKind<Source>];
|
|
19
|
-
type PromiseCompositeAssertionReturn = Promise<CompositeAssertionReturn<'assert'>>;
|
|
20
|
-
export type AssertCompositeAssertionReturn = CompositeAssertionReturn<'assert'> | PromiseCompositeAssertionReturn;
|
|
21
|
-
type SyncAssertionReturn = ReturnType<() => void>;
|
|
22
|
-
export type CompositeAssertionSummaryFormatter<Arguments extends readonly unknown[]> = (context: CompositeAssertionSummaryContext, ...parameters: Arguments) => string;
|
|
23
|
-
export type NarrowingCompositeAssertionSummaryFormatter<Actual, Arguments extends readonly unknown[]> = (context: CompositeAssertionSummaryContext, actual: Actual, ...parameters: Arguments) => string;
|
|
24
|
-
export type CompositeAssertionRunnerInput<Arguments extends readonly unknown[], Source extends AssertionSource> = {
|
|
25
|
-
readonly location: ResolvableSourceLocation;
|
|
26
|
-
readonly message: string | null;
|
|
27
|
-
readonly parameters: Arguments;
|
|
28
|
-
readonly source: Source;
|
|
29
|
-
};
|
|
30
|
-
export type CompositeAssertionReferenceRecord<Arguments extends readonly unknown[] = readonly unknown[], Result extends AssertCompositeAssertionReturn = AssertCompositeAssertionReturn> = {
|
|
31
|
-
readonly formatSummary: CompositeAssertionSummaryFormatter<Arguments> | null;
|
|
32
|
-
readonly kind: 'composite';
|
|
33
|
-
readonly name: string;
|
|
34
|
-
readonly run: (input: CompositeAssertionRunnerInput<Arguments, 'assert'>) => Result;
|
|
35
|
-
};
|
|
36
|
-
export type NarrowingCompositeAssertionReferenceRecord<Actual = unknown, Narrowed extends Actual = Actual, Arguments extends readonly unknown[] = readonly unknown[]> = {
|
|
37
|
-
readonly formatSummary: NarrowingCompositeAssertionSummaryFormatter<Actual, Arguments> | null;
|
|
38
|
-
readonly kind: 'narrowing-composite';
|
|
39
|
-
readonly name: string;
|
|
40
|
-
readonly narrows: (actual: Actual, ...parameters: Arguments) => actual is Narrowed;
|
|
41
|
-
};
|
|
42
|
-
export type AssertionReferenceRecord = CompositeAssertionReferenceRecord | NarrowingCompositeAssertionReferenceRecord;
|
|
43
|
-
export type CompositeAssertionReference<Arguments extends readonly unknown[] = readonly unknown[], Result extends AssertCompositeAssertionReturn = AssertCompositeAssertionReturn> = {
|
|
44
|
-
readonly [assertionReferenceIdentity]: true;
|
|
45
|
-
readonly [assertionReferenceRecordIdentity]: CompositeAssertionReferenceRecord<Arguments, Result>;
|
|
46
|
-
};
|
|
47
|
-
export type NarrowingCompositeAssertionReference<Actual = unknown, Narrowed extends Actual = Actual, Arguments extends readonly unknown[] = readonly unknown[]> = {
|
|
48
|
-
readonly [assertionReferenceIdentity]: true;
|
|
49
|
-
readonly [assertionReferenceRecordIdentity]: NarrowingCompositeAssertionReferenceRecord<Actual, Narrowed, Arguments>;
|
|
50
|
-
};
|
|
51
|
-
export type AssertionReference = CompositeAssertionReference | NarrowingCompositeAssertionReference;
|
|
52
|
-
type NarrowingReferenceArguments<Actual, Arguments extends readonly unknown[]> = readonly [
|
|
53
|
-
actual: Actual,
|
|
54
|
-
...parameters: Arguments
|
|
55
|
-
];
|
|
56
|
-
type ReferenceArguments<Reference> = Reference extends NarrowingCompositeAssertionReference<infer Actual, infer Narrowed, infer Arguments> ? NarrowingReferenceArguments<Actual | Narrowed, Arguments> : never;
|
|
57
|
-
type ReferenceReturn<Result> = Result extends Promise<CompositeAssertionReturn<'assert'>> ? Promise<void> : SyncAssertionReturn;
|
|
58
|
-
type ReadonlyParameters<Arguments extends readonly unknown[]> = readonly [...Arguments];
|
|
59
|
-
export type AssertReferenceArguments<Reference> = Reference extends CompositeAssertionReference<infer Arguments> ? ReadonlyParameters<Arguments> : ReferenceArguments<Reference>;
|
|
60
|
-
export type AssertReferenceReturn<Reference> = Reference extends CompositeAssertionReference<infer Arguments, infer Result> ? Arguments extends readonly unknown[] ? ReferenceReturn<Result> : never : SyncAssertionReturn;
|
|
61
|
-
export declare function createAssertionReferenceRecord<Arguments extends readonly unknown[], Result extends AssertCompositeAssertionReturn>(record: CompositeAssertionReferenceRecord<Arguments, Result>): CompositeAssertionReference<Arguments, Result>;
|
|
62
|
-
export declare function createAssertionReferenceRecord<Actual, Narrowed extends Actual, Arguments extends readonly unknown[]>(record: NarrowingCompositeAssertionReferenceRecord<Actual, Narrowed, Arguments>): NarrowingCompositeAssertionReference<Actual, Narrowed, Arguments>;
|
|
63
|
-
export declare function createCompositeAssertionReferenceRecord<Arguments extends readonly unknown[], Result extends AssertCompositeAssertionReturn>(record: CompositeAssertionReferenceRecord<Arguments, Result>): CompositeAssertionReference<Arguments, Result>;
|
|
64
|
-
export declare function createNarrowingCompositeAssertionReferenceRecord<Actual, Narrowed extends Actual, Arguments extends readonly unknown[]>(record: NarrowingCompositeAssertionReferenceRecord<Actual, Narrowed, Arguments>): NarrowingCompositeAssertionReference<Actual, Narrowed, Arguments>;
|
|
65
|
-
export declare function getAssertionReferenceRecord(reference: AssertionReference): AssertionReferenceRecord;
|
|
66
|
-
export declare function getCompositeAssertionReferenceRecord<Arguments extends readonly unknown[], Result extends AssertCompositeAssertionReturn>(reference: CompositeAssertionReference<Arguments, Result>): CompositeAssertionReferenceRecord<Arguments, Result>;
|
|
67
|
-
export declare function getNarrowingAssertionReferenceRecord<Actual, Narrowed extends Actual, Arguments extends readonly unknown[]>(reference: NarrowingCompositeAssertionReference<Actual, Narrowed, Arguments>): NarrowingCompositeAssertionReferenceRecord<Actual, Narrowed, Arguments>;
|
|
68
|
-
export declare function isAssertionReference(value: unknown): value is AssertionReference;
|
|
69
|
-
export declare function isNarrowingAssertionReference(value: unknown): value is NarrowingCompositeAssertionReference;
|
|
70
|
-
export declare function isCompositeAssertionGroup<Source extends AssertionSource>(value: unknown): value is CompositeAssertionGroup<Source>;
|
|
71
|
-
export declare function createCompositeAssertionGroup<Source extends AssertionSource>(children: NonEmptyReadonlyArray<CompositeAssertionChildNode<Source>>): CompositeAssertionGroup<Source>;
|
|
72
|
-
export {};
|
|
73
|
-
//# sourceMappingURL=assertion-reference.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"assertion-reference.d.ts","sourceRoot":"","sources":["../../../../source/assertion-protocol/assertion-reference.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACR,2BAA2B,EAC9B,MAAM,qBAAqB,CAAC;AAC7B,OAAO,KAAK,EACR,eAAe,EACf,qBAAqB,EACrB,wBAAwB,EAC3B,MAAM,2BAA2B,CAAC;AAEnC,QAAA,MAAM,0BAA0B,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ecord');
|
|
3
|
-
const compositeGroupIdentity = Symbol.for('OverkillCompositeGroup');
|
|
4
|
-
function ensureAssertionName(name) {
|
|
5
|
-
if (name.trim().length === 0) {
|
|
6
|
-
throw new TypeError('Assertion reference name must not be empty.');
|
|
7
|
-
}
|
|
8
|
-
}
|
|
9
|
-
export function createAssertionReferenceRecord(record) {
|
|
10
|
-
ensureAssertionName(record.name);
|
|
11
|
-
if (record.kind === 'composite') {
|
|
12
|
-
return {
|
|
13
|
-
[assertionReferenceIdentity]: true,
|
|
14
|
-
[assertionReferenceRecordIdentity]: record
|
|
15
|
-
};
|
|
16
|
-
}
|
|
17
|
-
return {
|
|
18
|
-
[assertionReferenceIdentity]: true,
|
|
19
|
-
[assertionReferenceRecordIdentity]: record
|
|
20
|
-
};
|
|
21
|
-
}
|
|
22
|
-
export function createCompositeAssertionReferenceRecord(record) {
|
|
23
|
-
return createAssertionReferenceRecord({ ...record });
|
|
24
|
-
}
|
|
25
|
-
export function createNarrowingCompositeAssertionReferenceRecord(record) {
|
|
26
|
-
return createAssertionReferenceRecord({ ...record });
|
|
27
|
-
}
|
|
28
|
-
export function getAssertionReferenceRecord(reference) {
|
|
29
|
-
return reference[assertionReferenceRecordIdentity];
|
|
30
|
-
}
|
|
31
|
-
export function getCompositeAssertionReferenceRecord(reference) {
|
|
32
|
-
return reference[assertionReferenceRecordIdentity];
|
|
33
|
-
}
|
|
34
|
-
export function getNarrowingAssertionReferenceRecord(reference) {
|
|
35
|
-
return reference[assertionReferenceRecordIdentity];
|
|
36
|
-
}
|
|
37
|
-
export function isAssertionReference(value) {
|
|
38
|
-
return typeof value === 'object' && value !== null && Object.hasOwn(value, assertionReferenceIdentity);
|
|
39
|
-
}
|
|
40
|
-
export function isNarrowingAssertionReference(value) {
|
|
41
|
-
return isAssertionReference(value) && getAssertionReferenceRecord(value).kind === 'narrowing-composite';
|
|
42
|
-
}
|
|
43
|
-
export function isCompositeAssertionGroup(value) {
|
|
44
|
-
return typeof value === 'object' && value !== null && Object.hasOwn(value, compositeGroupIdentity);
|
|
45
|
-
}
|
|
46
|
-
export function createCompositeAssertionGroup(children) {
|
|
47
|
-
return { [compositeGroupIdentity]: true, children };
|
|
48
|
-
}
|
|
49
|
-
//# sourceMappingURL=assertion-reference.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"assertion-reference.js","sourceRoot":"","sources":["../../../../source/assertion-protocol/assertion-reference.ts"],"names":[],"mappings":"AASA,MAAM,0BAA0B,GAAkB,MAAM,CAAC,GAAG,CAAC,4BAA4B,CAAC,CAAC;AAC3F,MAAM,gCAAgC,GAAkB,MAAM,CAAC,GAAG,CAAC,kCAAkC,CAAC,CAAC;AACvG,MAAM,sBAAsB,GAAkB,MAAM,CAAC,GAAG,CAAC,wBAAwB,CAAC,CAAC;AAyHnF,SAAS,mBAAmB,CAAC,IAAY;IACrC,IAAI,IAAI,CAAC,IAAI,EAAE,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;QAC3B,MAAM,IAAI,SAAS,CAAC,6CAA6C,CAAC,CAAC;IACvE,CAAC;AACL,CAAC;AAaD,MAAM,UAAU,8BAA8B,CAAC,MAAgC;IAC3E,mBAAmB,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC;IAEjC,IAAI,MAAM,CAAC,IAAI,KAAK,WAAW,EAAE,CAAC;QAC9B,OAAO;YACH,CAAC,0BAA0B,CAAC,EAAE,IAAI;YAClC,CAAC,gCAAgC,CAAC,EAAE,MAAM;SAC7C,CAAC;IACN,CAAC;IAED,OAAO;QACH,CAAC,0BAA0B,CAAC,EAAE,IAAI;QAClC,CAAC,gCAAgC,CAAC,EAAE,MAAM;KAC7C,CAAC;AACN,CAAC;AAED,MAAM,UAAU,uCAAuC,CAGrD,MAA4D;IAC1D,OAAO,8BAA8B,CAAC,EAAE,GAAG,MAAM,EAAE,CAAC,CAAC;AACzD,CAAC;AAED,MAAM,UAAU,gDAAgD,CAK5D,MAA+E;IAE/E,OAAO,8BAA8B,CAAC,EAAE,GAAG,MAAM,EAAE,CAAC,CAAC;AACzD,CAAC;AAED,MAAM,UAAU,2BAA2B,CAAC,SAA6B;IACrE,OAAO,SAAS,CAAC,gCAAgC,CAAC,CAAC;AACvD,CAAC;AAED,MAAM,UAAU,oCAAoC,CAIhD,SAAyD;IAEzD,OAAO,SAAS,CAAC,gCAAgC,CAAC,CAAC;AACvD,CAAC;AAED,MAAM,UAAU,oCAAoC,CAKhD,SAA4E;IAE5E,OAAO,SAAS,CAAC,gCAAgC,CAAC,CAAC;AACvD,CAAC;AAED,MAAM,UAAU,oBAAoB,CAAC,KAAc;IAC/C,OAAO,OAAO,KAAK,KAAK,QAAQ,IAAI,KAAK,KAAK,IAAI,IAAI,MAAM,CAAC,MAAM,CAAC,KAAK,EAAE,0BAA0B,CAAC,CAAC;AAC3G,CAAC;AAED,MAAM,UAAU,6BAA6B,CAAC,KAAc;IACxD,OAAO,oBAAoB,CAAC,KAAK,CAAC,IAAI,2BAA2B,CAAC,KAAK,CAAC,CAAC,IAAI,KAAK,qBAAqB,CAAC;AAC5G,CAAC;AAED,MAAM,UAAU,yBAAyB,CACrC,KAAc;IAEd,OAAO,OAAO,KAAK,KAAK,QAAQ,IAAI,KAAK,KAAK,IAAI,IAAI,MAAM,CAAC,MAAM,CAAC,KAAK,EAAE,sBAAsB,CAAC,CAAC;AACvG,CAAC;AAED,MAAM,UAAU,6BAA6B,CACzC,QAAoE;IAEpE,OAAO,EAAE,CAAC,sBAAsB,CAAC,EAAE,IAAI,EAAE,QAAQ,EAAE,CAAC;AACxD,CAAC"}
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { type AssertionOutcome } from '../assertion-evaluation.ts';
|
|
2
|
-
import type { ActualAssertionNode, AssertionSource } from '../assertion-node-shape.ts';
|
|
3
|
-
export type TrueAssertionNode<Source extends AssertionSource = AssertionSource> = ActualAssertionNode<Source, 'true'>;
|
|
4
|
-
export type FalseAssertionNode<Source extends AssertionSource = AssertionSource> = ActualAssertionNode<Source, 'false'>;
|
|
5
|
-
export declare const booleanSummaryByCheck: {
|
|
6
|
-
readonly false: "Expected value to be false.";
|
|
7
|
-
readonly true: "Expected value to be true.";
|
|
8
|
-
};
|
|
9
|
-
export declare function evaluateFalse(assertion: FalseAssertionNode): AssertionOutcome;
|
|
10
|
-
export declare function evaluateTrue(assertion: TrueAssertionNode): AssertionOutcome;
|
|
11
|
-
//# sourceMappingURL=boolean.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"boolean.d.ts","sourceRoot":"","sources":["../../../../../source/assertion-protocol/assertions/boolean.ts"],"names":[],"mappings":"AAAA,OAAO,EAAoB,KAAK,gBAAgB,EAAE,MAAM,4BAA4B,CAAC;AACrF,OAAO,KAAK,EAAE,mBAAmB,EAAE,eAAe,EAAE,MAAM,4BAA4B,CAAC;AAEvF,MAAM,MAAM,iBAAiB,CAAC,MAAM,SAAS,eAAe,GAAG,eAAe,IAAI,mBAAmB,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;AAEtH,MAAM,MAAM,kBAAkB,CAAC,MAAM,SAAS,eAAe,GAAG,eAAe,IAAI,mBAAmB,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;AAExH,eAAO,MAAM,qBAAqB;;;CAGxB,CAAC;AAEX,wBAAgB,aAAa,CAAC,SAAS,EAAE,kBAAkB,GAAG,gBAAgB,CAE7E;AAED,wBAAgB,YAAY,CAAC,SAAS,EAAE,iBAAiB,GAAG,gBAAgB,CAE3E"}
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import { type AssertionOutcome } from '../assertion-evaluation.ts';
|
|
2
|
-
import type { ActualAssertionNode, AssertionSource, ResolvableSourceLocation } from '../assertion-node-shape.ts';
|
|
3
|
-
export type LengthAssertionNode<Source extends AssertionSource = AssertionSource> = {
|
|
4
|
-
readonly actual: unknown;
|
|
5
|
-
readonly check: 'length';
|
|
6
|
-
readonly expectedLength: number;
|
|
7
|
-
readonly location: ResolvableSourceLocation;
|
|
8
|
-
readonly message: string | null;
|
|
9
|
-
readonly source: Source;
|
|
10
|
-
};
|
|
11
|
-
export type EmptinessAssertionNode<Source extends AssertionSource = AssertionSource> = {
|
|
12
|
-
readonly [Check in 'empty' | 'not-empty']: ActualAssertionNode<Source, Check>;
|
|
13
|
-
}['empty' | 'not-empty'];
|
|
14
|
-
export declare const collectionSummaryByCheck: {
|
|
15
|
-
readonly empty: "Expected collection to be empty.";
|
|
16
|
-
readonly length: "Expected collection length to match.";
|
|
17
|
-
readonly 'not-empty': "Expected collection not to be empty.";
|
|
18
|
-
};
|
|
19
|
-
export declare function evaluateEmpty(assertion: EmptinessAssertionNode): AssertionOutcome;
|
|
20
|
-
export declare function evaluateLength(assertion: LengthAssertionNode): AssertionOutcome;
|
|
21
|
-
export declare function evaluateNotEmpty(assertion: EmptinessAssertionNode): AssertionOutcome;
|
|
22
|
-
//# sourceMappingURL=collection.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"collection.d.ts","sourceRoot":"","sources":["../../../../../source/assertion-protocol/assertions/collection.ts"],"names":[],"mappings":"AAAA,OAAO,EAAoB,KAAK,gBAAgB,EAAE,MAAM,4BAA4B,CAAC;AACrF,OAAO,KAAK,EAAE,mBAAmB,EAAE,eAAe,EAAE,wBAAwB,EAAE,MAAM,4BAA4B,CAAC;AAGjH,MAAM,MAAM,mBAAmB,CAAC,MAAM,SAAS,eAAe,GAAG,eAAe,IAAI;IAChF,QAAQ,CAAC,MAAM,EAAE,OAAO,CAAC;IACzB,QAAQ,CAAC,KAAK,EAAE,QAAQ,CAAC;IACzB,QAAQ,CAAC,cAAc,EAAE,MAAM,CAAC;IAChC,QAAQ,CAAC,QAAQ,EAAE,wBAAwB,CAAC;IAC5C,QAAQ,CAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IAChC,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;CAC3B,CAAC;AAEF,MAAM,MAAM,sBAAsB,CAAC,MAAM,SAAS,eAAe,GAAG,eAAe,IAAI;IACnF,QAAQ,EAAE,KAAK,IAAI,OAAO,GAAG,WAAW,GAAG,mBAAmB,CAAC,MAAM,EAAE,KAAK,CAAC;CAChF,CAAC,OAAO,GAAG,WAAW,CAAC,CAAC;AAEzB,eAAO,MAAM,wBAAwB;;;;CAI3B,CAAC;AAEX,wBAAgB,aAAa,CAAC,SAAS,EAAE,sBAAsB,GAAG,gBAAgB,CAQjF;AAED,wBAAgB,cAAc,CAAC,SAAS,EAAE,mBAAmB,GAAG,gBAAgB,CAS/E;AAED,wBAAgB,gBAAgB,CAAC,SAAS,EAAE,sBAAsB,GAAG,gBAAgB,CAQpF"}
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import { type AssertionOutcome } from '../assertion-evaluation.ts';
|
|
2
|
-
import type { AssertionSource, ExpectedAssertionNode } from '../assertion-node-shape.ts';
|
|
3
|
-
export type EqualAssertionNode<Source extends AssertionSource = AssertionSource> = ExpectedAssertionNode<Source, 'equal'>;
|
|
4
|
-
export type NotEqualAssertionNode<Source extends AssertionSource = AssertionSource> = ExpectedAssertionNode<Source, 'not-equal'>;
|
|
5
|
-
export type DeepEqualAssertionNode<Source extends AssertionSource = AssertionSource> = ExpectedAssertionNode<Source, 'deep-equal'>;
|
|
6
|
-
export type NotDeepEqualAssertionNode<Source extends AssertionSource = AssertionSource> = ExpectedAssertionNode<Source, 'not-deep-equal'>;
|
|
7
|
-
export declare const equalitySummaryByCheck: {
|
|
8
|
-
readonly 'deep-equal': "Expected values to be deeply equal.";
|
|
9
|
-
readonly equal: "Expected values to be equal.";
|
|
10
|
-
readonly 'not-deep-equal': "Expected values not to be deeply equal.";
|
|
11
|
-
readonly 'not-equal': "Expected values not to be equal.";
|
|
12
|
-
};
|
|
13
|
-
export declare function evaluateDeepEqual(assertion: DeepEqualAssertionNode): AssertionOutcome;
|
|
14
|
-
export declare function evaluateEqual(assertion: EqualAssertionNode): AssertionOutcome;
|
|
15
|
-
export declare function evaluateNotDeepEqual(assertion: NotDeepEqualAssertionNode): AssertionOutcome;
|
|
16
|
-
export declare function evaluateNotEqual(assertion: NotEqualAssertionNode): AssertionOutcome;
|
|
17
|
-
//# sourceMappingURL=equality.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"equality.d.ts","sourceRoot":"","sources":["../../../../../source/assertion-protocol/assertions/equality.ts"],"names":[],"mappings":"AAKA,OAAO,EAAuC,KAAK,gBAAgB,EAAE,MAAM,4BAA4B,CAAC;AACxG,OAAO,KAAK,EAAE,eAAe,EAAE,qBAAqB,EAAE,MAAM,4BAA4B,CAAC;AAEzF,MAAM,MAAM,kBAAkB,CAAC,MAAM,SAAS,eAAe,GAAG,eAAe,IAAI,qBAAqB,CACpG,MAAM,EACN,OAAO,CACV,CAAC;AAEF,MAAM,MAAM,qBAAqB,CAAC,MAAM,SAAS,eAAe,GAAG,eAAe,IAAI,qBAAqB,CACvG,MAAM,EACN,WAAW,CACd,CAAC;AAEF,MAAM,MAAM,sBAAsB,CAAC,MAAM,SAAS,eAAe,GAAG,eAAe,IAAI,qBAAqB,CACxG,MAAM,EACN,YAAY,CACf,CAAC;AAEF,MAAM,MAAM,yBAAyB,CAAC,MAAM,SAAS,eAAe,GAAG,eAAe,IAAI,qBAAqB,CAC3G,MAAM,EACN,gBAAgB,CACnB,CAAC;AAEF,eAAO,MAAM,sBAAsB;;;;;CAKzB,CAAC;AAEX,wBAAgB,iBAAiB,CAAC,SAAS,EAAE,sBAAsB,GAAG,gBAAgB,CAErF;AAED,wBAAgB,aAAa,CAAC,SAAS,EAAE,kBAAkB,GAAG,gBAAgB,CAM7E;AAED,wBAAgB,oBAAoB,CAAC,SAAS,EAAE,yBAAyB,GAAG,gBAAgB,CAM3F;AAED,wBAAgB,gBAAgB,CAAC,SAAS,EAAE,qBAAqB,GAAG,gBAAgB,CAEnF"}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { type AssertionOutcome } from '../assertion-evaluation.ts';
|
|
2
|
-
import type { AssertionSource, ResolvableSourceLocation } from '../assertion-node-shape.ts';
|
|
3
|
-
export type FailAssertionNode<Source extends AssertionSource = AssertionSource> = {
|
|
4
|
-
readonly check: 'fail';
|
|
5
|
-
readonly location: ResolvableSourceLocation;
|
|
6
|
-
readonly message: string | null;
|
|
7
|
-
readonly source: Source;
|
|
8
|
-
};
|
|
9
|
-
export declare const failSummaryByCheck: {
|
|
10
|
-
readonly fail: "Assertion failed.";
|
|
11
|
-
};
|
|
12
|
-
export declare function evaluateFail(assertion: FailAssertionNode): AssertionOutcome;
|
|
13
|
-
//# sourceMappingURL=fail.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"fail.d.ts","sourceRoot":"","sources":["../../../../../source/assertion-protocol/assertions/fail.ts"],"names":[],"mappings":"AAAA,OAAO,EAAoB,KAAK,gBAAgB,EAAE,MAAM,4BAA4B,CAAC;AACrF,OAAO,KAAK,EAAE,eAAe,EAAE,wBAAwB,EAAE,MAAM,4BAA4B,CAAC;AAE5F,MAAM,MAAM,iBAAiB,CAAC,MAAM,SAAS,eAAe,GAAG,eAAe,IAAI;IAC9E,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,QAAQ,EAAE,wBAAwB,CAAC;IAC5C,QAAQ,CAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IAChC,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;CAC3B,CAAC;AAEF,eAAO,MAAM,kBAAkB;;CAErB,CAAC;AAEX,wBAAgB,YAAY,CAAC,SAAS,EAAE,iBAAiB,GAAG,gBAAgB,CAE3E"}
|