@creative-introvert/tons-of-tests 2.1.0 → 3.0.0-rc.1
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/README.md +143 -37
- package/dist/cjs/Classify.js +1 -2
- package/dist/cjs/Classify.js.map +1 -1
- package/dist/cjs/RepositoryError.js +42 -33
- package/dist/cjs/RepositoryError.js.map +1 -1
- package/dist/cjs/Show.js +18 -0
- package/dist/cjs/Show.js.map +1 -1
- package/dist/cjs/Test.js +40 -2
- package/dist/cjs/Test.js.map +1 -1
- package/dist/cjs/Test.repository.js +25 -22
- package/dist/cjs/Test.repository.js.map +1 -1
- package/dist/cjs/TestRun.js +28 -0
- package/dist/cjs/TestRun.js.map +1 -0
- package/dist/cjs/TestValueError.js +23 -0
- package/dist/cjs/TestValueError.js.map +1 -0
- package/dist/cjs/index.js +0 -7
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/internal/Classify.js +1 -9
- package/dist/cjs/internal/Classify.js.map +1 -1
- package/dist/cjs/internal/Test.js +235 -95
- package/dist/cjs/internal/Test.js.map +1 -1
- package/dist/cjs/internal/Test.repository.sqlite.js +487 -356
- package/dist/cjs/internal/Test.repository.sqlite.js.map +1 -1
- package/dist/cjs/internal/Test.serialization.js +128 -0
- package/dist/cjs/internal/Test.serialization.js.map +1 -0
- package/dist/cjs/internal/common.js.map +1 -1
- package/dist/cjs/internal/stats.js +29 -1
- package/dist/cjs/internal/stats.js.map +1 -1
- package/dist/cjs/internal/summarize.js +143 -29
- package/dist/cjs/internal/summarize.js.map +1 -1
- package/dist/cjs/internal/test-repository-fixtures.js +31 -0
- package/dist/cjs/internal/test-repository-fixtures.js.map +1 -0
- package/dist/cjs/internal/test-repository-schema.js +98 -0
- package/dist/cjs/internal/test-repository-schema.js.map +1 -0
- package/dist/cjs/internal/test-result-stats.js +89 -0
- package/dist/cjs/internal/test-result-stats.js.map +1 -0
- package/dist/dts/Classify.d.ts +0 -1
- package/dist/dts/Classify.d.ts.map +1 -1
- package/dist/dts/RepositoryError.d.ts +47 -20
- package/dist/dts/RepositoryError.d.ts.map +1 -1
- package/dist/dts/Show.d.ts +5 -5
- package/dist/dts/Show.d.ts.map +1 -1
- package/dist/dts/Test.d.ts +136 -13
- package/dist/dts/Test.d.ts.map +1 -1
- package/dist/dts/Test.repository.d.ts +132 -9
- package/dist/dts/Test.repository.d.ts.map +1 -1
- package/dist/dts/TestRun.d.ts +22 -0
- package/dist/dts/TestRun.d.ts.map +1 -0
- package/dist/dts/TestValueError.d.ts +17 -0
- package/dist/dts/TestValueError.d.ts.map +1 -0
- package/dist/dts/index.d.ts +0 -1
- package/dist/dts/index.d.ts.map +1 -1
- package/dist/dts/internal/Classify.d.ts +0 -1
- package/dist/dts/internal/Classify.d.ts.map +1 -1
- package/dist/dts/internal/Test.d.ts +64 -30
- package/dist/dts/internal/Test.d.ts.map +1 -1
- package/dist/dts/internal/Test.repository.sqlite.d.ts +92 -11
- package/dist/dts/internal/Test.repository.sqlite.d.ts.map +1 -1
- package/dist/dts/internal/Test.serialization.d.ts +34 -0
- package/dist/dts/internal/Test.serialization.d.ts.map +1 -0
- package/dist/dts/internal/common.d.ts +1 -1
- package/dist/dts/internal/common.d.ts.map +1 -1
- package/dist/dts/internal/stats.d.ts +16 -1
- package/dist/dts/internal/stats.d.ts.map +1 -1
- package/dist/dts/internal/summarize.d.ts +39 -7
- package/dist/dts/internal/summarize.d.ts.map +1 -1
- package/dist/dts/internal/test-repository-fixtures.d.ts +33 -0
- package/dist/dts/internal/test-repository-fixtures.d.ts.map +1 -0
- package/dist/dts/internal/test-repository-schema.d.ts +16 -0
- package/dist/dts/internal/test-repository-schema.d.ts.map +1 -0
- package/dist/dts/internal/test-result-stats.d.ts +7 -0
- package/dist/dts/internal/test-result-stats.d.ts.map +1 -0
- package/dist/esm/Classify.js +0 -1
- package/dist/esm/Classify.js.map +1 -1
- package/dist/esm/RepositoryError.js +29 -29
- package/dist/esm/RepositoryError.js.map +1 -1
- package/dist/esm/Show.js +2 -2
- package/dist/esm/Show.js.map +1 -1
- package/dist/esm/Test.js +37 -1
- package/dist/esm/Test.js.map +1 -1
- package/dist/esm/Test.repository.js +26 -21
- package/dist/esm/Test.repository.js.map +1 -1
- package/dist/esm/TestRun.js +22 -0
- package/dist/esm/TestRun.js.map +1 -0
- package/dist/esm/TestValueError.js +16 -0
- package/dist/esm/TestValueError.js.map +1 -0
- package/dist/esm/index.js +0 -1
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/internal/Classify.js +0 -7
- package/dist/esm/internal/Classify.js.map +1 -1
- package/dist/esm/internal/Test.js +231 -94
- package/dist/esm/internal/Test.js.map +1 -1
- package/dist/esm/internal/Test.repository.sqlite.js +486 -356
- package/dist/esm/internal/Test.repository.sqlite.js.map +1 -1
- package/dist/esm/internal/Test.serialization.js +119 -0
- package/dist/esm/internal/Test.serialization.js.map +1 -0
- package/dist/esm/internal/common.js.map +1 -1
- package/dist/esm/internal/stats.js +27 -0
- package/dist/esm/internal/stats.js.map +1 -1
- package/dist/esm/internal/summarize.js +143 -28
- package/dist/esm/internal/summarize.js.map +1 -1
- package/dist/esm/internal/test-repository-fixtures.js +25 -0
- package/dist/esm/internal/test-repository-fixtures.js.map +1 -0
- package/dist/esm/internal/test-repository-schema.js +92 -0
- package/dist/esm/internal/test-repository-schema.js.map +1 -0
- package/dist/esm/internal/test-result-stats.js +83 -0
- package/dist/esm/internal/test-result-stats.js.map +1 -0
- package/package.json +1 -1
- package/dist/cjs/Test.repository.types.js +0 -14
- package/dist/cjs/Test.repository.types.js.map +0 -1
- package/dist/cjs/internal/lib/Schema.js +0 -14
- package/dist/cjs/internal/lib/Schema.js.map +0 -1
- package/dist/dts/Test.repository.types.d.ts +0 -62
- package/dist/dts/Test.repository.types.d.ts.map +0 -1
- package/dist/dts/internal/lib/Schema.d.ts +0 -4
- package/dist/dts/internal/lib/Schema.d.ts.map +0 -1
- package/dist/esm/Test.repository.types.js +0 -7
- package/dist/esm/Test.repository.types.js.map +0 -1
- package/dist/esm/internal/lib/Schema.js +0 -7
- package/dist/esm/internal/lib/Schema.js.map +0 -1
package/dist/dts/Test.d.ts
CHANGED
|
@@ -1,8 +1,13 @@
|
|
|
1
|
-
import { type Array, Effect, Option, type Stream } from 'effect';
|
|
1
|
+
import { type Array, type Effect, type Option, Schema, type Stream } from 'effect';
|
|
2
2
|
import type { Label, Stats } from './Classify.js';
|
|
3
3
|
import * as internal from './internal/Test.js';
|
|
4
4
|
import type { TestRun, TestResultSchemas } from './Test.repository.js';
|
|
5
|
-
|
|
5
|
+
/** Codecs must encode deterministically and preserve values through JSON. */
|
|
6
|
+
export type TestSuiteSchemas<I, T, A, B> = TestResultSchemas<I, A, B> & {
|
|
7
|
+
testCase: {
|
|
8
|
+
expected: Schema.Codec<T, unknown>;
|
|
9
|
+
};
|
|
10
|
+
};
|
|
6
11
|
export type TestCases<I, T, E = never, R = never> = ReadonlyArray<TestCase<I, T>> | Stream.Stream<TestCase<I, T>, E, R>;
|
|
7
12
|
export type EvaluationResult<A, B> = {
|
|
8
13
|
/** Non-empty and unique within the case. Keep it stable across runs. */
|
|
@@ -17,24 +22,82 @@ export type EvaluationResult<A, B> = {
|
|
|
17
22
|
* unique within the case.
|
|
18
23
|
*/
|
|
19
24
|
export type Evaluate<O, T, A = O, B = T> = (output: O, expected: T) => Array.NonEmptyReadonlyArray<EvaluationResult<A, B>>;
|
|
25
|
+
export type TestSuitePrograms<I, O, E, R> = {
|
|
26
|
+
program: Program<I, O, E, R>;
|
|
27
|
+
variants?: never;
|
|
28
|
+
} | {
|
|
29
|
+
program?: never;
|
|
30
|
+
variants: Readonly<Record<string, {
|
|
31
|
+
program: Program<I, O, E, R>;
|
|
32
|
+
}>>;
|
|
33
|
+
};
|
|
34
|
+
type SuiteProgram<S> = S extends {
|
|
35
|
+
program: infer P;
|
|
36
|
+
} ? P : S extends {
|
|
37
|
+
variants: infer V;
|
|
38
|
+
} ? V[keyof V] extends {
|
|
39
|
+
program: infer P;
|
|
40
|
+
} ? P : never : never;
|
|
41
|
+
type ProgramEffect<S> = SuiteProgram<S> extends (...args: never[]) => infer F ? F : never;
|
|
42
|
+
/** Errors from every configured program and from the case stream. */
|
|
43
|
+
export type TestSuiteError<S> = Effect.Error<ProgramEffect<S>> | Stream.Error<S extends {
|
|
44
|
+
testCases: infer C;
|
|
45
|
+
} ? C : never>;
|
|
46
|
+
/** Callers provide all services used by any program or the case stream. */
|
|
47
|
+
export type TestSuiteServices<S> = Effect.Services<ProgramEffect<S>> | Stream.Services<S extends {
|
|
48
|
+
testCases: infer C;
|
|
49
|
+
} ? C : never>;
|
|
50
|
+
/**
|
|
51
|
+
* Keep source effect types. Skip `evaluate` during inference so the suite supplies
|
|
52
|
+
* its callback parameter types.
|
|
53
|
+
*/
|
|
54
|
+
export type InferTestSuite<S> = {
|
|
55
|
+
[K in keyof S]: K extends 'evaluate' ? unknown : S[K];
|
|
56
|
+
};
|
|
57
|
+
export type SelectedProgram<S> = Program<SuiteProgram<S> extends (input: infer I) => unknown ? I : never, Effect.Success<ProgramEffect<S>>, Effect.Error<ProgramEffect<S>>, Effect.Services<ProgramEffect<S>>>;
|
|
58
|
+
declare const TestVariantRequired_base: Schema.Class<TestVariantRequired, Schema.TaggedStruct<"TestVariantRequired", {
|
|
59
|
+
readonly testSuiteName: Schema.String;
|
|
60
|
+
}>, import("effect/Cause").YieldableError & {
|
|
61
|
+
readonly brand: unique symbol;
|
|
62
|
+
}>;
|
|
63
|
+
export declare class TestVariantRequired extends TestVariantRequired_base {
|
|
64
|
+
}
|
|
65
|
+
declare const TestVariantNotFound_base: Schema.Class<TestVariantNotFound, Schema.TaggedStruct<"TestVariantNotFound", {
|
|
66
|
+
readonly testSuiteName: Schema.String;
|
|
67
|
+
readonly variant: Schema.String;
|
|
68
|
+
}>, import("effect/Cause").YieldableError & {
|
|
69
|
+
readonly brand: unique symbol;
|
|
70
|
+
}>;
|
|
71
|
+
export declare class TestVariantNotFound extends TestVariantNotFound_base {
|
|
72
|
+
}
|
|
20
73
|
/**
|
|
21
|
-
*
|
|
22
|
-
*
|
|
23
|
-
*
|
|
74
|
+
* Defines either one `program` or named `variants` that share cases, schemas,
|
|
75
|
+
* and evaluation. A single program has the permanent variant ID `default`.
|
|
76
|
+
* `Test.all` needs an explicit selection for named variants, even when there is
|
|
77
|
+
* only one. CLI reporting commands select all configured variants by default.
|
|
78
|
+
* Variant IDs must be non-empty, contain no commas, and not start with `run:`.
|
|
79
|
+
* Editing a program keeps its history; changing its ID starts another history.
|
|
80
|
+
* An empty `variants` map keeps snapshots readable after all programs are removed.
|
|
81
|
+
* CLI commands that execute tests require at least one configured variant.
|
|
82
|
+
*
|
|
83
|
+
* Runs the selected program once per distinct input/expected-value hash, then
|
|
84
|
+
* evaluates its output. Later duplicates are warned about and skipped; the first
|
|
85
|
+
* case's tags are kept. `O` and `T` describe the whole output and expected value;
|
|
86
|
+
* `A` and `B` describe the evaluated values.
|
|
87
|
+
* Without `evaluate`, reuse the same schema for evaluation.result and
|
|
88
|
+
* evaluation.expected. Schema equality produces one result with key `result`.
|
|
24
89
|
*/
|
|
25
90
|
export type TestSuite<I = unknown, O = unknown, T = unknown, E = never, R = never, A = O, B = T> = {
|
|
26
91
|
name: string;
|
|
27
|
-
|
|
28
|
-
schemas
|
|
29
|
-
} & ({
|
|
92
|
+
} & (({
|
|
93
|
+
schemas: TestSuiteSchemas<I, T, A, B>;
|
|
30
94
|
testCases: TestCases<I, T, E, R>;
|
|
31
|
-
program: Program<I, O, E, R>;
|
|
32
95
|
evaluate: Evaluate<O, T, A, B>;
|
|
33
|
-
} | {
|
|
96
|
+
} & TestSuitePrograms<I, O, E, R>) | ({
|
|
97
|
+
schemas: TestSuiteSchemas<I, T & NoInfer<B>, A, B>;
|
|
34
98
|
testCases: TestCases<I, T & NoInfer<B>, E, R>;
|
|
35
|
-
program: Program<I, O & NoInfer<A>, E, R>;
|
|
36
99
|
evaluate?: undefined;
|
|
37
|
-
});
|
|
100
|
+
} & TestSuitePrograms<I, O & NoInfer<A>, E, R>));
|
|
38
101
|
export type TestCase<I, T> = {
|
|
39
102
|
input: I;
|
|
40
103
|
expected: T;
|
|
@@ -75,12 +138,72 @@ export type TestResultPredicate<I, O, T> = (args: {
|
|
|
75
138
|
testResult: TestResult<I, O, T>;
|
|
76
139
|
previousTestResult: Option.Option<TestResult<I, O, T>>;
|
|
77
140
|
}) => boolean;
|
|
141
|
+
export type TestResultComparison<I, A, B> = {
|
|
142
|
+
_tag: 'Matched';
|
|
143
|
+
from: TestResult<I, A, B>;
|
|
144
|
+
to: TestResult<I, A, B>;
|
|
145
|
+
changed: boolean;
|
|
146
|
+
} | {
|
|
147
|
+
_tag: 'OnlyFrom';
|
|
148
|
+
from: TestResult<I, A, B>;
|
|
149
|
+
} | {
|
|
150
|
+
_tag: 'OnlyTo';
|
|
151
|
+
to: TestResult<I, A, B>;
|
|
152
|
+
};
|
|
153
|
+
/** Selects a program without running it or requiring its services. */
|
|
154
|
+
export declare const selectVariant: typeof internal.selectVariant;
|
|
155
|
+
/**
|
|
156
|
+
* Runs only the selected program. Named variants require an explicit selection;
|
|
157
|
+
* a single program uses `default`. Its error and service types include every
|
|
158
|
+
* configured program and the case stream, even when the variant ID is a literal.
|
|
159
|
+
*/
|
|
78
160
|
export declare const all: typeof internal.all;
|
|
161
|
+
/**
|
|
162
|
+
* Compares complete cached runs or committed snapshots without evaluating again.
|
|
163
|
+
* The shared codecs must decode both runs and require no Effect services.
|
|
164
|
+
* Callers decide whether comparing different suites or program versions is meaningful.
|
|
165
|
+
*
|
|
166
|
+
* Results match by case hash and evaluation key. A match changes when its label
|
|
167
|
+
* or evaluated values change. Rows follow `to` order, followed by rows found only
|
|
168
|
+
* in `from`, in `from` order. Empty complete runs are valid comparison endpoints.
|
|
169
|
+
* Resolve missing baselines before calling. Both runs must still exist in their
|
|
170
|
+
* stores; a cached attempt replaced by another execution cannot be read.
|
|
171
|
+
* Incompatible codecs fail with `TestValueError`, which names the stored suite.
|
|
172
|
+
*/
|
|
173
|
+
export declare const compareRuns: typeof internal.compareRuns;
|
|
174
|
+
/**
|
|
175
|
+
* Summarizes all matching results in a complete cached run or snapshot, including
|
|
176
|
+
* unchanged results. Each case contributes its timing once. Empty complete runs
|
|
177
|
+
* have zero counts and no timing values.
|
|
178
|
+
* The shared codecs must still read that run. The caller decides whether the
|
|
179
|
+
* stored values still have the same meaning. Resolve a missing baseline before
|
|
180
|
+
* calling; it differs from an empty run.
|
|
181
|
+
*/
|
|
182
|
+
export declare const summarizeRun: <I, A, B>(args_0: {
|
|
183
|
+
run: TestRun;
|
|
184
|
+
schemas: TestResultSchemas<I, A, B>;
|
|
185
|
+
predicate?: (result: TestResult<I, A, B>) => boolean;
|
|
186
|
+
}) => Effect.Effect<{
|
|
187
|
+
run: {
|
|
188
|
+
readonly id: number;
|
|
189
|
+
readonly name: string;
|
|
190
|
+
readonly variant: string;
|
|
191
|
+
readonly store: "cache";
|
|
192
|
+
readonly state: "Complete" | "Failed" | "Running";
|
|
193
|
+
} | {
|
|
194
|
+
readonly id: number;
|
|
195
|
+
readonly name: string;
|
|
196
|
+
readonly variant: string;
|
|
197
|
+
readonly store: "snapshot";
|
|
198
|
+
readonly state: "Complete";
|
|
199
|
+
};
|
|
200
|
+
stats: Stats;
|
|
201
|
+
}, import("./RepositoryError.ts").RepositoryError, import("./Test.repository.js").TestRepository>;
|
|
79
202
|
export declare const diff: typeof internal.diff;
|
|
80
|
-
export declare const makeSha256: typeof internal.makeSha256;
|
|
81
203
|
/** Builds the lookup key for one evaluation within its original test case. */
|
|
82
204
|
export declare const resultKey: typeof internal.resultKey;
|
|
83
205
|
export declare const runCollectRecord: typeof internal.runCollectRecord;
|
|
84
206
|
/** Keeps matching results and recalculates counts and case timing statistics. */
|
|
85
207
|
export declare const filterResults: typeof internal.filterResults;
|
|
208
|
+
export {};
|
|
86
209
|
//# sourceMappingURL=Test.d.ts.map
|
package/dist/dts/Test.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Test.d.ts","sourceRoot":"","sources":["../../src/Test.ts"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"Test.d.ts","sourceRoot":"","sources":["../../src/Test.ts"],"names":[],"mappings":"AAAA,OAAO,EACH,KAAK,KAAK,EACV,KAAK,MAAM,EACX,KAAK,MAAM,EACX,MAAM,EACN,KAAK,MAAM,EACd,MAAM,QAAQ,CAAC;AAEhB,OAAO,KAAK,EAAC,KAAK,EAAE,KAAK,EAAC,MAAM,eAAe,CAAC;AAChD,OAAO,KAAK,QAAQ,MAAM,oBAAoB,CAAC;AAC/C,OAAO,KAAK,EAAC,OAAO,EAAE,iBAAiB,EAAC,MAAM,sBAAsB,CAAC;AAErE,6EAA6E;AAC7E,MAAM,MAAM,gBAAgB,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,IAAI,iBAAiB,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,GAAG;IACpE,QAAQ,EAAE;QACN,QAAQ,EAAE,MAAM,CAAC,KAAK,CAAC,CAAC,EAAE,OAAO,CAAC,CAAC;KACtC,CAAC;CACL,CAAC;AAEF,MAAM,MAAM,SAAS,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,GAAG,KAAK,EAAE,CAAC,GAAG,KAAK,IAC1C,aAAa,CAAC,QAAQ,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,GAC7B,MAAM,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC;AAE1C,MAAM,MAAM,gBAAgB,CAAC,CAAC,EAAE,CAAC,IAAI;IACjC,wEAAwE;IACxE,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,MAAM,EAAE,CAAC,CAAC;IACnB,QAAQ,CAAC,QAAQ,EAAE,CAAC,CAAC;IACrB,QAAQ,CAAC,KAA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CAAC,CAAC,CAAC,CAAC;CAC1D,KAAK,OAAO,CAAC;AAEd,MAAM,MAAM,oBAAoB,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,IAClC;IACI,IAAI,EAAE,SAAS,CAAC;IAChB,IAAI,EAAE,UAAU,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC;IAC1B,EAAE,EAAE,UAAU,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC;IACxB,OAAO,EAAE,OAAO,CAAC;CACpB,GACD;IAAC,IAAI,EAAE,UAAU,CAAC;IAAC,IAAI,EAAE,UAAU,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAA;CAAC,GAC7C;IAAC,IAAI,EAAE,QAAQ,CAAC;IAAC,EAAE,EAAE,UAAU,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAA;CAAC,CAAC;AAEhD,sEAAsE;AACtE,eAAO,MAAM,aAAa,+BAAyB,CAAC;AAEpD;;;;GAIG;AACH,eAAO,MAAM,GAAG,qBAAe,CAAC;AAChC;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,WAAW,6BAAuB,CAAC;AAChD;;;;;;;GAOG;AACH,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;iGAAwB,CAAC;AAClD,eAAO,MAAM,IAAI,sBAAgB,CAAC;AAClC,8EAA8E;AAC9E,eAAO,MAAM,SAAS,2BAAqB,CAAC;AAC5C,eAAO,MAAM,gBAAgB,kCAA4B,CAAC;AAC1D,iFAAiF;AACjF,eAAO,MAAM,aAAa,+BAAyB,CAAC"}
|
|
@@ -1,12 +1,135 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
import type {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
1
|
+
import { Context, Effect, Layer, type Option, type Schema, type Stream } from 'effect';
|
|
2
|
+
import { SqlClient } from 'effect/sql';
|
|
3
|
+
import type { Stats } from './Classify.js';
|
|
4
|
+
import { TestRepositoryStorage } from './internal/Test.repository.sqlite.js';
|
|
5
|
+
import type { RepositoryError } from './RepositoryError.js';
|
|
6
|
+
import type { TestResult } from './Test.js';
|
|
7
|
+
import type { TestRun } from './TestRun.js';
|
|
8
|
+
export { TestRun } from './TestRun.js';
|
|
9
|
+
type StatsCollector = {
|
|
10
|
+
add: (results: ReadonlyArray<Pick<TestResult, 'hashTestCase' | 'label' | 'timeMillis'>>) => Effect.Effect<void, RepositoryError>;
|
|
11
|
+
stats: Effect.Effect<Stats, RepositoryError>;
|
|
12
|
+
};
|
|
13
|
+
/**
|
|
14
|
+
* Encode and decode stored input and evaluated values. Pass a suite's schemas
|
|
15
|
+
* directly; its whole-case expectation is only needed by the runner.
|
|
16
|
+
* Codecs must be deterministic, preserve equivalent values through JSON, and
|
|
17
|
+
* require no Effect services.
|
|
18
|
+
*/
|
|
19
|
+
export type TestResultSchemas<I = unknown, O = unknown, T = unknown> = {
|
|
20
|
+
testCase: {
|
|
21
|
+
input: Schema.Codec<I, unknown>;
|
|
22
|
+
};
|
|
23
|
+
evaluation: {
|
|
24
|
+
result: Schema.Codec<O, unknown>;
|
|
25
|
+
expected: Schema.Codec<T, unknown>;
|
|
26
|
+
};
|
|
27
|
+
};
|
|
28
|
+
/**
|
|
29
|
+
* Keeps only the latest attempt per snapshot identity, suite, and variant in a
|
|
30
|
+
* disposable cache. A new attempt replaces the previous one, even if it later fails.
|
|
31
|
+
* Only explicit commits write snapshots and baseline pointers. Saved snapshots
|
|
32
|
+
* stay unchanged, and history is never pruned.
|
|
33
|
+
*
|
|
34
|
+
* Reading a missing snapshot file returns no saved runs without creating the file.
|
|
35
|
+
* Unsupported snapshot formats fail without changing the file. Unsupported cache
|
|
36
|
+
* formats are discarded. Neither store has upgrade migrations.
|
|
37
|
+
*/
|
|
38
|
+
export type TestRepositoryShape = {
|
|
39
|
+
/**
|
|
40
|
+
* Read the selected run in pages of 100 results. Cached reads keep the same rows
|
|
41
|
+
* until the stream closes. If the attempt was already replaced, fail instead of
|
|
42
|
+
* reading its successor.
|
|
43
|
+
*/
|
|
44
|
+
getTestResultsStream: <I = unknown, O = unknown, T = unknown>(testRun: TestRun, schemas: TestResultSchemas<I, O, T>,
|
|
45
|
+
/** Match at most 50 case/key pairs per call. Results keep their stored order. */
|
|
46
|
+
matching?: ReadonlyArray<Pick<TestResult, 'hashTestCase' | 'key'>>) => Stream.Stream<TestResult<I, O, T>, RepositoryError>;
|
|
47
|
+
/** Calculate exact statistics in temporary cache tables, then release those tables. */
|
|
48
|
+
withStats: <A, E, R>(use: (collector: StatsCollector) => Effect.Effect<A, E, R>) => Effect.Effect<A, E | RepositoryError, R>;
|
|
49
|
+
/**
|
|
50
|
+
* Replace the latest cached attempt with a new `Running` attempt and call
|
|
51
|
+
* `execute` once. The callback can be interrupted. Save `Complete` after callback
|
|
52
|
+
* success, including empty runs.
|
|
53
|
+
* Save `Failed` after a callback failure, synchronous throw, defect, or
|
|
54
|
+
* interruption. Return success only after saving `Complete`.
|
|
55
|
+
*
|
|
56
|
+
* Database errors propagate. If execution and finalization both fail, preserve
|
|
57
|
+
* both causes. A failed final write or abrupt process exit can leave the attempt
|
|
58
|
+
* `Running`; it cannot be reused or committed.
|
|
59
|
+
*/
|
|
60
|
+
withTestRun: <A, E = never, R = never>(input: {
|
|
61
|
+
name: string;
|
|
62
|
+
variant: string;
|
|
63
|
+
}, execute: (testRun: TestRun) => Effect.Effect<A, E, R>) => Effect.Effect<{
|
|
64
|
+
run: TestRun;
|
|
65
|
+
value: A;
|
|
66
|
+
}, E | RepositoryError, R>;
|
|
67
|
+
/** Read an exact store and ID. A replaced cached attempt is missing. */
|
|
68
|
+
getTestRun: (run: Pick<TestRun, 'store' | 'id'>) => Effect.Effect<Option.Option<TestRun>, RepositoryError>;
|
|
69
|
+
/** Read the latest cached attempt in any state, including a complete empty run. */
|
|
70
|
+
getLatestTestRun: (input: {
|
|
71
|
+
name: string;
|
|
72
|
+
variant: string;
|
|
73
|
+
}) => Effect.Effect<Option.Option<TestRun>, RepositoryError>;
|
|
74
|
+
/**
|
|
75
|
+
* Read the selected snapshot without creating a missing snapshot file.
|
|
76
|
+
* A missing baseline is `None`; a complete empty baseline is `Some`.
|
|
77
|
+
*/
|
|
78
|
+
getBaselineTestRun: (input: {
|
|
79
|
+
name: string;
|
|
80
|
+
variant: string;
|
|
81
|
+
}) => Effect.Effect<Option.Option<TestRun>, RepositoryError>;
|
|
82
|
+
/**
|
|
83
|
+
* Save the exact selected attempts and their baseline pointers in one snapshot
|
|
84
|
+
* transaction. Return snapshots in selection order. Every selected attempt must
|
|
85
|
+
* still exist and be `Complete` before a snapshot writer opens. Each suite and
|
|
86
|
+
* variant may appear only once.
|
|
87
|
+
*
|
|
88
|
+
* Copy stored values, order, tags, and timing without running programs or codecs.
|
|
89
|
+
* A failed transaction leaves all snapshots and baselines unchanged. Recommitting
|
|
90
|
+
* an attempt reuses its execution UUID's snapshot. Selecting a saved snapshot
|
|
91
|
+
* restores its baseline. The cache stays reusable after commit.
|
|
92
|
+
*
|
|
93
|
+
* Close file-backed snapshot writers before returning success, so copying the
|
|
94
|
+
* snapshot file alone preserves the saved results.
|
|
95
|
+
*/
|
|
96
|
+
commitTestRuns: (runs: readonly TestRun[]) => Effect.Effect<readonly TestRun[], RepositoryError>;
|
|
97
|
+
/**
|
|
98
|
+
* List committed snapshots by descending ID, including removed variants.
|
|
99
|
+
* `limit` must be 1–100; the next page has `id < before`.
|
|
100
|
+
*/
|
|
101
|
+
listTestRuns: (input: {
|
|
102
|
+
name: string;
|
|
103
|
+
variant?: string;
|
|
104
|
+
before?: number;
|
|
105
|
+
limit: number;
|
|
106
|
+
}) => Effect.Effect<ReadonlyArray<TestRun & {
|
|
107
|
+
readonly isBaseline: boolean;
|
|
108
|
+
}>, RepositoryError>;
|
|
109
|
+
/** List variants with committed history by name, with each selected baseline. */
|
|
110
|
+
listVariantBaselines: (name: string) => Effect.Effect<ReadonlyArray<{
|
|
111
|
+
variant: string;
|
|
112
|
+
baseline: Option.Option<TestRun>;
|
|
113
|
+
}>, RepositoryError>;
|
|
114
|
+
/** Only `Running` cached attempts accept writes. Complete and failed runs cannot change. */
|
|
115
|
+
insertTestResult: <I, O, T>(input: TestResult<I, O, T>, testRun: TestRun, schemas: TestResultSchemas<I, O, T>) => Effect.Effect<void, RepositoryError>;
|
|
116
|
+
/** Check the stored attempt's state inside each batch transaction before writing. */
|
|
117
|
+
insertTestResults: <I, O, T>(inputs: ReadonlyArray<TestResult<I, O, T>>, testRun: TestRun, schemas: TestResultSchemas<I, O, T>) => Effect.Effect<void, RepositoryError>;
|
|
118
|
+
};
|
|
119
|
+
declare const TestRepository_base: Context.ServiceClass<TestRepository, "@creative-introvert/tons-of-tests/TestRepository", TestRepositoryShape>;
|
|
7
120
|
export declare class TestRepository extends TestRepository_base {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
121
|
+
/**
|
|
122
|
+
* Keep cache rows separate by `snapshotIdentity`, even when repositories share a
|
|
123
|
+
* cache filename. Cache and snapshot paths must refer to different files.
|
|
124
|
+
* With `:memory:`, each store lasts for this layer's lifetime.
|
|
125
|
+
* The caller supplies platform services; `CLI.buildLayer` also resolves paths.
|
|
126
|
+
*/
|
|
127
|
+
static layer(options: {
|
|
128
|
+
readonly dbPath: string;
|
|
129
|
+
readonly cachePath: string;
|
|
130
|
+
readonly snapshotIdentity: string;
|
|
131
|
+
}): Layer.Layer<TestRepository, import("effect/PlatformError").PlatformError | import("./RepositoryError.js").RepositoryFormatError | import("./RepositoryError.js").RepositoryPathConflict | Schema.SchemaError | import("effect/sql/SqlError").SqlError, import("effect/Crypto").Crypto | import("effect/FileSystem").FileSystem | import("effect/Path").Path>;
|
|
132
|
+
/** Use separate in-memory stores and platform services for isolated tests. */
|
|
133
|
+
static readonly TestLayer: Layer.Layer<SqlClient.SqlClient | TestRepository | TestRepositoryStorage, import("effect/PlatformError").PlatformError | import("./RepositoryError.js").RepositoryFormatError | import("./RepositoryError.js").RepositoryPathConflict | Schema.SchemaError | import("effect/sql/SqlError").SqlError, never>;
|
|
11
134
|
}
|
|
12
135
|
//# sourceMappingURL=Test.repository.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Test.repository.d.ts","sourceRoot":"","sources":["../../src/Test.repository.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Test.repository.d.ts","sourceRoot":"","sources":["../../src/Test.repository.ts"],"names":[],"mappings":"AACA,OAAO,EACH,OAAO,EACP,MAAM,EACN,KAAK,EACL,KAAK,MAAM,EACX,KAAK,MAAM,EACX,KAAK,MAAM,EACd,MAAM,QAAQ,CAAC;AAChB,OAAO,EAAC,SAAS,EAAC,MAAM,YAAY,CAAC;AAErC,OAAO,KAAK,EAAC,KAAK,EAAC,MAAM,eAAe,CAAC;AACzC,OAAO,EAEH,qBAAqB,EACxB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,KAAK,EAAC,eAAe,EAAC,MAAM,sBAAsB,CAAC;AAC1D,OAAO,KAAK,EAAC,UAAU,EAAC,MAAM,WAAW,CAAC;AAC1C,OAAO,KAAK,EAAC,OAAO,EAAC,MAAM,cAAc,CAAC;AAE1C,OAAO,EAAC,OAAO,EAAC,MAAM,cAAc,CAAC;AAErC,KAAK,cAAc,GAAG;IAClB,GAAG,EAAE,CACD,OAAO,EAAE,aAAa,CAClB,IAAI,CAAC,UAAU,EAAE,cAAc,GAAG,OAAO,GAAG,YAAY,CAAC,CAC5D,KACA,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,eAAe,CAAC,CAAC;IAC1C,KAAK,EAAE,MAAM,CAAC,MAAM,CAAC,KAAK,EAAE,eAAe,CAAC,CAAC;CAChD,CAAC;AAEF;;;;;GAKG;AACH,MAAM,MAAM,iBAAiB,CAAC,CAAC,GAAG,OAAO,EAAE,CAAC,GAAG,OAAO,EAAE,CAAC,GAAG,OAAO,IAAI;IACnE,QAAQ,EAAE;QAAC,KAAK,EAAE,MAA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|
+
/**
|
|
3
|
+
* Identify a run by both `store` and `id`; the two stores can use the same ID.
|
|
4
|
+
* A new execution replaces the cached attempt for its snapshot identity, suite,
|
|
5
|
+
* and variant. Complete attempts, including empty ones, can be reused or committed.
|
|
6
|
+
* Committed snapshots stay unchanged after a program changes or is removed.
|
|
7
|
+
*/
|
|
8
|
+
export declare const TestRun: Schema.Union<readonly [Schema.Struct<{
|
|
9
|
+
readonly id: Schema.Int;
|
|
10
|
+
readonly name: Schema.String;
|
|
11
|
+
readonly variant: Schema.String;
|
|
12
|
+
readonly store: Schema.Literal<"cache">;
|
|
13
|
+
readonly state: Schema.Literals<readonly ["Running", "Complete", "Failed"]>;
|
|
14
|
+
}>, Schema.Struct<{
|
|
15
|
+
readonly id: Schema.Int;
|
|
16
|
+
readonly name: Schema.String;
|
|
17
|
+
readonly variant: Schema.String;
|
|
18
|
+
readonly store: Schema.Literal<"snapshot">;
|
|
19
|
+
readonly state: Schema.Literal<"Complete">;
|
|
20
|
+
}>]>;
|
|
21
|
+
export type TestRun = typeof TestRun.Type;
|
|
22
|
+
//# sourceMappingURL=TestRun.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TestRun.d.ts","sourceRoot":"","sources":["../../src/TestRun.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,MAAM,EAAC,MAAM,QAAQ,CAAC;AAQ9B;;;;;GAKG;AACH,eAAO,MAAM,OAAO;;;;;;;;;;;;IAWlB,CAAC;AACH,MAAM,MAAM,OAAO,GAAG,OAAO,OAAO,CAAC,IAAI,CAAC"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { Schema } from 'effect';
|
|
2
|
+
declare const TestValueError_base: Schema.Class<TestValueError, Schema.TaggedStruct<"TestValueError", {
|
|
3
|
+
readonly suite: Schema.String;
|
|
4
|
+
readonly caseNumber: Schema.Int;
|
|
5
|
+
readonly key: Schema.optionalKey<Schema.String>;
|
|
6
|
+
readonly field: Schema.Literals<readonly ["testCase.input", "testCase.expected", "evaluation.result", "evaluation.expected"]>;
|
|
7
|
+
readonly operation: Schema.Literals<readonly ["encode", "decode", "roundTrip"]>;
|
|
8
|
+
readonly cause: Schema.instanceOf<Schema.SchemaError, unknown>;
|
|
9
|
+
}>, import("effect/Cause").YieldableError & {
|
|
10
|
+
readonly brand: unique symbol;
|
|
11
|
+
}>;
|
|
12
|
+
/** A suite value could not be converted without losing information. */
|
|
13
|
+
export declare class TestValueError extends TestValueError_base {
|
|
14
|
+
get message(): string;
|
|
15
|
+
}
|
|
16
|
+
export {};
|
|
17
|
+
//# sourceMappingURL=TestValueError.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TestValueError.d.ts","sourceRoot":"","sources":["../../src/TestValueError.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,MAAM,EAAC,MAAM,QAAQ,CAAC;;;;;;;;;oBAKT,OAAO,MAAM;;AAHlC,uEAAuE;AACvE,qBAAa,cAAe,SAAQ,mBAelC;IACE,IAAa,OAAO,WAGnB;CACJ"}
|
package/dist/dts/index.d.ts
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
export * as Classify from './Classify.js';
|
|
2
2
|
export * as DisplayConfig from './DisplayConfig.js';
|
|
3
3
|
export * as Error from './RepositoryError.js';
|
|
4
|
-
export { pack } from './internal/pack.js';
|
|
5
4
|
export * as Show from './Show.js';
|
|
6
5
|
export * as Test from './Test.js';
|
|
7
6
|
export * as TestRepository from './Test.repository.js';
|
package/dist/dts/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,QAAQ,MAAM,eAAe,CAAC;AAC1C,OAAO,KAAK,aAAa,MAAM,oBAAoB,CAAC;AACpD,OAAO,KAAK,KAAK,MAAM,sBAAsB,CAAC;AAC9C,OAAO,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,QAAQ,MAAM,eAAe,CAAC;AAC1C,OAAO,KAAK,aAAa,MAAM,oBAAoB,CAAC;AACpD,OAAO,KAAK,KAAK,MAAM,sBAAsB,CAAC;AAC9C,OAAO,KAAK,IAAI,MAAM,WAAW,CAAC;AAClC,OAAO,KAAK,IAAI,MAAM,WAAW,CAAC;AAClC,OAAO,KAAK,cAAc,MAAM,sBAAsB,CAAC"}
|
|
@@ -7,7 +7,6 @@ export declare const values: {
|
|
|
7
7
|
readonly FN: 'FN';
|
|
8
8
|
};
|
|
9
9
|
export declare const LabelSchema: Schema.Literals<readonly ["TP", "TN", "FP", "FN"]>;
|
|
10
|
-
export declare const defaultIsEqual: <A, B>(a: A, b: B) => boolean;
|
|
11
10
|
export declare const defaultIsNil: <I>(x: I) => boolean;
|
|
12
11
|
export declare const makeClassify: <O, T>({ isEqual, isOutputNil, isExpectedNil, }: {
|
|
13
12
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Classify.d.ts","sourceRoot":"","sources":["../../../src/internal/Classify.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Classify.d.ts","sourceRoot":"","sources":["../../../src/internal/Classify.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,MAAM,EAAE,MAAM,EAAC,MAAM,QAAQ,CAAC;AAEtC,OAAO,KAAK,EAAC,QAAQ,IAAI,SAAS,EAAC,MAAM,gBAAgB,CAAC;AAE1D,eAAO,MAAM,MAAM;aACf,EAAE,EAAE,IAAI;aACR,EAAE,EAAE,IAAI;aACR,EAAE,EAAE,IAAI;aACR,EAAE,EAAE,IAAI;CACF,CAAC;AAEX,eAAO,MAAM,WAAW,oDAA4C,CAAC;AAErE,eAAO,MAAM,YAAY,GAAI,CAAC,KAAK,CAAC,KAAG,OAAwC,CAAC;AAEhF,eAAO,MAAM,YAAY,GACpB,CAAC,EAAE,CAAC,4CAIF;IACC;;;;OAIG;IACH,OAAO,EAAE,CAAC,MAAM,EAAE,CAAC,EAAE,QAAQ,EAAE,CAAC,KAAK,OAAO,CAAC;IAC7C,WAAW,CAAC,EAAE,CAAC,MAAM,EAAE,CAAC,KAAK,OAAO,CAAC;IACrC,aAAa,CAAC,EAAE,CAAC,QAAQ,EAAE,CAAC,KAAK,OAAO,CAAC;CAC5C,KAAG,SAAS,CAAC,CAAC,EAAE,CAAC,CAkBjB,CAAC;AAEN,eAAO,MAAM,SAAS,MAAO;IAAC,EAAE,EAAE,MAAM,CAAC;IAAC,EAAE,EAAE,MAAM,CAAA;CAAC,KAAG,MAGvD,CAAC;AAEF,eAAO,MAAM,MAAM,MAAO;IAAC,EAAE,EAAE,MAAM,CAAC;IAAC,EAAE,EAAE,MAAM,CAAA;CAAC,KAAG,MAGpD,CAAC;AAEF,eAAO,MAAM,GAAG,OAAQ,MAAM,EAAE,KAAG,MACqC,CAAC;AAEzE,eAAO,MAAM,GAAG,OAAQ,MAAM,EAAE,KAAG,MACqC,CAAC;AAEzE,eAAO,MAAM,IAAI,OAAQ,MAAM,EAAE,KAAG,MAAM,GAAG,SAM5C,CAAC;AAEF,eAAO,MAAM,MAAM,OAAQ,MAAM,EAAE,KAAG,MAAM,CAAC,MAAM,CAAC,MAAM,CAczD,CAAC"}
|
|
@@ -1,51 +1,85 @@
|
|
|
1
1
|
import { Effect, Option, Schema, Stream } from 'effect';
|
|
2
|
-
import
|
|
3
|
-
import type {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
ordering: number;
|
|
11
|
-
resultOrdering: number;
|
|
12
|
-
label: import("../Classify.js").Label;
|
|
13
|
-
input: I;
|
|
14
|
-
result: O;
|
|
15
|
-
expected: T;
|
|
16
|
-
tags: readonly string[];
|
|
17
|
-
timeMillis: number;
|
|
18
|
-
};
|
|
19
|
-
};
|
|
2
|
+
import { Stats } from '../Classify.js';
|
|
3
|
+
import type { Diff, Evaluate, InferTestSuite, Program, SelectedProgram, TestCase, TestResult, TestResultComparison, TestRunResults, TestSuite, TestSuiteError, TestSuitePrograms, TestSuiteServices } from '../Test.js';
|
|
4
|
+
import { TestVariantNotFound, TestVariantRequired } from '../Test.js';
|
|
5
|
+
import { TestRepository, type TestResultSchemas, type TestRun } from '../Test.repository.js';
|
|
6
|
+
import type { TestValueError } from '../TestValueError.js';
|
|
7
|
+
import { makeResultCodec } from './Test.serialization.js';
|
|
8
|
+
/** Hash already encoded JSON. Object key order does not affect identity. */
|
|
9
|
+
export declare const makeSha256: (input: Schema.Json) => string;
|
|
20
10
|
export declare const resultKey: ({ hashTestCase, key, }: Pick<TestResult, 'hashTestCase' | 'key'>) => string;
|
|
21
|
-
export declare const TestResultSchema: Schema.Codec<TestResult>;
|
|
22
11
|
export declare const test: <I, O, T, E, R, A, B>(args_0: {
|
|
23
12
|
testCase: TestCase<I, T> & {
|
|
24
13
|
ordering: number;
|
|
25
14
|
};
|
|
15
|
+
hashTestCase: string;
|
|
26
16
|
program: Program<I, O, E, R>;
|
|
27
17
|
evaluate: Evaluate<O, T, A, B>;
|
|
28
|
-
|
|
29
|
-
|
|
18
|
+
encodeResult: ReturnType<typeof makeResultCodec<I, A, B>>['encode'];
|
|
19
|
+
}) => Effect.Effect<[{
|
|
30
20
|
hashTestCase: string;
|
|
31
|
-
key: string;
|
|
32
21
|
ordering: number;
|
|
33
22
|
resultOrdering: number;
|
|
34
|
-
label: import("../Classify.js").Label;
|
|
35
23
|
input: I;
|
|
24
|
+
tags: string[];
|
|
25
|
+
timeMillis: number;
|
|
26
|
+
id: string;
|
|
27
|
+
key: string;
|
|
36
28
|
result: A;
|
|
37
29
|
expected: B;
|
|
38
|
-
|
|
30
|
+
label: import("../Classify.js").Label;
|
|
31
|
+
}, ...{
|
|
32
|
+
hashTestCase: string;
|
|
33
|
+
ordering: number;
|
|
34
|
+
resultOrdering: number;
|
|
35
|
+
input: I;
|
|
36
|
+
tags: string[];
|
|
39
37
|
timeMillis: number;
|
|
40
|
-
|
|
41
|
-
|
|
38
|
+
id: string;
|
|
39
|
+
key: string;
|
|
40
|
+
result: A;
|
|
41
|
+
expected: B;
|
|
42
|
+
label: import("../Classify.js").Label;
|
|
43
|
+
}[]], E | TestValueError, R>;
|
|
44
|
+
export declare function selectVariant<S extends {
|
|
45
|
+
name: string;
|
|
46
|
+
} & TestSuitePrograms<never, unknown, unknown, unknown>>(suite: S, variant?: string): Effect.Effect<{
|
|
47
|
+
name: string;
|
|
48
|
+
program: SelectedProgram<S>;
|
|
49
|
+
}, TestVariantRequired | TestVariantNotFound>;
|
|
50
|
+
export declare function all<I, O, T, A = O, B = T, S = never>(suite: TestSuite<I, O, T, unknown, unknown, A, B> & InferTestSuite<S>, options?: {
|
|
51
|
+
variant?: string | undefined;
|
|
42
52
|
concurrency?: number | undefined;
|
|
43
|
-
})
|
|
53
|
+
}): Stream.Stream<TestResult<I, A, B>, TestSuiteError<S> | TestValueError | TestVariantRequired | TestVariantNotFound, TestSuiteServices<S>>;
|
|
44
54
|
export declare const runCollectRecord: (testRun: TestRun) => <I, O, T, E, R>(testResults$: Stream.Stream<TestResult<I, O, T>, E, R>) => Effect.Effect<TestRunResults<I, O, T>, E, R>;
|
|
45
55
|
export declare const filterResults: <I, O, T>(testRun: TestRunResults<I, O, T>, predicate: (result: TestResult<I, O, T>) => boolean) => TestRunResults<I, O, T>;
|
|
46
56
|
export declare const diff: ({ testRun: { stats }, previousTestRun, }: {
|
|
47
|
-
testRun: TestRunResults
|
|
48
|
-
previousTestRun: Option.Option<TestRunResults
|
|
57
|
+
testRun: Pick<TestRunResults, 'stats'>;
|
|
58
|
+
previousTestRun: Option.Option<Pick<TestRunResults, 'stats'>>;
|
|
49
59
|
}) => Diff;
|
|
50
|
-
export {}
|
|
60
|
+
export declare const compareRuns: <I, A, B>({ from, to, schemas, }: {
|
|
61
|
+
from: TestRun;
|
|
62
|
+
to: TestRun;
|
|
63
|
+
schemas: TestResultSchemas<I, A, B>;
|
|
64
|
+
}) => Stream.Stream<TestResultComparison<I, A, B>, import("../RepositoryError.js").RepositoryError, TestRepository>;
|
|
65
|
+
export declare const summarizeRun: <I, A, B>(args_0: {
|
|
66
|
+
run: TestRun;
|
|
67
|
+
schemas: TestResultSchemas<I, A, B>;
|
|
68
|
+
predicate?: (result: TestResult<I, A, B>) => boolean;
|
|
69
|
+
}) => Effect.Effect<{
|
|
70
|
+
run: {
|
|
71
|
+
readonly id: number;
|
|
72
|
+
readonly name: string;
|
|
73
|
+
readonly variant: string;
|
|
74
|
+
readonly store: "cache";
|
|
75
|
+
readonly state: "Complete" | "Failed" | "Running";
|
|
76
|
+
} | {
|
|
77
|
+
readonly id: number;
|
|
78
|
+
readonly name: string;
|
|
79
|
+
readonly variant: string;
|
|
80
|
+
readonly store: "snapshot";
|
|
81
|
+
readonly state: "Complete";
|
|
82
|
+
};
|
|
83
|
+
stats: Stats;
|
|
84
|
+
}, import("../RepositoryError.js").RepositoryError, TestRepository>;
|
|
51
85
|
//# sourceMappingURL=Test.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Test.d.ts","sourceRoot":"","sources":["../../../src/internal/Test.ts"],"names":[],"mappings":"AACA,OAAO,EAAQ,MAAM,EAAE,MAAM,EAAQ,MAAM,EAAQ,MAAM,EAAC,MAAM,QAAQ,CAAC;
|
|
1
|
+
{"version":3,"file":"Test.d.ts","sourceRoot":"","sources":["../../../src/internal/Test.ts"],"names":[],"mappings":"AACA,OAAO,EAAQ,MAAM,EAAE,MAAM,EAAQ,MAAM,EAAQ,MAAM,EAAC,MAAM,QAAQ,CAAC;AAEzE,OAAO,EAAC,KAAK,EAAC,MAAM,gBAAgB,CAAC;AACrC,OAAO,KAAK,EACR,IAAI,EACJ,QAAQ,EACR,cAAc,EACd,OAAO,EACP,eAAe,EACf,QAAQ,EACR,UAAU,EACV,oBAAoB,EACpB,cAAc,EACd,SAAS,EACT,cAAc,E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