@vitest-agent/ui 2.3.0 → 2.3.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/index.d.ts +65 -65
- package/index.js +1 -1
- package/package.json +3 -3
package/index.d.ts
CHANGED
|
@@ -41,7 +41,7 @@ type FileCoverageReport = typeof FileCoverageReport.Type;
|
|
|
41
41
|
* Per-test record accumulated as `TestStarted` / `TestFinished` events arrive.
|
|
42
42
|
* @public
|
|
43
43
|
*/
|
|
44
|
-
declare const TestRecord: Schema.Struct<{
|
|
44
|
+
export declare const TestRecord: Schema.Struct<{
|
|
45
45
|
readonly testName: Schema.String;
|
|
46
46
|
readonly suitePath: Schema.$Array<Schema.String>;
|
|
47
47
|
readonly status: Schema.Union<readonly [Schema.Literals<readonly ["passed", "failed", "skipped", "pending"]>, Schema.Literals<readonly ["running", "timed-out"]>]>;
|
|
@@ -55,13 +55,13 @@ declare const TestRecord: Schema.Struct<{
|
|
|
55
55
|
}>>;
|
|
56
56
|
}>;
|
|
57
57
|
/** @public */
|
|
58
|
-
type TestRecord = typeof TestRecord.Type;
|
|
58
|
+
export type TestRecord = typeof TestRecord.Type;
|
|
59
59
|
/**
|
|
60
60
|
* Per-module aggregation. The reducer keeps modules keyed on
|
|
61
61
|
* `modulePath` so out-of-order events can update the right slot.
|
|
62
62
|
* @public
|
|
63
63
|
*/
|
|
64
|
-
declare const ModuleRecord: Schema.Struct<{
|
|
64
|
+
export declare const ModuleRecord: Schema.Struct<{
|
|
65
65
|
readonly modulePath: Schema.String;
|
|
66
66
|
readonly status: Schema.Literals<readonly ["queued", "running", "finished"]>;
|
|
67
67
|
readonly passCount: Schema.Number;
|
|
@@ -98,14 +98,14 @@ declare const ModuleRecord: Schema.Struct<{
|
|
|
98
98
|
readonly tagCounts: Schema.optional<Schema.$Record<Schema.String, Schema.Number>>;
|
|
99
99
|
}>;
|
|
100
100
|
/** @public */
|
|
101
|
-
type ModuleRecord = typeof ModuleRecord.Type;
|
|
101
|
+
export type ModuleRecord = typeof ModuleRecord.Type;
|
|
102
102
|
/**
|
|
103
103
|
* One row in the failure list. A failure can exist before its
|
|
104
104
|
* classification arrives (`FailureClassified` is emitted from a
|
|
105
105
|
* separate pipeline), so `classification` is nullable.
|
|
106
106
|
* @public
|
|
107
107
|
*/
|
|
108
|
-
declare const FailureRecord: Schema.Struct<{
|
|
108
|
+
export declare const FailureRecord: Schema.Struct<{
|
|
109
109
|
readonly modulePath: Schema.String;
|
|
110
110
|
readonly testName: Schema.String;
|
|
111
111
|
readonly suitePath: Schema.$Array<Schema.String>;
|
|
@@ -120,13 +120,13 @@ declare const FailureRecord: Schema.Struct<{
|
|
|
120
120
|
readonly classification: Schema.NullOr<Schema.Literals<readonly ["stable", "new-failure", "persistent", "flaky", "recovered"]>>;
|
|
121
121
|
}>;
|
|
122
122
|
/** @public */
|
|
123
|
-
type FailureRecord = typeof FailureRecord.Type;
|
|
123
|
+
export type FailureRecord = typeof FailureRecord.Type;
|
|
124
124
|
/**
|
|
125
125
|
* Coverage block, populated only after `CoverageReady`. Threshold
|
|
126
126
|
* violations are accumulated separately as they arrive.
|
|
127
127
|
* @public
|
|
128
128
|
*/
|
|
129
|
-
declare const CoverageRenderState: Schema.Struct<{
|
|
129
|
+
export declare const CoverageRenderState: Schema.Struct<{
|
|
130
130
|
readonly metrics: Schema.Struct<{
|
|
131
131
|
readonly statements: Schema.Number;
|
|
132
132
|
readonly branches: Schema.Number;
|
|
@@ -159,25 +159,25 @@ declare const CoverageRenderState: Schema.Struct<{
|
|
|
159
159
|
readonly totalFiles: Schema.optional<Schema.Number>;
|
|
160
160
|
}>;
|
|
161
161
|
/** @public */
|
|
162
|
-
type CoverageRenderState = typeof CoverageRenderState.Type;
|
|
162
|
+
export type CoverageRenderState = typeof CoverageRenderState.Type;
|
|
163
163
|
/**
|
|
164
164
|
* A `SuggestedAction` event, denormalized into the queue the renderer reads.
|
|
165
165
|
* @public
|
|
166
166
|
*/
|
|
167
|
-
declare const SuggestedActionRecord: Schema.Struct<{
|
|
167
|
+
export declare const SuggestedActionRecord: Schema.Struct<{
|
|
168
168
|
readonly severity: Schema.Literals<readonly ["info", "warn", "blocker"]>;
|
|
169
169
|
readonly title: Schema.String;
|
|
170
170
|
readonly detail: Schema.String;
|
|
171
171
|
readonly targetTool: Schema.optional<Schema.String>;
|
|
172
172
|
}>;
|
|
173
173
|
/** @public */
|
|
174
|
-
type SuggestedActionRecord = typeof SuggestedActionRecord.Type;
|
|
174
|
+
export type SuggestedActionRecord = typeof SuggestedActionRecord.Type;
|
|
175
175
|
/**
|
|
176
176
|
* Per-run totals, recomputed on every `ModuleFinished` and reconciled
|
|
177
177
|
* against `RunFinished` (which carries the runner's own count).
|
|
178
178
|
* @public
|
|
179
179
|
*/
|
|
180
|
-
declare const RenderTotals: Schema.Struct<{
|
|
180
|
+
export declare const RenderTotals: Schema.Struct<{
|
|
181
181
|
readonly passCount: Schema.Number;
|
|
182
182
|
readonly failCount: Schema.Number;
|
|
183
183
|
readonly skipCount: Schema.Number;
|
|
@@ -185,7 +185,7 @@ declare const RenderTotals: Schema.Struct<{
|
|
|
185
185
|
readonly durationMs: Schema.Number;
|
|
186
186
|
}>;
|
|
187
187
|
/** @public */
|
|
188
|
-
type RenderTotals = typeof RenderTotals.Type;
|
|
188
|
+
export type RenderTotals = typeof RenderTotals.Type;
|
|
189
189
|
/**
|
|
190
190
|
* The renderer state. Both the human (Ink) and agent (string)
|
|
191
191
|
* renderers read this shape; the reducer is the only producer.
|
|
@@ -197,7 +197,7 @@ type RenderTotals = typeof RenderTotals.Type;
|
|
|
197
197
|
* rather than the suite completing.
|
|
198
198
|
* @public
|
|
199
199
|
*/
|
|
200
|
-
declare const RenderState: Schema.Struct<{
|
|
200
|
+
export declare const RenderState: Schema.Struct<{
|
|
201
201
|
readonly phase: Schema.Literals<readonly ["idle", "running", "finished", "timed-out"]>;
|
|
202
202
|
readonly runId: Schema.NullOr<Schema.String>;
|
|
203
203
|
readonly configHash: Schema.NullOr<Schema.String>;
|
|
@@ -328,14 +328,14 @@ declare const RenderState: Schema.Struct<{
|
|
|
328
328
|
}>>;
|
|
329
329
|
}>;
|
|
330
330
|
/** @public */
|
|
331
|
-
type RenderState = typeof RenderState.Type;
|
|
331
|
+
export type RenderState = typeof RenderState.Type;
|
|
332
332
|
/**
|
|
333
333
|
* Initial state — what the reducer returns when no events have been
|
|
334
334
|
* applied yet. Exported so tests and the renderers' bootstrapping
|
|
335
335
|
* code share one definition.
|
|
336
336
|
* @public
|
|
337
337
|
*/
|
|
338
|
-
declare const initialRenderState: RenderState;
|
|
338
|
+
export declare const initialRenderState: RenderState;
|
|
339
339
|
//#endregion
|
|
340
340
|
//#region src/contracts/dispatcher.d.ts
|
|
341
341
|
/**
|
|
@@ -629,22 +629,22 @@ type TestClassification = typeof TestClassification.Type;
|
|
|
629
629
|
* Coverage metric whose threshold can be violated independently.
|
|
630
630
|
* @public
|
|
631
631
|
*/
|
|
632
|
-
declare const CoverageMetric: Schema.Literals<readonly ["lines", "branches", "functions", "statements"]>;
|
|
632
|
+
export declare const CoverageMetric: Schema.Literals<readonly ["lines", "branches", "functions", "statements"]>;
|
|
633
633
|
/** @public */
|
|
634
|
-
type CoverageMetric = typeof CoverageMetric.Type;
|
|
634
|
+
export type CoverageMetric = typeof CoverageMetric.Type;
|
|
635
635
|
/**
|
|
636
636
|
* Severity tier for a suggested action emitted during a run.
|
|
637
637
|
* @public
|
|
638
638
|
*/
|
|
639
|
-
declare const ActionSeverity: Schema.Literals<readonly ["info", "warn", "blocker"]>;
|
|
639
|
+
export declare const ActionSeverity: Schema.Literals<readonly ["info", "warn", "blocker"]>;
|
|
640
640
|
/** @public */
|
|
641
|
-
type ActionSeverity = typeof ActionSeverity.Type;
|
|
641
|
+
export type ActionSeverity = typeof ActionSeverity.Type;
|
|
642
642
|
/**
|
|
643
643
|
* A coverage gap surfaced to the renderer — a per-file shortfall that
|
|
644
644
|
* a renderer may want to call out individually.
|
|
645
645
|
* @public
|
|
646
646
|
*/
|
|
647
|
-
declare const CoverageGap: Schema.Struct<{
|
|
647
|
+
export declare const CoverageGap: Schema.Struct<{
|
|
648
648
|
readonly file: Schema.String;
|
|
649
649
|
readonly missing: Schema.Struct<{
|
|
650
650
|
readonly statements: Schema.Number;
|
|
@@ -655,7 +655,7 @@ declare const CoverageGap: Schema.Struct<{
|
|
|
655
655
|
readonly uncoveredLines: Schema.optional<Schema.String>;
|
|
656
656
|
}>;
|
|
657
657
|
/** @public */
|
|
658
|
-
type CoverageGap = typeof CoverageGap.Type;
|
|
658
|
+
export type CoverageGap = typeof CoverageGap.Type;
|
|
659
659
|
/**
|
|
660
660
|
* The reducer projects this union into `RenderState`. Renderers
|
|
661
661
|
* never read the raw event stream — they read the projected state.
|
|
@@ -666,7 +666,7 @@ type CoverageGap = typeof CoverageGap.Type;
|
|
|
666
666
|
* been updated to consume the new state shape.
|
|
667
667
|
* @public
|
|
668
668
|
*/
|
|
669
|
-
declare const RunEvent: Schema.Union<readonly [Schema.TaggedStruct<"RunStarted", {
|
|
669
|
+
export declare const RunEvent: Schema.Union<readonly [Schema.TaggedStruct<"RunStarted", {
|
|
670
670
|
readonly runId: Schema.String;
|
|
671
671
|
readonly startedAt: Schema.String;
|
|
672
672
|
readonly configHash: Schema.String;
|
|
@@ -830,7 +830,7 @@ declare const RunEvent: Schema.Union<readonly [Schema.TaggedStruct<"RunStarted",
|
|
|
830
830
|
}>>>;
|
|
831
831
|
}>]>;
|
|
832
832
|
/** @public */
|
|
833
|
-
type RunEvent = typeof RunEvent.Type;
|
|
833
|
+
export type RunEvent = typeof RunEvent.Type;
|
|
834
834
|
/**
|
|
835
835
|
* Convenience: discriminator-keyed map of the individual variants.
|
|
836
836
|
*
|
|
@@ -1044,7 +1044,7 @@ interface Cell {
|
|
|
1044
1044
|
* @returns the run shape classification
|
|
1045
1045
|
* @public
|
|
1046
1046
|
*/
|
|
1047
|
-
declare const classifyRunShape: (state: RenderState, projects: ReadonlyArray<ProjectSummary>) => RunShape;
|
|
1047
|
+
export declare const classifyRunShape: (state: RenderState, projects: ReadonlyArray<ProjectSummary>) => RunShape;
|
|
1048
1048
|
/**
|
|
1049
1049
|
* Compute the outcome class from the reduced state.
|
|
1050
1050
|
*
|
|
@@ -1065,7 +1065,7 @@ declare const classifyRunShape: (state: RenderState, projects: ReadonlyArray<Pro
|
|
|
1065
1065
|
* @returns the outcome classification
|
|
1066
1066
|
* @public
|
|
1067
1067
|
*/
|
|
1068
|
-
declare const classifyOutcome: (state: RenderState) => RunOutcome;
|
|
1068
|
+
export declare const classifyOutcome: (state: RenderState) => RunOutcome;
|
|
1069
1069
|
//#endregion
|
|
1070
1070
|
//#region src/dispatcher/dispatch.d.ts
|
|
1071
1071
|
/**
|
|
@@ -1075,7 +1075,7 @@ declare const classifyOutcome: (state: RenderState) => RunOutcome;
|
|
|
1075
1075
|
*
|
|
1076
1076
|
* @public
|
|
1077
1077
|
*/
|
|
1078
|
-
declare const dispatcherTable: Readonly<Record<RunShape, Readonly<Record<RunOutcome, Cell>>>>;
|
|
1078
|
+
export declare const dispatcherTable: Readonly<Record<RunShape, Readonly<Record<RunOutcome, Cell>>>>;
|
|
1079
1079
|
/**
|
|
1080
1080
|
* Dispatch to the cell that matches `(inputs.shape, inputs.outcome)`
|
|
1081
1081
|
* and return its agent-half string output.
|
|
@@ -1085,7 +1085,7 @@ declare const dispatcherTable: Readonly<Record<RunShape, Readonly<Record<RunOutc
|
|
|
1085
1085
|
* @returns the agent-string output for the matched cell
|
|
1086
1086
|
* @public
|
|
1087
1087
|
*/
|
|
1088
|
-
declare const dispatch: (inputs: DispatchInputs, opts: CellOptions) => string;
|
|
1088
|
+
export declare const dispatch: (inputs: DispatchInputs, opts: CellOptions) => string;
|
|
1089
1089
|
/**
|
|
1090
1090
|
* Dispatch to the cell that matches `(inputs.shape, inputs.outcome)`
|
|
1091
1091
|
* and return its Ink-half React tree. Returns `null` when the matched
|
|
@@ -1097,7 +1097,7 @@ declare const dispatch: (inputs: DispatchInputs, opts: CellOptions) => string;
|
|
|
1097
1097
|
* @returns the Ink React element, or `null` when the cell has no Ink half
|
|
1098
1098
|
* @public
|
|
1099
1099
|
*/
|
|
1100
|
-
declare const dispatchInk: (inputs: DispatchInputs, opts: CellOptions) => ReactElement | null;
|
|
1100
|
+
export declare const dispatchInk: (inputs: DispatchInputs, opts: CellOptions) => ReactElement | null;
|
|
1101
1101
|
//#endregion
|
|
1102
1102
|
//#region src/dispatcher/footer.d.ts
|
|
1103
1103
|
/**
|
|
@@ -1111,7 +1111,7 @@ declare const dispatchInk: (inputs: DispatchInputs, opts: CellOptions) => ReactE
|
|
|
1111
1111
|
* @returns the most actionable classification, or `null` when none applies
|
|
1112
1112
|
* @public
|
|
1113
1113
|
*/
|
|
1114
|
-
declare const dominantClassification: (state: RenderState) => TestClassification | null;
|
|
1114
|
+
export declare const dominantClassification: (state: RenderState) => TestClassification | null;
|
|
1115
1115
|
/**
|
|
1116
1116
|
* Compose the trailing footer lines for a dispatcher cell. Returns an
|
|
1117
1117
|
* empty string when no pointer applies. The footer starts with a
|
|
@@ -1122,7 +1122,7 @@ declare const dominantClassification: (state: RenderState) => TestClassification
|
|
|
1122
1122
|
* @returns the footer string, or an empty string when no pointer applies
|
|
1123
1123
|
* @public
|
|
1124
1124
|
*/
|
|
1125
|
-
declare const buildFooter: (inputs: DispatchInputs) => string;
|
|
1125
|
+
export declare const buildFooter: (inputs: DispatchInputs) => string;
|
|
1126
1126
|
//#endregion
|
|
1127
1127
|
//#region src/format-duration.d.ts
|
|
1128
1128
|
/**
|
|
@@ -1150,7 +1150,7 @@ declare const buildFooter: (inputs: DispatchInputs) => string;
|
|
|
1150
1150
|
* @returns formatted duration string
|
|
1151
1151
|
* @public
|
|
1152
1152
|
*/
|
|
1153
|
-
declare const formatDisplayDuration: (ms: number) => string;
|
|
1153
|
+
export declare const formatDisplayDuration: (ms: number) => string;
|
|
1154
1154
|
//#endregion
|
|
1155
1155
|
//#region src/pubsub/Channel.d.ts
|
|
1156
1156
|
declare const RunEventChannel_base: Context.ServiceClass<RunEventChannel, "vitest-agent-ui/RunEventChannel", PubSub.PubSub<{
|
|
@@ -1336,7 +1336,7 @@ declare const RunEventChannel_base: Context.ServiceClass<RunEventChannel, "vites
|
|
|
1336
1336
|
*
|
|
1337
1337
|
* @public
|
|
1338
1338
|
*/
|
|
1339
|
-
declare class RunEventChannel extends RunEventChannel_base {}
|
|
1339
|
+
export declare class RunEventChannel extends RunEventChannel_base {}
|
|
1340
1340
|
/**
|
|
1341
1341
|
* Default live layer providing an unbounded Effect `PubSub` for
|
|
1342
1342
|
* the run-event channel. The PubSub is scoped — when the surrounding
|
|
@@ -1352,7 +1352,7 @@ declare class RunEventChannel extends RunEventChannel_base {}
|
|
|
1352
1352
|
*
|
|
1353
1353
|
* @public
|
|
1354
1354
|
*/
|
|
1355
|
-
declare const RunEventChannelLive: Layer.Layer<RunEventChannel>;
|
|
1355
|
+
export declare const RunEventChannelLive: Layer.Layer<RunEventChannel>;
|
|
1356
1356
|
//#endregion
|
|
1357
1357
|
//#region src/pubsub/Publisher.d.ts
|
|
1358
1358
|
/**
|
|
@@ -1366,7 +1366,7 @@ declare const RunEventChannelLive: Layer.Layer<RunEventChannel>;
|
|
|
1366
1366
|
* @returns an Effect that resolves to the publish success boolean
|
|
1367
1367
|
* @public
|
|
1368
1368
|
*/
|
|
1369
|
-
declare const publish: (event: RunEvent) => Effect.Effect<boolean, never, RunEventChannel>;
|
|
1369
|
+
export declare const publish: (event: RunEvent) => Effect.Effect<boolean, never, RunEventChannel>;
|
|
1370
1370
|
/**
|
|
1371
1371
|
* Emit a batch of events onto the channel in order.
|
|
1372
1372
|
*
|
|
@@ -1378,7 +1378,7 @@ declare const publish: (event: RunEvent) => Effect.Effect<boolean, never, RunEve
|
|
|
1378
1378
|
* @returns an Effect that resolves when all events are enqueued
|
|
1379
1379
|
* @public
|
|
1380
1380
|
*/
|
|
1381
|
-
declare const publishAll: (events: Iterable<RunEvent>) => Effect.Effect<void, never, RunEventChannel>;
|
|
1381
|
+
export declare const publishAll: (events: Iterable<RunEvent>) => Effect.Effect<void, never, RunEventChannel>;
|
|
1382
1382
|
//#endregion
|
|
1383
1383
|
//#region src/pubsub/Subscriber.d.ts
|
|
1384
1384
|
/**
|
|
@@ -1392,7 +1392,7 @@ declare const publishAll: (events: Iterable<RunEvent>) => Effect.Effect<void, ne
|
|
|
1392
1392
|
* @returns an Effect that resolves to the terminal render state
|
|
1393
1393
|
* @public
|
|
1394
1394
|
*/
|
|
1395
|
-
declare const accumulateUntilFinished: (initial?: RenderState) => Effect.Effect<RenderState, never, RunEventChannel>;
|
|
1395
|
+
export declare const accumulateUntilFinished: (initial?: RenderState) => Effect.Effect<RenderState, never, RunEventChannel>;
|
|
1396
1396
|
/**
|
|
1397
1397
|
* Run a callback for every projected `RenderState` as events
|
|
1398
1398
|
* arrive. The stream terminates when the PubSub shuts down (typically
|
|
@@ -1408,7 +1408,7 @@ declare const accumulateUntilFinished: (initial?: RenderState) => Effect.Effect<
|
|
|
1408
1408
|
* @returns an Effect that completes when the PubSub shuts down
|
|
1409
1409
|
* @public
|
|
1410
1410
|
*/
|
|
1411
|
-
declare const forEachRenderState: <R, E>(onState: (state: RenderState) => Effect.Effect<void, E, R>, initial?: RenderState) => Effect.Effect<void, E, R | RunEventChannel>;
|
|
1411
|
+
export declare const forEachRenderState: <R, E>(onState: (state: RenderState) => Effect.Effect<void, E, R>, initial?: RenderState) => Effect.Effect<void, E, R | RunEventChannel>;
|
|
1412
1412
|
/**
|
|
1413
1413
|
* Build an Effect `Stream` of accumulated states over the channel.
|
|
1414
1414
|
*
|
|
@@ -1420,7 +1420,7 @@ declare const forEachRenderState: <R, E>(onState: (state: RenderState) => Effect
|
|
|
1420
1420
|
* @returns an Effect that resolves to a Stream of render states
|
|
1421
1421
|
* @public
|
|
1422
1422
|
*/
|
|
1423
|
-
declare const renderStateStream: (initial?: RenderState) => Effect.Effect<Stream.Stream<RenderState>, never, RunEventChannel>;
|
|
1423
|
+
export declare const renderStateStream: (initial?: RenderState) => Effect.Effect<Stream.Stream<RenderState>, never, RunEventChannel>;
|
|
1424
1424
|
/**
|
|
1425
1425
|
* Convenience: subscribe and produce a low-level dequeue of raw
|
|
1426
1426
|
* `RunEvent` values. Mostly for tests and ad-hoc consumers; most
|
|
@@ -1430,7 +1430,7 @@ declare const renderStateStream: (initial?: RenderState) => Effect.Effect<Stream
|
|
|
1430
1430
|
* @returns an Effect that resolves to a dequeue of raw run events
|
|
1431
1431
|
* @public
|
|
1432
1432
|
*/
|
|
1433
|
-
declare const subscribeRaw: () => Effect.Effect<PubSub.Subscription<RunEvent>, never, RunEventChannel | Scope.Scope>;
|
|
1433
|
+
export declare const subscribeRaw: () => Effect.Effect<PubSub.Subscription<RunEvent>, never, RunEventChannel | Scope.Scope>;
|
|
1434
1434
|
//#endregion
|
|
1435
1435
|
//#region src/reducer.d.ts
|
|
1436
1436
|
/**
|
|
@@ -1445,7 +1445,7 @@ declare const subscribeRaw: () => Effect.Effect<PubSub.Subscription<RunEvent>, n
|
|
|
1445
1445
|
* @returns the next render state
|
|
1446
1446
|
* @public
|
|
1447
1447
|
*/
|
|
1448
|
-
declare const reduceRenderState: (state: RenderState, event: RunEvent) => RenderState;
|
|
1448
|
+
export declare const reduceRenderState: (state: RenderState, event: RunEvent) => RenderState;
|
|
1449
1449
|
/**
|
|
1450
1450
|
* Fold a sequence of events into a final `RenderState`.
|
|
1451
1451
|
*
|
|
@@ -1457,7 +1457,7 @@ declare const reduceRenderState: (state: RenderState, event: RunEvent) => Render
|
|
|
1457
1457
|
* @returns the terminal render state after all events are applied
|
|
1458
1458
|
* @public
|
|
1459
1459
|
*/
|
|
1460
|
-
declare const reduceRenderStateAll: (events: ReadonlyArray<RunEvent>, seed?: RenderState) => RenderState;
|
|
1460
|
+
export declare const reduceRenderStateAll: (events: ReadonlyArray<RunEvent>, seed?: RenderState) => RenderState;
|
|
1461
1461
|
//#endregion
|
|
1462
1462
|
//#region src/render-agent.d.ts
|
|
1463
1463
|
/**
|
|
@@ -1504,7 +1504,7 @@ interface RenderAgentOptions {
|
|
|
1504
1504
|
* @returns the agent-format string
|
|
1505
1505
|
* @public
|
|
1506
1506
|
*/
|
|
1507
|
-
declare const renderAgent: (state: RenderState, options?: RenderAgentOptions) => string;
|
|
1507
|
+
export declare const renderAgent: (state: RenderState, options?: RenderAgentOptions) => string;
|
|
1508
1508
|
//#endregion
|
|
1509
1509
|
//#region src/render-ink/CountColumns.d.ts
|
|
1510
1510
|
/**
|
|
@@ -1529,7 +1529,7 @@ interface CountColumnsProps {
|
|
|
1529
1529
|
*
|
|
1530
1530
|
* @public
|
|
1531
1531
|
*/
|
|
1532
|
-
declare const DURATION_CELL_WIDTH = 7;
|
|
1532
|
+
export declare const DURATION_CELL_WIDTH = 7;
|
|
1533
1533
|
/**
|
|
1534
1534
|
* Renders four colored count columns (pass ✓, fail ✗, skip ↷, timeout ⧖)
|
|
1535
1535
|
* for an aggregate row. Counts render right-aligned in fixed 4-digit cells so
|
|
@@ -1538,7 +1538,7 @@ declare const DURATION_CELL_WIDTH = 7;
|
|
|
1538
1538
|
*
|
|
1539
1539
|
* @public
|
|
1540
1540
|
*/
|
|
1541
|
-
declare const CountColumns: FC<CountColumnsProps>;
|
|
1541
|
+
export declare const CountColumns: FC<CountColumnsProps>;
|
|
1542
1542
|
//#endregion
|
|
1543
1543
|
//#region src/render-ink/CoverageBlock.d.ts
|
|
1544
1544
|
/**
|
|
@@ -1558,7 +1558,7 @@ interface CoverageBlockProps {
|
|
|
1558
1558
|
*
|
|
1559
1559
|
* @public
|
|
1560
1560
|
*/
|
|
1561
|
-
declare const CoverageBlock: FC<CoverageBlockProps>;
|
|
1561
|
+
export declare const CoverageBlock: FC<CoverageBlockProps>;
|
|
1562
1562
|
//#endregion
|
|
1563
1563
|
//#region src/render-ink/FailureSection.d.ts
|
|
1564
1564
|
/**
|
|
@@ -1578,7 +1578,7 @@ interface FailureSectionProps {
|
|
|
1578
1578
|
*
|
|
1579
1579
|
* @public
|
|
1580
1580
|
*/
|
|
1581
|
-
declare const FailureSection: FC<FailureSectionProps>;
|
|
1581
|
+
export declare const FailureSection: FC<FailureSectionProps>;
|
|
1582
1582
|
//#endregion
|
|
1583
1583
|
//#region src/render-ink/FailuresSection.d.ts
|
|
1584
1584
|
/**
|
|
@@ -1598,7 +1598,7 @@ interface FailuresSectionProps {
|
|
|
1598
1598
|
*
|
|
1599
1599
|
* @public
|
|
1600
1600
|
*/
|
|
1601
|
-
declare const FailuresSection: FC<FailuresSectionProps>;
|
|
1601
|
+
export declare const FailuresSection: FC<FailuresSectionProps>;
|
|
1602
1602
|
//#endregion
|
|
1603
1603
|
//#region src/render-ink/ModuleHeader.d.ts
|
|
1604
1604
|
/**
|
|
@@ -1616,7 +1616,7 @@ interface ModuleHeaderProps {
|
|
|
1616
1616
|
*
|
|
1617
1617
|
* @public
|
|
1618
1618
|
*/
|
|
1619
|
-
declare const ModuleHeader: FC<ModuleHeaderProps>;
|
|
1619
|
+
export declare const ModuleHeader: FC<ModuleHeaderProps>;
|
|
1620
1620
|
//#endregion
|
|
1621
1621
|
//#region src/render-ink/ProjectRow.d.ts
|
|
1622
1622
|
/**
|
|
@@ -1662,7 +1662,7 @@ interface ProjectRowProps {
|
|
|
1662
1662
|
*
|
|
1663
1663
|
* @public
|
|
1664
1664
|
*/
|
|
1665
|
-
declare const ProjectRow: FC<ProjectRowProps>;
|
|
1665
|
+
export declare const ProjectRow: FC<ProjectRowProps>;
|
|
1666
1666
|
//#endregion
|
|
1667
1667
|
//#region src/render-ink/StatusIcon.d.ts
|
|
1668
1668
|
/**
|
|
@@ -1685,7 +1685,7 @@ interface StatusIconProps {
|
|
|
1685
1685
|
*
|
|
1686
1686
|
* @public
|
|
1687
1687
|
*/
|
|
1688
|
-
declare const StatusIcon: FC<StatusIconProps>;
|
|
1688
|
+
export declare const StatusIcon: FC<StatusIconProps>;
|
|
1689
1689
|
//#endregion
|
|
1690
1690
|
//#region src/render-ink/StreamApp.d.ts
|
|
1691
1691
|
/**
|
|
@@ -1707,7 +1707,7 @@ interface StreamAppProps {
|
|
|
1707
1707
|
*
|
|
1708
1708
|
* @public
|
|
1709
1709
|
*/
|
|
1710
|
-
declare const StreamApp: FC<StreamAppProps>;
|
|
1710
|
+
export declare const StreamApp: FC<StreamAppProps>;
|
|
1711
1711
|
//#endregion
|
|
1712
1712
|
//#region src/render-ink/SuggestedActions.d.ts
|
|
1713
1713
|
/**
|
|
@@ -1725,7 +1725,7 @@ interface SuggestedActionsProps {
|
|
|
1725
1725
|
*
|
|
1726
1726
|
* @public
|
|
1727
1727
|
*/
|
|
1728
|
-
declare const SuggestedActions: FC<SuggestedActionsProps>;
|
|
1728
|
+
export declare const SuggestedActions: FC<SuggestedActionsProps>;
|
|
1729
1729
|
//#endregion
|
|
1730
1730
|
//#region src/render-ink/spinner.d.ts
|
|
1731
1731
|
/**
|
|
@@ -1745,13 +1745,13 @@ declare const SuggestedActions: FC<SuggestedActionsProps>;
|
|
|
1745
1745
|
*
|
|
1746
1746
|
* @public
|
|
1747
1747
|
*/
|
|
1748
|
-
declare const SPINNER_FRAMES: readonly ["⠋", "⠙", "⠹", "⠸", "⠼", "⠴", "⠦", "⠧", "⠇", "⠏"];
|
|
1748
|
+
export declare const SPINNER_FRAMES: readonly ["⠋", "⠙", "⠹", "⠸", "⠼", "⠴", "⠦", "⠧", "⠇", "⠏"];
|
|
1749
1749
|
/**
|
|
1750
1750
|
* How long each spinner frame is held, in milliseconds.
|
|
1751
1751
|
*
|
|
1752
1752
|
* @public
|
|
1753
1753
|
*/
|
|
1754
|
-
declare const SPINNER_FRAME_MS = 80;
|
|
1754
|
+
export declare const SPINNER_FRAME_MS = 80;
|
|
1755
1755
|
/**
|
|
1756
1756
|
* Resolve the spinner glyph for a frame index. The index wraps modulo
|
|
1757
1757
|
* the frame count and tolerates negative values, so a wall-clock-derived
|
|
@@ -1761,7 +1761,7 @@ declare const SPINNER_FRAME_MS = 80;
|
|
|
1761
1761
|
* @returns the Braille glyph for the given frame
|
|
1762
1762
|
* @public
|
|
1763
1763
|
*/
|
|
1764
|
-
declare const spinnerFrame: (index: number) => string;
|
|
1764
|
+
export declare const spinnerFrame: (index: number) => string;
|
|
1765
1765
|
/**
|
|
1766
1766
|
* Derive the spinner frame index from a wall-clock timestamp. Using the
|
|
1767
1767
|
* clock — rather than a monotonic counter — keeps the animation correct
|
|
@@ -1771,7 +1771,7 @@ declare const spinnerFrame: (index: number) => string;
|
|
|
1771
1771
|
* @returns the frame index for the given timestamp
|
|
1772
1772
|
* @public
|
|
1773
1773
|
*/
|
|
1774
|
-
declare const spinnerFrameForTime: (nowMs: number) => number;
|
|
1774
|
+
export declare const spinnerFrameForTime: (nowMs: number) => number;
|
|
1775
1775
|
//#endregion
|
|
1776
1776
|
//#region src/render-ink/TagColumns.d.ts
|
|
1777
1777
|
/**
|
|
@@ -1782,7 +1782,7 @@ declare const spinnerFrameForTime: (nowMs: number) => number;
|
|
|
1782
1782
|
*
|
|
1783
1783
|
* @public
|
|
1784
1784
|
*/
|
|
1785
|
-
declare const tagUnion: (rows: ReadonlyArray<Record<string, number> | undefined>) => ReadonlyArray<string>;
|
|
1785
|
+
export declare const tagUnion: (rows: ReadonlyArray<Record<string, number> | undefined>) => ReadonlyArray<string>;
|
|
1786
1786
|
/**
|
|
1787
1787
|
* Props for the `TagColumns` component.
|
|
1788
1788
|
*
|
|
@@ -1800,7 +1800,7 @@ interface TagColumnsProps {
|
|
|
1800
1800
|
*
|
|
1801
1801
|
* @public
|
|
1802
1802
|
*/
|
|
1803
|
-
declare const TagColumns: FC<TagColumnsProps>;
|
|
1803
|
+
export declare const TagColumns: FC<TagColumnsProps>;
|
|
1804
1804
|
//#endregion
|
|
1805
1805
|
//#region src/render-ink/TestRow.d.ts
|
|
1806
1806
|
/**
|
|
@@ -1819,7 +1819,7 @@ interface TestRowProps {
|
|
|
1819
1819
|
*
|
|
1820
1820
|
* @public
|
|
1821
1821
|
*/
|
|
1822
|
-
declare const TestRow: FC<TestRowProps>;
|
|
1822
|
+
export declare const TestRow: FC<TestRowProps>;
|
|
1823
1823
|
//#endregion
|
|
1824
1824
|
//#region src/render-ink/TrendLine.d.ts
|
|
1825
1825
|
/**
|
|
@@ -1839,7 +1839,7 @@ interface TrendLineProps {
|
|
|
1839
1839
|
*
|
|
1840
1840
|
* @public
|
|
1841
1841
|
*/
|
|
1842
|
-
declare const TrendLine: FC<TrendLineProps>;
|
|
1842
|
+
export declare const TrendLine: FC<TrendLineProps>;
|
|
1843
1843
|
//#endregion
|
|
1844
1844
|
//#region src/synthesize.d.ts
|
|
1845
1845
|
/**
|
|
@@ -1850,7 +1850,7 @@ declare const TrendLine: FC<TrendLineProps>;
|
|
|
1850
1850
|
*
|
|
1851
1851
|
* @public
|
|
1852
1852
|
*/
|
|
1853
|
-
declare const SUITE_LOAD_FAILURE_LABEL = "test suite failed to load";
|
|
1853
|
+
export declare const SUITE_LOAD_FAILURE_LABEL = "test suite failed to load";
|
|
1854
1854
|
/**
|
|
1855
1855
|
* Optional metadata threaded through the synthesized event stream.
|
|
1856
1856
|
*
|
|
@@ -1905,7 +1905,7 @@ interface SynthesizedCoverage {
|
|
|
1905
1905
|
* @returns an ordered array of run events
|
|
1906
1906
|
* @public
|
|
1907
1907
|
*/
|
|
1908
|
-
declare const synthesizeRunEvents: (modules: ReadonlyArray<VitestTestModule>, options?: SynthesizeOptions) => RunEvent[];
|
|
1908
|
+
export declare const synthesizeRunEvents: (modules: ReadonlyArray<VitestTestModule>, options?: SynthesizeOptions) => RunEvent[];
|
|
1909
1909
|
/**
|
|
1910
1910
|
* Options for {@link synthesizeFromAgentReport}.
|
|
1911
1911
|
*
|
|
@@ -1938,7 +1938,7 @@ interface SynthesizeFromAgentReportOptions {
|
|
|
1938
1938
|
* @returns an ordered array of run events
|
|
1939
1939
|
* @public
|
|
1940
1940
|
*/
|
|
1941
|
-
declare const synthesizeFromAgentReport: (report: AgentReport, options?: SynthesizeFromAgentReportOptions) => RunEvent[];
|
|
1941
|
+
export declare const synthesizeFromAgentReport: (report: AgentReport, options?: SynthesizeFromAgentReportOptions) => RunEvent[];
|
|
1942
1942
|
//#endregion
|
|
1943
1943
|
//#region src/index.d.ts
|
|
1944
1944
|
/**
|
|
@@ -1948,7 +1948,7 @@ declare const synthesizeFromAgentReport: (report: AgentReport, options?: Synthes
|
|
|
1948
1948
|
*
|
|
1949
1949
|
* @public
|
|
1950
1950
|
*/
|
|
1951
|
-
declare const CURRENT_UI_VERSION: string;
|
|
1951
|
+
export declare const CURRENT_UI_VERSION: string;
|
|
1952
1952
|
//#endregion
|
|
1953
|
-
export {
|
|
1953
|
+
export { type AgentCellFn, type AgentReport, type Cell, type CellOptions, type CountColumnsProps, type CoverageBlockProps, FileCoverageReport as CoverageFile, type CoverageTotals, type DispatchInputs, type FailureSectionProps, type FailuresSectionProps, type InkCellFn, type MetricThresholds, type ModuleHeaderProps, type ProjectRowProps, type ProjectSummary, type RenderAgentOptions, type RunEventByTag, type RunOutcome, type RunShape, type StatusIconKind, type StatusIconProps, type StreamAppProps, type SuggestedActionsProps, type SynthesizeFromAgentReportOptions, type SynthesizeOptions, type SynthesizedCoverage, type TagColumnsProps, type TestClassification, type TestRowProps, type TrendLineProps, type TrendSummary, type VitestModuleDiagnostic, type VitestModuleError, type VitestParsedStack, type VitestTestCase, type VitestTestDiagnostic, type VitestTestError, type VitestTestModule, type VitestTestResult, type VitestTestSuite };
|
|
1954
1954
|
//# sourceMappingURL=index.d.ts.map
|
package/index.js
CHANGED
|
@@ -33,7 +33,7 @@ import { ActionSeverity, CoverageFile, CoverageGap, CoverageMetric, CoverageRend
|
|
|
33
33
|
*
|
|
34
34
|
* @public
|
|
35
35
|
*/
|
|
36
|
-
const CURRENT_UI_VERSION = "2.3.
|
|
36
|
+
const CURRENT_UI_VERSION = "2.3.1";
|
|
37
37
|
|
|
38
38
|
//#endregion
|
|
39
39
|
export { ActionSeverity, CURRENT_UI_VERSION, CountColumns, CoverageBlock, CoverageFile, CoverageGap, CoverageMetric, CoverageRenderState, DURATION_CELL_WIDTH, FailureRecord, FailureSection, FailuresSection, ModuleHeader, ModuleRecord, ProjectRow, RenderState, RenderTotals, RunEvent, RunEventChannel, RunEventChannelLive, SPINNER_FRAMES, SPINNER_FRAME_MS, SUITE_LOAD_FAILURE_LABEL, StatusIcon, StreamApp, SuggestedActionRecord, SuggestedActions, TagColumns, TestRecord, TestRow, TrendLine, accumulateUntilFinished, buildFooter, classifyOutcome, classifyRunShape, dispatch, dispatchInk, dispatcherTable, dominantClassification, forEachRenderState, formatDisplayDuration, initialRenderState, publish, publishAll, reduceRenderState, reduceRenderStateAll, renderAgent, renderStateStream, spinnerFrame, spinnerFrameForTime, subscribeRaw, synthesizeFromAgentReport, synthesizeRunEvents, tagUnion };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vitest-agent/ui",
|
|
3
|
-
"version": "2.3.
|
|
3
|
+
"version": "2.3.1",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "Shared event-sourced renderer for vitest-agent. React Ink view for humans, plain-string view for agents, both fed by the same reducer over a RunEvent stream.",
|
|
6
6
|
"keywords": [
|
|
@@ -39,8 +39,8 @@
|
|
|
39
39
|
"./package.json": "./package.json"
|
|
40
40
|
},
|
|
41
41
|
"dependencies": {
|
|
42
|
-
"@vitest-agent/sdk": "2.5.
|
|
43
|
-
"effect": "4.0.0-rc.
|
|
42
|
+
"@vitest-agent/sdk": "2.5.1",
|
|
43
|
+
"effect": "4.0.0-rc.112"
|
|
44
44
|
},
|
|
45
45
|
"peerDependencies": {
|
|
46
46
|
"ink": "^7.1.0",
|