@vitest-agent/sdk 2.0.9 → 2.0.11

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/testing.d.ts CHANGED
@@ -1,58 +1,6 @@
1
1
  import { Context, Effect, Layer, Option, Schema } from "effect";
2
2
  import * as NodeServices from "@effect/platform-node/NodeServices";
3
3
  import * as SqliteMigrator from "@effect/sql-sqlite-node/SqliteMigrator";
4
- //#region src/schemas/Identity.d.ts
5
- /**
6
- * Canonical UUID for an LLM agent invocation. Generated server-side at
7
- * `register_agent` time. Stable across transport reconnects within an
8
- * agent's lifetime.
9
- * @public
10
- */
11
- declare const AgentId: Schema.brand<Schema.String, "AgentId">;
12
- /** @public */
13
- type AgentId = Schema.Schema.Type<typeof AgentId>;
14
- /**
15
- * The agent host process's chat id (Claude Code's per-process chat
16
- * UUID, etc.). Shorter-lived than a conversation; one conversation can
17
- * have multiple chats across `--resume` invocations. Distinct from
18
- * `sessions.id` (the SQLite agent-run PK).
19
- * @public
20
- */
21
- declare const ChatId: Schema.brand<Schema.String, "ChatId">;
22
- /** @public */
23
- type ChatId = Schema.Schema.Type<typeof ChatId>;
24
- //#endregion
25
- //#region src/errors/AgentErrors.d.ts
26
- declare const AgentNotFoundError_base: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P]; }>) => import("effect/Cause").YieldableError & {
27
- readonly _tag: "AgentNotFoundError";
28
- } & Readonly<A>;
29
- /**
30
- * `agent_id` does not exist for the given chat. Surface to the
31
- * caller; the typical resolution is to call `register_agent` for
32
- * this agent first.
33
- * @public
34
- */
35
- declare class AgentNotFoundError extends AgentNotFoundError_base<{
36
- readonly agentId: AgentId;
37
- readonly chatId?: ChatId;
38
- }> {}
39
- declare const RegistrationConflictError_base: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P]; }>) => import("effect/Cause").YieldableError & {
40
- readonly _tag: "RegistrationConflictError";
41
- } & Readonly<A>;
42
- /**
43
- * True conflict — e.g., the `parentAgentId` supplied to
44
- * `register_agent` refers to a different session than the one the
45
- * caller named. Distinct from `IdempotencyHit`, which is a success.
46
- * @public
47
- */
48
- declare class RegistrationConflictError extends RegistrationConflictError_base<{
49
- readonly reason: string;
50
- }> {
51
- constructor(args: {
52
- readonly reason: string;
53
- });
54
- }
55
- //#endregion
56
4
  //#region src/errors/DataStoreError.d.ts
57
5
  declare const DataStoreError_base: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P]; }>) => import("effect/Cause").YieldableError & {
58
6
  readonly _tag: "DataStoreError";
@@ -73,279 +21,440 @@ declare class DataStoreError extends DataStoreError_base<{
73
21
  });
74
22
  }
75
23
  //#endregion
76
- //#region src/errors/TddErrors.d.ts
77
- declare const GoalNotFoundError_base: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P]; }>) => import("effect/Cause").YieldableError & {
78
- readonly _tag: "GoalNotFoundError";
79
- } & Readonly<A>;
80
- /** @public */
81
- declare class GoalNotFoundError extends GoalNotFoundError_base<{
82
- readonly id: number;
83
- readonly reason: string;
84
- }> {
85
- constructor(args: {
86
- readonly id: number;
87
- readonly reason: string;
88
- });
89
- }
90
- declare const BehaviorNotFoundError_base: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P]; }>) => import("effect/Cause").YieldableError & {
91
- readonly _tag: "BehaviorNotFoundError";
92
- } & Readonly<A>;
93
- /** @public */
94
- declare class BehaviorNotFoundError extends BehaviorNotFoundError_base<{
95
- readonly id: number;
96
- readonly reason: string;
97
- }> {
98
- constructor(args: {
99
- readonly id: number;
100
- readonly reason: string;
101
- });
102
- }
103
- declare const TddTaskNotFoundError_base: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P]; }>) => import("effect/Cause").YieldableError & {
104
- readonly _tag: "TddTaskNotFoundError";
105
- } & Readonly<A>;
106
- /** @public */
107
- declare class TddTaskNotFoundError extends TddTaskNotFoundError_base<{
108
- readonly id: number;
109
- readonly reason: string;
110
- }> {
111
- constructor(args: {
112
- readonly id: number;
113
- readonly reason: string;
114
- });
115
- }
116
- /** @public */
117
- type TddTaskEndOutcome = "succeeded" | "blocked" | "abandoned";
118
- declare const TddTaskAlreadyEndedError_base: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P]; }>) => import("effect/Cause").YieldableError & {
119
- readonly _tag: "TddTaskAlreadyEndedError";
120
- } & Readonly<A>;
121
- /** @public */
122
- declare class TddTaskAlreadyEndedError extends TddTaskAlreadyEndedError_base<{
123
- readonly id: number;
124
- readonly endedAt: string;
125
- readonly outcome: TddTaskEndOutcome;
126
- }> {
127
- constructor(args: {
128
- readonly id: number;
129
- readonly endedAt: string;
130
- readonly outcome: TddTaskEndOutcome;
131
- });
132
- }
133
- /** @public */
134
- type IllegalStatusTransitionEntity = "goal" | "behavior" | "task";
135
- declare const IllegalStatusTransitionError_base: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P]; }>) => import("effect/Cause").YieldableError & {
136
- readonly _tag: "IllegalStatusTransitionError";
137
- } & Readonly<A>;
138
- /** @public */
139
- declare class IllegalStatusTransitionError extends IllegalStatusTransitionError_base<{
140
- readonly entity: IllegalStatusTransitionEntity;
141
- readonly id: number;
142
- readonly from: string;
143
- readonly to: string;
144
- readonly reason: string;
145
- }> {
146
- constructor(args: {
147
- readonly entity: IllegalStatusTransitionEntity;
148
- readonly id: number;
149
- readonly from: string;
150
- readonly to: string;
151
- readonly reason: string;
152
- });
153
- }
154
- //#endregion
155
- //#region src/schemas/Agent.d.ts
156
- declare const Agent_base: Schema.Class<Agent, Schema.TaggedStruct<"Agent", {
157
- readonly agentId: Schema.brand<Schema.String, "AgentId">;
158
- readonly sessionId: Schema.Number;
159
- readonly parentAgentId: Schema.NullOr<Schema.brand<Schema.String, "AgentId">>;
160
- readonly conversationId: Schema.NullOr<Schema.brand<Schema.String, "ConversationId">>;
161
- readonly agentType: Schema.String;
162
- readonly startedAt: Schema.Number;
163
- readonly endedAt: Schema.NullOr<Schema.Number>;
164
- readonly startGitBranch: Schema.NullOr<Schema.String>;
165
- readonly startGitCommitSha: Schema.NullOr<Schema.String>;
166
- readonly startWorktreeDir: Schema.NullOr<Schema.String>;
167
- readonly idempotencyKey: Schema.String;
168
- }>, {}>;
169
- /**
170
- * Successful registration row. The fields mirror the `agents` SQLite
171
- * table 1:1 in camelCase.
172
- *
173
- * `startGitBranch`, `startGitCommitSha`, `startWorktreeDir` capture
174
- * *what the agent inherited at registration time* — distinct from the
175
- * per-run git context recorded on `runs`. A divergence between the
176
- * two reveals a mid-session branch switch, which is itself signal.
177
- * @public
178
- */
179
- declare class Agent extends Agent_base {}
180
- declare const IdempotencyHit_base: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P]; }>) => Readonly<A> & {
181
- readonly _tag: "IdempotencyHit";
182
- } & import("effect/Pipeable").Pipeable;
183
- /**
184
- * Returned by `DataStore.registerAgent` when the
185
- * `(session_id, idempotency_key)` UNIQUE constraint already has a
186
- * row. Not an error — the caller treats it as a successful recovery
187
- * of the existing `agentId`.
188
- *
189
- * Modeled as a `Data.TaggedClass` so the success channel of
190
- * `registerAgent` is `Effect<Agent | IdempotencyHit, ...>` and
191
- * downstream code uses `Match.tag` to branch.
192
- * @public
193
- */
194
- declare class IdempotencyHit extends IdempotencyHit_base<{
195
- readonly existingAgentId: typeof AgentId.Type;
196
- }> {}
197
- //#endregion
198
- //#region src/schemas/Baselines.d.ts
24
+ //#region src/schemas/AgentReport.d.ts
199
25
  /**
200
- * Coverage baselines -- the auto-ratcheting high-water mark.
26
+ * Complete per-project test report written to disk as JSON.
201
27
  * @public
202
28
  */
203
- declare const CoverageBaselines: Schema.Struct<{
204
- readonly updatedAt: Schema.String;
205
- readonly global: Schema.Struct<{
206
- readonly lines: Schema.optional<Schema.Number>;
207
- readonly functions: Schema.optional<Schema.Number>;
208
- readonly branches: Schema.optional<Schema.Number>;
209
- readonly statements: Schema.optional<Schema.Number>;
29
+ declare const AgentReport: Schema.Struct<{
30
+ readonly timestamp: Schema.String;
31
+ readonly project: Schema.optional<Schema.String>;
32
+ readonly reason: Schema.Literals<readonly ["passed", "failed", "interrupted"]>;
33
+ readonly summary: Schema.Struct<{
34
+ readonly total: Schema.Number;
35
+ readonly passed: Schema.Number;
36
+ readonly failed: Schema.Number;
37
+ readonly skipped: Schema.Number;
38
+ readonly duration: Schema.Number;
210
39
  }>;
211
- readonly patterns: Schema.withDecodingDefaultKey<Schema.$Array<Schema.Tuple<readonly [Schema.String, Schema.Struct<{
212
- readonly lines: Schema.optional<Schema.Number>;
213
- readonly functions: Schema.optional<Schema.Number>;
214
- readonly branches: Schema.optional<Schema.Number>;
215
- readonly statements: Schema.optional<Schema.Number>;
216
- }>]>>, never>;
217
- }>;
218
- /** @public */
219
- type CoverageBaselines = typeof CoverageBaselines.Type;
220
- //#endregion
221
- //#region src/schemas/Tdd.d.ts
222
- /** @public */
223
- declare const GoalStatus: Schema.Literals<readonly ["pending", "in_progress", "done", "abandoned"]>;
224
- /** @public */
225
- type GoalStatus = typeof GoalStatus.Type;
226
- /** @public */
227
- declare const BehaviorStatus: Schema.Literals<readonly ["pending", "in_progress", "done", "abandoned"]>;
228
- /** @public */
229
- type BehaviorStatus = typeof BehaviorStatus.Type;
230
- /** @public */
231
- declare const GoalRow: Schema.Struct<{
232
- readonly id: Schema.Number;
233
- readonly sessionId: Schema.Number;
234
- readonly ordinal: Schema.Number;
235
- readonly goal: Schema.String;
236
- readonly status: Schema.Literals<readonly ["pending", "in_progress", "done", "abandoned"]>;
237
- readonly createdAt: Schema.String;
238
- }>;
239
- /** @public */
240
- type GoalRow = typeof GoalRow.Type;
241
- /** @public */
242
- declare const BehaviorRow: Schema.Struct<{
243
- readonly id: Schema.Number;
244
- readonly goalId: Schema.Number;
245
- readonly ordinal: Schema.Number;
246
- readonly behavior: Schema.String;
247
- readonly suggestedTestName: Schema.NullOr<Schema.String>;
248
- readonly status: Schema.Literals<readonly ["pending", "in_progress", "done", "abandoned"]>;
249
- readonly createdAt: Schema.String;
250
- }>;
251
- /** @public */
252
- type BehaviorRow = typeof BehaviorRow.Type;
253
- /** @public */
254
- declare const GoalDetail: Schema.Struct<{
255
- readonly id: Schema.Number;
256
- readonly sessionId: Schema.Number;
257
- readonly ordinal: Schema.Number;
258
- readonly goal: Schema.String;
259
- readonly status: Schema.Literals<readonly ["pending", "in_progress", "done", "abandoned"]>;
260
- readonly createdAt: Schema.String;
261
- readonly behaviors: Schema.$Array<Schema.Struct<{
262
- readonly id: Schema.Number;
263
- readonly goalId: Schema.Number;
264
- readonly ordinal: Schema.Number;
265
- readonly behavior: Schema.String;
266
- readonly suggestedTestName: Schema.NullOr<Schema.String>;
267
- readonly status: Schema.Literals<readonly ["pending", "in_progress", "done", "abandoned"]>;
268
- readonly createdAt: Schema.String;
269
- }>>;
270
- }>;
271
- /** @public */
272
- type GoalDetail = typeof GoalDetail.Type;
40
+ readonly failed: Schema.$Array<Schema.Struct<{
41
+ readonly file: Schema.String;
42
+ readonly state: Schema.Literals<readonly ["passed", "failed", "skipped", "pending"]>;
43
+ readonly duration: Schema.optional<Schema.Number>;
44
+ readonly errors: Schema.optional<Schema.$Array<Schema.Struct<{
45
+ readonly message: Schema.String;
46
+ readonly stack: Schema.optional<Schema.String>;
47
+ readonly diff: Schema.optional<Schema.String>;
48
+ readonly expected: Schema.optional<Schema.String>;
49
+ readonly received: Schema.optional<Schema.String>;
50
+ }>>>;
51
+ readonly tests: Schema.$Array<Schema.Struct<{
52
+ readonly name: Schema.String;
53
+ readonly fullName: Schema.String;
54
+ readonly state: Schema.Literals<readonly ["passed", "failed", "skipped", "pending"]>;
55
+ readonly duration: Schema.optional<Schema.Number>;
56
+ readonly flaky: Schema.optional<Schema.Boolean>;
57
+ readonly slow: Schema.optional<Schema.Boolean>;
58
+ readonly errors: Schema.optional<Schema.$Array<Schema.Struct<{
59
+ readonly message: Schema.String;
60
+ readonly stack: Schema.optional<Schema.String>;
61
+ readonly diff: Schema.optional<Schema.String>;
62
+ readonly expected: Schema.optional<Schema.String>;
63
+ readonly received: Schema.optional<Schema.String>;
64
+ }>>>;
65
+ readonly classification: Schema.optional<Schema.Literals<readonly ["stable", "new-failure", "persistent", "flaky", "recovered"]>>;
66
+ }>>;
67
+ }>>;
68
+ readonly unhandledErrors: Schema.$Array<Schema.Struct<{
69
+ readonly message: Schema.String;
70
+ readonly stack: Schema.optional<Schema.String>;
71
+ readonly diff: Schema.optional<Schema.String>;
72
+ readonly expected: Schema.optional<Schema.String>;
73
+ readonly received: Schema.optional<Schema.String>;
74
+ }>>;
75
+ readonly failedFiles: Schema.$Array<Schema.String>;
76
+ readonly coverage: Schema.optional<Schema.Struct<{
77
+ readonly totals: Schema.Struct<{
78
+ readonly statements: Schema.Number;
79
+ readonly branches: Schema.Number;
80
+ readonly functions: Schema.Number;
81
+ readonly lines: Schema.Number;
82
+ }>;
83
+ readonly thresholds: Schema.Struct<{
84
+ readonly global: Schema.Struct<{
85
+ readonly lines: Schema.optional<Schema.Number>;
86
+ readonly functions: Schema.optional<Schema.Number>;
87
+ readonly branches: Schema.optional<Schema.Number>;
88
+ readonly statements: Schema.optional<Schema.Number>;
89
+ }>;
90
+ readonly patterns: Schema.withDecodingDefaultKey<Schema.$Array<Schema.Tuple<readonly [Schema.String, Schema.Struct<{
91
+ readonly lines: Schema.optional<Schema.Number>;
92
+ readonly functions: Schema.optional<Schema.Number>;
93
+ readonly branches: Schema.optional<Schema.Number>;
94
+ readonly statements: Schema.optional<Schema.Number>;
95
+ }>]>>, never>;
96
+ }>;
97
+ readonly targets: Schema.optional<Schema.Struct<{
98
+ readonly global: Schema.Struct<{
99
+ readonly lines: Schema.optional<Schema.Number>;
100
+ readonly functions: Schema.optional<Schema.Number>;
101
+ readonly branches: Schema.optional<Schema.Number>;
102
+ readonly statements: Schema.optional<Schema.Number>;
103
+ }>;
104
+ readonly patterns: Schema.withDecodingDefaultKey<Schema.$Array<Schema.Tuple<readonly [Schema.String, Schema.Struct<{
105
+ readonly lines: Schema.optional<Schema.Number>;
106
+ readonly functions: Schema.optional<Schema.Number>;
107
+ readonly branches: Schema.optional<Schema.Number>;
108
+ readonly statements: Schema.optional<Schema.Number>;
109
+ }>]>>, never>;
110
+ }>>;
111
+ readonly baselines: Schema.optional<Schema.Struct<{
112
+ readonly global: Schema.Struct<{
113
+ readonly lines: Schema.optional<Schema.Number>;
114
+ readonly functions: Schema.optional<Schema.Number>;
115
+ readonly branches: Schema.optional<Schema.Number>;
116
+ readonly statements: Schema.optional<Schema.Number>;
117
+ }>;
118
+ readonly patterns: Schema.withDecodingDefaultKey<Schema.$Array<Schema.Tuple<readonly [Schema.String, Schema.Struct<{
119
+ readonly lines: Schema.optional<Schema.Number>;
120
+ readonly functions: Schema.optional<Schema.Number>;
121
+ readonly branches: Schema.optional<Schema.Number>;
122
+ readonly statements: Schema.optional<Schema.Number>;
123
+ }>]>>, never>;
124
+ }>>;
125
+ readonly scoped: Schema.withDecodingDefaultKey<Schema.Boolean, never>;
126
+ readonly scopedFiles: Schema.optional<Schema.$Array<Schema.String>>;
127
+ readonly lowCoverage: Schema.$Array<Schema.Struct<{
128
+ readonly file: Schema.String;
129
+ readonly summary: Schema.Struct<{
130
+ readonly statements: Schema.Number;
131
+ readonly branches: Schema.Number;
132
+ readonly functions: Schema.Number;
133
+ readonly lines: Schema.Number;
134
+ }>;
135
+ readonly uncoveredLines: Schema.String;
136
+ }>>;
137
+ readonly lowCoverageFiles: Schema.$Array<Schema.String>;
138
+ readonly belowTarget: Schema.optional<Schema.$Array<Schema.Struct<{
139
+ readonly file: Schema.String;
140
+ readonly summary: Schema.Struct<{
141
+ readonly statements: Schema.Number;
142
+ readonly branches: Schema.Number;
143
+ readonly functions: Schema.Number;
144
+ readonly lines: Schema.Number;
145
+ }>;
146
+ readonly uncoveredLines: Schema.String;
147
+ }>>>;
148
+ readonly belowTargetFiles: Schema.optional<Schema.$Array<Schema.String>>;
149
+ }>>;
150
+ readonly tagCounts: Schema.optional<Schema.$Record<Schema.String, Schema.Struct<{
151
+ readonly passed: Schema.optional<Schema.Number>;
152
+ readonly failed: Schema.optional<Schema.Number>;
153
+ readonly skipped: Schema.optional<Schema.Number>;
154
+ }>>>;
155
+ readonly consoleLeaks: Schema.optional<Schema.Struct<{
156
+ readonly total: Schema.Number;
157
+ readonly byFile: Schema.$Array<Schema.Struct<{
158
+ readonly file: Schema.String;
159
+ readonly stdout: Schema.Number;
160
+ readonly stderr: Schema.Number;
161
+ readonly tests: Schema.optional<Schema.$Array<Schema.String>>;
162
+ readonly sample: Schema.optional<Schema.String>;
163
+ }>>;
164
+ readonly truncated: Schema.optional<Schema.Boolean>;
165
+ }>>;
166
+ }>;
273
167
  /** @public */
274
- declare const BehaviorDetail: Schema.Struct<{
275
- readonly id: Schema.Number;
276
- readonly goalId: Schema.Number;
277
- readonly ordinal: Schema.Number;
278
- readonly behavior: Schema.String;
279
- readonly suggestedTestName: Schema.NullOr<Schema.String>;
280
- readonly status: Schema.Literals<readonly ["pending", "in_progress", "done", "abandoned"]>;
281
- readonly createdAt: Schema.String;
282
- readonly parentGoal: Schema.Struct<{
283
- readonly id: Schema.Number;
284
- readonly goal: Schema.String;
285
- readonly status: Schema.Literals<readonly ["pending", "in_progress", "done", "abandoned"]>;
168
+ type AgentReport = typeof AgentReport.Type;
169
+ //#endregion
170
+ //#region src/schemas/Baselines.d.ts
171
+ /**
172
+ * Coverage baselines -- the auto-ratcheting high-water mark.
173
+ * @public
174
+ */
175
+ declare const CoverageBaselines: Schema.Struct<{
176
+ readonly updatedAt: Schema.String;
177
+ readonly global: Schema.Struct<{
178
+ readonly lines: Schema.optional<Schema.Number>;
179
+ readonly functions: Schema.optional<Schema.Number>;
180
+ readonly branches: Schema.optional<Schema.Number>;
181
+ readonly statements: Schema.optional<Schema.Number>;
286
182
  }>;
287
- readonly dependencies: Schema.$Array<Schema.Struct<{
288
- readonly id: Schema.Number;
289
- readonly goalId: Schema.Number;
290
- readonly ordinal: Schema.Number;
291
- readonly behavior: Schema.String;
292
- readonly suggestedTestName: Schema.NullOr<Schema.String>;
293
- readonly status: Schema.Literals<readonly ["pending", "in_progress", "done", "abandoned"]>;
294
- readonly createdAt: Schema.String;
183
+ readonly patterns: Schema.withDecodingDefaultKey<Schema.$Array<Schema.Tuple<readonly [Schema.String, Schema.Struct<{
184
+ readonly lines: Schema.optional<Schema.Number>;
185
+ readonly functions: Schema.optional<Schema.Number>;
186
+ readonly branches: Schema.optional<Schema.Number>;
187
+ readonly statements: Schema.optional<Schema.Number>;
188
+ }>]>>, never>;
189
+ }>;
190
+ /** @public */
191
+ type CoverageBaselines = typeof CoverageBaselines.Type;
192
+ //#endregion
193
+ //#region src/schemas/CacheManifest.d.ts
194
+ /**
195
+ * Root manifest file that indexes all project reports.
196
+ * @public
197
+ */
198
+ declare const CacheManifest: Schema.Struct<{
199
+ readonly updatedAt: Schema.String;
200
+ readonly cacheDir: Schema.String;
201
+ readonly projects: Schema.$Array<Schema.Struct<{
202
+ readonly project: Schema.String;
203
+ readonly reportFile: Schema.String;
204
+ readonly historyFile: Schema.optional<Schema.String>;
205
+ readonly lastRun: Schema.NullOr<Schema.String>;
206
+ readonly lastResult: Schema.NullOr<Schema.Literals<readonly ["passed", "failed", "interrupted"]>>;
295
207
  }>>;
296
208
  }>;
297
209
  /** @public */
298
- type BehaviorDetail = typeof BehaviorDetail.Type;
210
+ type CacheManifest = typeof CacheManifest.Type;
299
211
  //#endregion
300
- //#region src/schemas/Trends.d.ts
212
+ //#region src/schemas/Coverage.d.ts
301
213
  /**
302
- * A single coverage trend data point recorded on a full test run.
214
+ * Per-file coverage data including uncovered line ranges.
303
215
  * @public
304
216
  */
305
- declare const TrendEntry: Schema.Struct<{
306
- readonly timestamp: Schema.String;
307
- readonly coverage: Schema.Struct<{
308
- readonly statements: Schema.Number;
309
- readonly branches: Schema.Number;
310
- readonly functions: Schema.Number;
311
- readonly lines: Schema.Number;
312
- }>;
313
- readonly delta: Schema.Struct<{
217
+ declare const FileCoverageReport: Schema.Struct<{
218
+ readonly file: Schema.String;
219
+ readonly summary: Schema.Struct<{
314
220
  readonly statements: Schema.Number;
315
221
  readonly branches: Schema.Number;
316
222
  readonly functions: Schema.Number;
317
223
  readonly lines: Schema.Number;
318
224
  }>;
319
- readonly direction: Schema.Literals<readonly ["improving", "regressing", "stable"]>;
320
- readonly targetsHash: Schema.optional<Schema.String>;
225
+ readonly uncoveredLines: Schema.String;
321
226
  }>;
322
227
  /** @public */
323
- type TrendEntry = typeof TrendEntry.Type;
228
+ type FileCoverageReport = typeof FileCoverageReport.Type;
324
229
  /**
325
- * Per-project trend record with sliding window of entries.
230
+ * Complete coverage report attached to an AgentReport.
326
231
  * @public
327
232
  */
328
- declare const TrendRecord: Schema.Struct<{
329
- readonly entries: Schema.$Array<Schema.Struct<{
330
- readonly timestamp: Schema.String;
331
- readonly coverage: Schema.Struct<{
332
- readonly statements: Schema.Number;
333
- readonly branches: Schema.Number;
334
- readonly functions: Schema.Number;
335
- readonly lines: Schema.Number;
233
+ declare const CoverageReport: Schema.Struct<{
234
+ readonly totals: Schema.Struct<{
235
+ readonly statements: Schema.Number;
236
+ readonly branches: Schema.Number;
237
+ readonly functions: Schema.Number;
238
+ readonly lines: Schema.Number;
239
+ }>;
240
+ readonly thresholds: Schema.Struct<{
241
+ readonly global: Schema.Struct<{
242
+ readonly lines: Schema.optional<Schema.Number>;
243
+ readonly functions: Schema.optional<Schema.Number>;
244
+ readonly branches: Schema.optional<Schema.Number>;
245
+ readonly statements: Schema.optional<Schema.Number>;
336
246
  }>;
337
- readonly delta: Schema.Struct<{
338
- readonly statements: Schema.Number;
339
- readonly branches: Schema.Number;
340
- readonly functions: Schema.Number;
341
- readonly lines: Schema.Number;
247
+ readonly patterns: Schema.withDecodingDefaultKey<Schema.$Array<Schema.Tuple<readonly [Schema.String, Schema.Struct<{
248
+ readonly lines: Schema.optional<Schema.Number>;
249
+ readonly functions: Schema.optional<Schema.Number>;
250
+ readonly branches: Schema.optional<Schema.Number>;
251
+ readonly statements: Schema.optional<Schema.Number>;
252
+ }>]>>, never>;
253
+ }>;
254
+ readonly targets: Schema.optional<Schema.Struct<{
255
+ readonly global: Schema.Struct<{
256
+ readonly lines: Schema.optional<Schema.Number>;
257
+ readonly functions: Schema.optional<Schema.Number>;
258
+ readonly branches: Schema.optional<Schema.Number>;
259
+ readonly statements: Schema.optional<Schema.Number>;
342
260
  }>;
343
- readonly direction: Schema.Literals<readonly ["improving", "regressing", "stable"]>;
344
- readonly targetsHash: Schema.optional<Schema.String>;
345
- }>>;
346
- }>;
347
- /** @public */
348
- type TrendRecord = typeof TrendRecord.Type;
261
+ readonly patterns: Schema.withDecodingDefaultKey<Schema.$Array<Schema.Tuple<readonly [Schema.String, Schema.Struct<{
262
+ readonly lines: Schema.optional<Schema.Number>;
263
+ readonly functions: Schema.optional<Schema.Number>;
264
+ readonly branches: Schema.optional<Schema.Number>;
265
+ readonly statements: Schema.optional<Schema.Number>;
266
+ }>]>>, never>;
267
+ }>>;
268
+ readonly baselines: Schema.optional<Schema.Struct<{
269
+ readonly global: Schema.Struct<{
270
+ readonly lines: Schema.optional<Schema.Number>;
271
+ readonly functions: Schema.optional<Schema.Number>;
272
+ readonly branches: Schema.optional<Schema.Number>;
273
+ readonly statements: Schema.optional<Schema.Number>;
274
+ }>;
275
+ readonly patterns: Schema.withDecodingDefaultKey<Schema.$Array<Schema.Tuple<readonly [Schema.String, Schema.Struct<{
276
+ readonly lines: Schema.optional<Schema.Number>;
277
+ readonly functions: Schema.optional<Schema.Number>;
278
+ readonly branches: Schema.optional<Schema.Number>;
279
+ readonly statements: Schema.optional<Schema.Number>;
280
+ }>]>>, never>;
281
+ }>>;
282
+ readonly scoped: Schema.withDecodingDefaultKey<Schema.Boolean, never>;
283
+ readonly scopedFiles: Schema.optional<Schema.$Array<Schema.String>>;
284
+ readonly lowCoverage: Schema.$Array<Schema.Struct<{
285
+ readonly file: Schema.String;
286
+ readonly summary: Schema.Struct<{
287
+ readonly statements: Schema.Number;
288
+ readonly branches: Schema.Number;
289
+ readonly functions: Schema.Number;
290
+ readonly lines: Schema.Number;
291
+ }>;
292
+ readonly uncoveredLines: Schema.String;
293
+ }>>;
294
+ readonly lowCoverageFiles: Schema.$Array<Schema.String>;
295
+ readonly belowTarget: Schema.optional<Schema.$Array<Schema.Struct<{
296
+ readonly file: Schema.String;
297
+ readonly summary: Schema.Struct<{
298
+ readonly statements: Schema.Number;
299
+ readonly branches: Schema.Number;
300
+ readonly functions: Schema.Number;
301
+ readonly lines: Schema.Number;
302
+ }>;
303
+ readonly uncoveredLines: Schema.String;
304
+ }>>>;
305
+ readonly belowTargetFiles: Schema.optional<Schema.$Array<Schema.String>>;
306
+ }>;
307
+ /** @public */
308
+ type CoverageReport = typeof CoverageReport.Type;
309
+ //#endregion
310
+ //#region src/schemas/History.d.ts
311
+ /**
312
+ * Per-project history record containing all tracked tests.
313
+ * @public
314
+ */
315
+ declare const HistoryRecord: Schema.Struct<{
316
+ readonly project: Schema.String;
317
+ readonly updatedAt: Schema.String;
318
+ readonly tests: Schema.$Array<Schema.Struct<{
319
+ readonly modulePath: Schema.String;
320
+ readonly fullName: Schema.String;
321
+ readonly runs: Schema.$Array<Schema.Struct<{
322
+ readonly timestamp: Schema.String;
323
+ readonly state: Schema.Literals<readonly ["passed", "failed"]>;
324
+ }>>;
325
+ }>>;
326
+ }>;
327
+ /** @public */
328
+ type HistoryRecord = typeof HistoryRecord.Type;
329
+ //#endregion
330
+ //#region src/schemas/Tdd.d.ts
331
+ /** @public */
332
+ declare const GoalStatus: Schema.Literals<readonly ["pending", "in_progress", "done", "abandoned"]>;
333
+ /** @public */
334
+ type GoalStatus = typeof GoalStatus.Type;
335
+ /** @public */
336
+ declare const BehaviorStatus: Schema.Literals<readonly ["pending", "in_progress", "done", "abandoned"]>;
337
+ /** @public */
338
+ type BehaviorStatus = typeof BehaviorStatus.Type;
339
+ /** @public */
340
+ declare const GoalRow: Schema.Struct<{
341
+ readonly id: Schema.Number;
342
+ readonly sessionId: Schema.Number;
343
+ readonly ordinal: Schema.Number;
344
+ readonly goal: Schema.String;
345
+ readonly status: Schema.Literals<readonly ["pending", "in_progress", "done", "abandoned"]>;
346
+ readonly createdAt: Schema.String;
347
+ }>;
348
+ /** @public */
349
+ type GoalRow = typeof GoalRow.Type;
350
+ /** @public */
351
+ declare const BehaviorRow: Schema.Struct<{
352
+ readonly id: Schema.Number;
353
+ readonly goalId: Schema.Number;
354
+ readonly ordinal: Schema.Number;
355
+ readonly behavior: Schema.String;
356
+ readonly suggestedTestName: Schema.NullOr<Schema.String>;
357
+ readonly status: Schema.Literals<readonly ["pending", "in_progress", "done", "abandoned"]>;
358
+ readonly createdAt: Schema.String;
359
+ }>;
360
+ /** @public */
361
+ type BehaviorRow = typeof BehaviorRow.Type;
362
+ /** @public */
363
+ declare const GoalDetail: Schema.Struct<{
364
+ readonly id: Schema.Number;
365
+ readonly sessionId: Schema.Number;
366
+ readonly ordinal: Schema.Number;
367
+ readonly goal: Schema.String;
368
+ readonly status: Schema.Literals<readonly ["pending", "in_progress", "done", "abandoned"]>;
369
+ readonly createdAt: Schema.String;
370
+ readonly behaviors: Schema.$Array<Schema.Struct<{
371
+ readonly id: Schema.Number;
372
+ readonly goalId: Schema.Number;
373
+ readonly ordinal: Schema.Number;
374
+ readonly behavior: Schema.String;
375
+ readonly suggestedTestName: Schema.NullOr<Schema.String>;
376
+ readonly status: Schema.Literals<readonly ["pending", "in_progress", "done", "abandoned"]>;
377
+ readonly createdAt: Schema.String;
378
+ }>>;
379
+ }>;
380
+ /** @public */
381
+ type GoalDetail = typeof GoalDetail.Type;
382
+ /** @public */
383
+ declare const BehaviorDetail: Schema.Struct<{
384
+ readonly id: Schema.Number;
385
+ readonly goalId: Schema.Number;
386
+ readonly ordinal: Schema.Number;
387
+ readonly behavior: Schema.String;
388
+ readonly suggestedTestName: Schema.NullOr<Schema.String>;
389
+ readonly status: Schema.Literals<readonly ["pending", "in_progress", "done", "abandoned"]>;
390
+ readonly createdAt: Schema.String;
391
+ readonly parentGoal: Schema.Struct<{
392
+ readonly id: Schema.Number;
393
+ readonly goal: Schema.String;
394
+ readonly status: Schema.Literals<readonly ["pending", "in_progress", "done", "abandoned"]>;
395
+ }>;
396
+ readonly dependencies: Schema.$Array<Schema.Struct<{
397
+ readonly id: Schema.Number;
398
+ readonly goalId: Schema.Number;
399
+ readonly ordinal: Schema.Number;
400
+ readonly behavior: Schema.String;
401
+ readonly suggestedTestName: Schema.NullOr<Schema.String>;
402
+ readonly status: Schema.Literals<readonly ["pending", "in_progress", "done", "abandoned"]>;
403
+ readonly createdAt: Schema.String;
404
+ }>>;
405
+ }>;
406
+ /** @public */
407
+ type BehaviorDetail = typeof BehaviorDetail.Type;
408
+ //#endregion
409
+ //#region src/schemas/Trends.d.ts
410
+ /**
411
+ * A single coverage trend data point recorded on a full test run.
412
+ * @public
413
+ */
414
+ declare const TrendEntry: Schema.Struct<{
415
+ readonly timestamp: Schema.String;
416
+ readonly coverage: Schema.Struct<{
417
+ readonly statements: Schema.Number;
418
+ readonly branches: Schema.Number;
419
+ readonly functions: Schema.Number;
420
+ readonly lines: Schema.Number;
421
+ }>;
422
+ readonly delta: Schema.Struct<{
423
+ readonly statements: Schema.Number;
424
+ readonly branches: Schema.Number;
425
+ readonly functions: Schema.Number;
426
+ readonly lines: Schema.Number;
427
+ }>;
428
+ readonly direction: Schema.Literals<readonly ["improving", "regressing", "stable"]>;
429
+ readonly targetsHash: Schema.optional<Schema.String>;
430
+ }>;
431
+ /** @public */
432
+ type TrendEntry = typeof TrendEntry.Type;
433
+ /**
434
+ * Per-project trend record with sliding window of entries.
435
+ * @public
436
+ */
437
+ declare const TrendRecord: Schema.Struct<{
438
+ readonly entries: Schema.$Array<Schema.Struct<{
439
+ readonly timestamp: Schema.String;
440
+ readonly coverage: Schema.Struct<{
441
+ readonly statements: Schema.Number;
442
+ readonly branches: Schema.Number;
443
+ readonly functions: Schema.Number;
444
+ readonly lines: Schema.Number;
445
+ }>;
446
+ readonly delta: Schema.Struct<{
447
+ readonly statements: Schema.Number;
448
+ readonly branches: Schema.Number;
449
+ readonly functions: Schema.Number;
450
+ readonly lines: Schema.Number;
451
+ }>;
452
+ readonly direction: Schema.Literals<readonly ["improving", "regressing", "stable"]>;
453
+ readonly targetsHash: Schema.optional<Schema.String>;
454
+ }>>;
455
+ }>;
456
+ /** @public */
457
+ type TrendRecord = typeof TrendRecord.Type;
349
458
  //#endregion
350
459
  //#region src/utils/validate-phase-transition.d.ts
351
460
  /** @public */
@@ -364,20 +473,194 @@ interface CitedArtifact {
364
473
  readonly behavior_id: number | null;
365
474
  }
366
475
  //#endregion
367
- //#region src/services/DataStore.d.ts
476
+ //#region src/schemas/Identity.d.ts
477
+ /**
478
+ * Canonical UUID for an LLM agent invocation. Generated server-side at
479
+ * `register_agent` time. Stable across transport reconnects within an
480
+ * agent's lifetime.
481
+ * @public
482
+ */
483
+ declare const AgentId: Schema.brand<Schema.String, "AgentId">;
368
484
  /** @public */
369
- interface CreateGoalInput {
370
- readonly tddTaskId: number;
371
- readonly goal: string;
372
- }
485
+ type AgentId = Schema.Schema.Type<typeof AgentId>;
486
+ /**
487
+ * The agent host process's chat id (Claude Code's per-process chat
488
+ * UUID, etc.). Shorter-lived than a conversation; one conversation can
489
+ * have multiple chats across `--resume` invocations. Distinct from
490
+ * `sessions.id` (the SQLite agent-run PK).
491
+ * @public
492
+ */
493
+ declare const ChatId: Schema.brand<Schema.String, "ChatId">;
373
494
  /** @public */
374
- interface UpdateGoalInput {
375
- readonly id: number;
376
- readonly goal?: string;
377
- readonly status?: GoalStatus;
495
+ type ChatId = Schema.Schema.Type<typeof ChatId>;
496
+ //#endregion
497
+ //#region src/errors/AgentErrors.d.ts
498
+ declare const AgentNotFoundError_base: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P]; }>) => import("effect/Cause").YieldableError & {
499
+ readonly _tag: "AgentNotFoundError";
500
+ } & Readonly<A>;
501
+ /**
502
+ * `agent_id` does not exist for the given chat. Surface to the
503
+ * caller; the typical resolution is to call `register_agent` for
504
+ * this agent first.
505
+ * @public
506
+ */
507
+ declare class AgentNotFoundError extends AgentNotFoundError_base<{
508
+ readonly agentId: AgentId;
509
+ readonly chatId?: ChatId;
510
+ }> {}
511
+ declare const RegistrationConflictError_base: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P]; }>) => import("effect/Cause").YieldableError & {
512
+ readonly _tag: "RegistrationConflictError";
513
+ } & Readonly<A>;
514
+ /**
515
+ * True conflict — e.g., the `parentAgentId` supplied to
516
+ * `register_agent` refers to a different session than the one the
517
+ * caller named. Distinct from `IdempotencyHit`, which is a success.
518
+ * @public
519
+ */
520
+ declare class RegistrationConflictError extends RegistrationConflictError_base<{
521
+ readonly reason: string;
522
+ }> {
523
+ constructor(args: {
524
+ readonly reason: string;
525
+ });
378
526
  }
379
- /** @public */
380
- interface CreateBehaviorInput {
527
+ //#endregion
528
+ //#region src/errors/TddErrors.d.ts
529
+ declare const GoalNotFoundError_base: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P]; }>) => import("effect/Cause").YieldableError & {
530
+ readonly _tag: "GoalNotFoundError";
531
+ } & Readonly<A>;
532
+ /** @public */
533
+ declare class GoalNotFoundError extends GoalNotFoundError_base<{
534
+ readonly id: number;
535
+ readonly reason: string;
536
+ }> {
537
+ constructor(args: {
538
+ readonly id: number;
539
+ readonly reason: string;
540
+ });
541
+ }
542
+ declare const BehaviorNotFoundError_base: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P]; }>) => import("effect/Cause").YieldableError & {
543
+ readonly _tag: "BehaviorNotFoundError";
544
+ } & Readonly<A>;
545
+ /** @public */
546
+ declare class BehaviorNotFoundError extends BehaviorNotFoundError_base<{
547
+ readonly id: number;
548
+ readonly reason: string;
549
+ }> {
550
+ constructor(args: {
551
+ readonly id: number;
552
+ readonly reason: string;
553
+ });
554
+ }
555
+ declare const TddTaskNotFoundError_base: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P]; }>) => import("effect/Cause").YieldableError & {
556
+ readonly _tag: "TddTaskNotFoundError";
557
+ } & Readonly<A>;
558
+ /** @public */
559
+ declare class TddTaskNotFoundError extends TddTaskNotFoundError_base<{
560
+ readonly id: number;
561
+ readonly reason: string;
562
+ }> {
563
+ constructor(args: {
564
+ readonly id: number;
565
+ readonly reason: string;
566
+ });
567
+ }
568
+ /** @public */
569
+ type TddTaskEndOutcome = "succeeded" | "blocked" | "abandoned";
570
+ declare const TddTaskAlreadyEndedError_base: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P]; }>) => import("effect/Cause").YieldableError & {
571
+ readonly _tag: "TddTaskAlreadyEndedError";
572
+ } & Readonly<A>;
573
+ /** @public */
574
+ declare class TddTaskAlreadyEndedError extends TddTaskAlreadyEndedError_base<{
575
+ readonly id: number;
576
+ readonly endedAt: string;
577
+ readonly outcome: TddTaskEndOutcome;
578
+ }> {
579
+ constructor(args: {
580
+ readonly id: number;
581
+ readonly endedAt: string;
582
+ readonly outcome: TddTaskEndOutcome;
583
+ });
584
+ }
585
+ /** @public */
586
+ type IllegalStatusTransitionEntity = "goal" | "behavior" | "task";
587
+ declare const IllegalStatusTransitionError_base: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P]; }>) => import("effect/Cause").YieldableError & {
588
+ readonly _tag: "IllegalStatusTransitionError";
589
+ } & Readonly<A>;
590
+ /** @public */
591
+ declare class IllegalStatusTransitionError extends IllegalStatusTransitionError_base<{
592
+ readonly entity: IllegalStatusTransitionEntity;
593
+ readonly id: number;
594
+ readonly from: string;
595
+ readonly to: string;
596
+ readonly reason: string;
597
+ }> {
598
+ constructor(args: {
599
+ readonly entity: IllegalStatusTransitionEntity;
600
+ readonly id: number;
601
+ readonly from: string;
602
+ readonly to: string;
603
+ readonly reason: string;
604
+ });
605
+ }
606
+ //#endregion
607
+ //#region src/schemas/Agent.d.ts
608
+ declare const Agent_base: Schema.Class<Agent, Schema.TaggedStruct<"Agent", {
609
+ readonly agentId: Schema.brand<Schema.String, "AgentId">;
610
+ readonly sessionId: Schema.Number;
611
+ readonly parentAgentId: Schema.NullOr<Schema.brand<Schema.String, "AgentId">>;
612
+ readonly conversationId: Schema.NullOr<Schema.brand<Schema.String, "ConversationId">>;
613
+ readonly agentType: Schema.String;
614
+ readonly startedAt: Schema.Number;
615
+ readonly endedAt: Schema.NullOr<Schema.Number>;
616
+ readonly startGitBranch: Schema.NullOr<Schema.String>;
617
+ readonly startGitCommitSha: Schema.NullOr<Schema.String>;
618
+ readonly startWorktreeDir: Schema.NullOr<Schema.String>;
619
+ readonly idempotencyKey: Schema.String;
620
+ }>, {}>;
621
+ /**
622
+ * Successful registration row. The fields mirror the `agents` SQLite
623
+ * table 1:1 in camelCase.
624
+ *
625
+ * `startGitBranch`, `startGitCommitSha`, `startWorktreeDir` capture
626
+ * *what the agent inherited at registration time* — distinct from the
627
+ * per-run git context recorded on `runs`. A divergence between the
628
+ * two reveals a mid-session branch switch, which is itself signal.
629
+ * @public
630
+ */
631
+ declare class Agent extends Agent_base {}
632
+ declare const IdempotencyHit_base: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P]; }>) => Readonly<A> & {
633
+ readonly _tag: "IdempotencyHit";
634
+ } & import("effect/Pipeable").Pipeable;
635
+ /**
636
+ * Returned by `DataStore.registerAgent` when the
637
+ * `(session_id, idempotency_key)` UNIQUE constraint already has a
638
+ * row. Not an error — the caller treats it as a successful recovery
639
+ * of the existing `agentId`.
640
+ *
641
+ * Modeled as a `Data.TaggedClass` so the success channel of
642
+ * `registerAgent` is `Effect<Agent | IdempotencyHit, ...>` and
643
+ * downstream code uses `Match.tag` to branch.
644
+ * @public
645
+ */
646
+ declare class IdempotencyHit extends IdempotencyHit_base<{
647
+ readonly existingAgentId: typeof AgentId.Type;
648
+ }> {}
649
+ //#endregion
650
+ //#region src/services/DataStore.d.ts
651
+ /** @public */
652
+ interface CreateGoalInput {
653
+ readonly tddTaskId: number;
654
+ readonly goal: string;
655
+ }
656
+ /** @public */
657
+ interface UpdateGoalInput {
658
+ readonly id: number;
659
+ readonly goal?: string;
660
+ readonly status?: GoalStatus;
661
+ }
662
+ /** @public */
663
+ interface CreateBehaviorInput {
381
664
  readonly goalId: number;
382
665
  readonly behavior: string;
383
666
  readonly suggestedTestName?: string;
@@ -809,289 +1092,6 @@ declare const DataStore_base: Context.ServiceClass<DataStore, "vitest-agent/Data
809
1092
  /** @public */
810
1093
  declare class DataStore extends DataStore_base {}
811
1094
  //#endregion
812
- //#region src/schemas/AgentReport.d.ts
813
- /**
814
- * Complete per-project test report written to disk as JSON.
815
- * @public
816
- */
817
- declare const AgentReport: Schema.Struct<{
818
- readonly timestamp: Schema.String;
819
- readonly project: Schema.optional<Schema.String>;
820
- readonly reason: Schema.Literals<readonly ["passed", "failed", "interrupted"]>;
821
- readonly summary: Schema.Struct<{
822
- readonly total: Schema.Number;
823
- readonly passed: Schema.Number;
824
- readonly failed: Schema.Number;
825
- readonly skipped: Schema.Number;
826
- readonly duration: Schema.Number;
827
- }>;
828
- readonly failed: Schema.$Array<Schema.Struct<{
829
- readonly file: Schema.String;
830
- readonly state: Schema.Literals<readonly ["passed", "failed", "skipped", "pending"]>;
831
- readonly duration: Schema.optional<Schema.Number>;
832
- readonly errors: Schema.optional<Schema.$Array<Schema.Struct<{
833
- readonly message: Schema.String;
834
- readonly stack: Schema.optional<Schema.String>;
835
- readonly diff: Schema.optional<Schema.String>;
836
- readonly expected: Schema.optional<Schema.String>;
837
- readonly received: Schema.optional<Schema.String>;
838
- }>>>;
839
- readonly tests: Schema.$Array<Schema.Struct<{
840
- readonly name: Schema.String;
841
- readonly fullName: Schema.String;
842
- readonly state: Schema.Literals<readonly ["passed", "failed", "skipped", "pending"]>;
843
- readonly duration: Schema.optional<Schema.Number>;
844
- readonly flaky: Schema.optional<Schema.Boolean>;
845
- readonly slow: Schema.optional<Schema.Boolean>;
846
- readonly errors: Schema.optional<Schema.$Array<Schema.Struct<{
847
- readonly message: Schema.String;
848
- readonly stack: Schema.optional<Schema.String>;
849
- readonly diff: Schema.optional<Schema.String>;
850
- readonly expected: Schema.optional<Schema.String>;
851
- readonly received: Schema.optional<Schema.String>;
852
- }>>>;
853
- readonly classification: Schema.optional<Schema.Literals<readonly ["stable", "new-failure", "persistent", "flaky", "recovered"]>>;
854
- }>>;
855
- }>>;
856
- readonly unhandledErrors: Schema.$Array<Schema.Struct<{
857
- readonly message: Schema.String;
858
- readonly stack: Schema.optional<Schema.String>;
859
- readonly diff: Schema.optional<Schema.String>;
860
- readonly expected: Schema.optional<Schema.String>;
861
- readonly received: Schema.optional<Schema.String>;
862
- }>>;
863
- readonly failedFiles: Schema.$Array<Schema.String>;
864
- readonly coverage: Schema.optional<Schema.Struct<{
865
- readonly totals: Schema.Struct<{
866
- readonly statements: Schema.Number;
867
- readonly branches: Schema.Number;
868
- readonly functions: Schema.Number;
869
- readonly lines: Schema.Number;
870
- }>;
871
- readonly thresholds: Schema.Struct<{
872
- readonly global: Schema.Struct<{
873
- readonly lines: Schema.optional<Schema.Number>;
874
- readonly functions: Schema.optional<Schema.Number>;
875
- readonly branches: Schema.optional<Schema.Number>;
876
- readonly statements: Schema.optional<Schema.Number>;
877
- }>;
878
- readonly patterns: Schema.withDecodingDefaultKey<Schema.$Array<Schema.Tuple<readonly [Schema.String, Schema.Struct<{
879
- readonly lines: Schema.optional<Schema.Number>;
880
- readonly functions: Schema.optional<Schema.Number>;
881
- readonly branches: Schema.optional<Schema.Number>;
882
- readonly statements: Schema.optional<Schema.Number>;
883
- }>]>>, never>;
884
- }>;
885
- readonly targets: Schema.optional<Schema.Struct<{
886
- readonly global: Schema.Struct<{
887
- readonly lines: Schema.optional<Schema.Number>;
888
- readonly functions: Schema.optional<Schema.Number>;
889
- readonly branches: Schema.optional<Schema.Number>;
890
- readonly statements: Schema.optional<Schema.Number>;
891
- }>;
892
- readonly patterns: Schema.withDecodingDefaultKey<Schema.$Array<Schema.Tuple<readonly [Schema.String, Schema.Struct<{
893
- readonly lines: Schema.optional<Schema.Number>;
894
- readonly functions: Schema.optional<Schema.Number>;
895
- readonly branches: Schema.optional<Schema.Number>;
896
- readonly statements: Schema.optional<Schema.Number>;
897
- }>]>>, never>;
898
- }>>;
899
- readonly baselines: Schema.optional<Schema.Struct<{
900
- readonly global: Schema.Struct<{
901
- readonly lines: Schema.optional<Schema.Number>;
902
- readonly functions: Schema.optional<Schema.Number>;
903
- readonly branches: Schema.optional<Schema.Number>;
904
- readonly statements: Schema.optional<Schema.Number>;
905
- }>;
906
- readonly patterns: Schema.withDecodingDefaultKey<Schema.$Array<Schema.Tuple<readonly [Schema.String, Schema.Struct<{
907
- readonly lines: Schema.optional<Schema.Number>;
908
- readonly functions: Schema.optional<Schema.Number>;
909
- readonly branches: Schema.optional<Schema.Number>;
910
- readonly statements: Schema.optional<Schema.Number>;
911
- }>]>>, never>;
912
- }>>;
913
- readonly scoped: Schema.withDecodingDefaultKey<Schema.Boolean, never>;
914
- readonly scopedFiles: Schema.optional<Schema.$Array<Schema.String>>;
915
- readonly lowCoverage: Schema.$Array<Schema.Struct<{
916
- readonly file: Schema.String;
917
- readonly summary: Schema.Struct<{
918
- readonly statements: Schema.Number;
919
- readonly branches: Schema.Number;
920
- readonly functions: Schema.Number;
921
- readonly lines: Schema.Number;
922
- }>;
923
- readonly uncoveredLines: Schema.String;
924
- }>>;
925
- readonly lowCoverageFiles: Schema.$Array<Schema.String>;
926
- readonly belowTarget: Schema.optional<Schema.$Array<Schema.Struct<{
927
- readonly file: Schema.String;
928
- readonly summary: Schema.Struct<{
929
- readonly statements: Schema.Number;
930
- readonly branches: Schema.Number;
931
- readonly functions: Schema.Number;
932
- readonly lines: Schema.Number;
933
- }>;
934
- readonly uncoveredLines: Schema.String;
935
- }>>>;
936
- readonly belowTargetFiles: Schema.optional<Schema.$Array<Schema.String>>;
937
- }>>;
938
- readonly tagCounts: Schema.optional<Schema.$Record<Schema.String, Schema.Struct<{
939
- readonly passed: Schema.optional<Schema.Number>;
940
- readonly failed: Schema.optional<Schema.Number>;
941
- readonly skipped: Schema.optional<Schema.Number>;
942
- }>>>;
943
- readonly consoleLeaks: Schema.optional<Schema.Struct<{
944
- readonly total: Schema.Number;
945
- readonly byFile: Schema.$Array<Schema.Struct<{
946
- readonly file: Schema.String;
947
- readonly stdout: Schema.Number;
948
- readonly stderr: Schema.Number;
949
- readonly tests: Schema.optional<Schema.$Array<Schema.String>>;
950
- readonly sample: Schema.optional<Schema.String>;
951
- }>>;
952
- readonly truncated: Schema.optional<Schema.Boolean>;
953
- }>>;
954
- }>;
955
- /** @public */
956
- type AgentReport = typeof AgentReport.Type;
957
- //#endregion
958
- //#region src/schemas/CacheManifest.d.ts
959
- /**
960
- * Root manifest file that indexes all project reports.
961
- * @public
962
- */
963
- declare const CacheManifest: Schema.Struct<{
964
- readonly updatedAt: Schema.String;
965
- readonly cacheDir: Schema.String;
966
- readonly projects: Schema.$Array<Schema.Struct<{
967
- readonly project: Schema.String;
968
- readonly reportFile: Schema.String;
969
- readonly historyFile: Schema.optional<Schema.String>;
970
- readonly lastRun: Schema.NullOr<Schema.String>;
971
- readonly lastResult: Schema.NullOr<Schema.Literals<readonly ["passed", "failed", "interrupted"]>>;
972
- }>>;
973
- }>;
974
- /** @public */
975
- type CacheManifest = typeof CacheManifest.Type;
976
- //#endregion
977
- //#region src/schemas/Coverage.d.ts
978
- /**
979
- * Per-file coverage data including uncovered line ranges.
980
- * @public
981
- */
982
- declare const FileCoverageReport: Schema.Struct<{
983
- readonly file: Schema.String;
984
- readonly summary: Schema.Struct<{
985
- readonly statements: Schema.Number;
986
- readonly branches: Schema.Number;
987
- readonly functions: Schema.Number;
988
- readonly lines: Schema.Number;
989
- }>;
990
- readonly uncoveredLines: Schema.String;
991
- }>;
992
- /** @public */
993
- type FileCoverageReport = typeof FileCoverageReport.Type;
994
- /**
995
- * Complete coverage report attached to an AgentReport.
996
- * @public
997
- */
998
- declare const CoverageReport: Schema.Struct<{
999
- readonly totals: Schema.Struct<{
1000
- readonly statements: Schema.Number;
1001
- readonly branches: Schema.Number;
1002
- readonly functions: Schema.Number;
1003
- readonly lines: Schema.Number;
1004
- }>;
1005
- readonly thresholds: Schema.Struct<{
1006
- readonly global: Schema.Struct<{
1007
- readonly lines: Schema.optional<Schema.Number>;
1008
- readonly functions: Schema.optional<Schema.Number>;
1009
- readonly branches: Schema.optional<Schema.Number>;
1010
- readonly statements: Schema.optional<Schema.Number>;
1011
- }>;
1012
- readonly patterns: Schema.withDecodingDefaultKey<Schema.$Array<Schema.Tuple<readonly [Schema.String, Schema.Struct<{
1013
- readonly lines: Schema.optional<Schema.Number>;
1014
- readonly functions: Schema.optional<Schema.Number>;
1015
- readonly branches: Schema.optional<Schema.Number>;
1016
- readonly statements: Schema.optional<Schema.Number>;
1017
- }>]>>, never>;
1018
- }>;
1019
- readonly targets: Schema.optional<Schema.Struct<{
1020
- readonly global: Schema.Struct<{
1021
- readonly lines: Schema.optional<Schema.Number>;
1022
- readonly functions: Schema.optional<Schema.Number>;
1023
- readonly branches: Schema.optional<Schema.Number>;
1024
- readonly statements: Schema.optional<Schema.Number>;
1025
- }>;
1026
- readonly patterns: Schema.withDecodingDefaultKey<Schema.$Array<Schema.Tuple<readonly [Schema.String, Schema.Struct<{
1027
- readonly lines: Schema.optional<Schema.Number>;
1028
- readonly functions: Schema.optional<Schema.Number>;
1029
- readonly branches: Schema.optional<Schema.Number>;
1030
- readonly statements: Schema.optional<Schema.Number>;
1031
- }>]>>, never>;
1032
- }>>;
1033
- readonly baselines: Schema.optional<Schema.Struct<{
1034
- readonly global: Schema.Struct<{
1035
- readonly lines: Schema.optional<Schema.Number>;
1036
- readonly functions: Schema.optional<Schema.Number>;
1037
- readonly branches: Schema.optional<Schema.Number>;
1038
- readonly statements: Schema.optional<Schema.Number>;
1039
- }>;
1040
- readonly patterns: Schema.withDecodingDefaultKey<Schema.$Array<Schema.Tuple<readonly [Schema.String, Schema.Struct<{
1041
- readonly lines: Schema.optional<Schema.Number>;
1042
- readonly functions: Schema.optional<Schema.Number>;
1043
- readonly branches: Schema.optional<Schema.Number>;
1044
- readonly statements: Schema.optional<Schema.Number>;
1045
- }>]>>, never>;
1046
- }>>;
1047
- readonly scoped: Schema.withDecodingDefaultKey<Schema.Boolean, never>;
1048
- readonly scopedFiles: Schema.optional<Schema.$Array<Schema.String>>;
1049
- readonly lowCoverage: Schema.$Array<Schema.Struct<{
1050
- readonly file: Schema.String;
1051
- readonly summary: Schema.Struct<{
1052
- readonly statements: Schema.Number;
1053
- readonly branches: Schema.Number;
1054
- readonly functions: Schema.Number;
1055
- readonly lines: Schema.Number;
1056
- }>;
1057
- readonly uncoveredLines: Schema.String;
1058
- }>>;
1059
- readonly lowCoverageFiles: Schema.$Array<Schema.String>;
1060
- readonly belowTarget: Schema.optional<Schema.$Array<Schema.Struct<{
1061
- readonly file: Schema.String;
1062
- readonly summary: Schema.Struct<{
1063
- readonly statements: Schema.Number;
1064
- readonly branches: Schema.Number;
1065
- readonly functions: Schema.Number;
1066
- readonly lines: Schema.Number;
1067
- }>;
1068
- readonly uncoveredLines: Schema.String;
1069
- }>>>;
1070
- readonly belowTargetFiles: Schema.optional<Schema.$Array<Schema.String>>;
1071
- }>;
1072
- /** @public */
1073
- type CoverageReport = typeof CoverageReport.Type;
1074
- //#endregion
1075
- //#region src/schemas/History.d.ts
1076
- /**
1077
- * Per-project history record containing all tracked tests.
1078
- * @public
1079
- */
1080
- declare const HistoryRecord: Schema.Struct<{
1081
- readonly project: Schema.String;
1082
- readonly updatedAt: Schema.String;
1083
- readonly tests: Schema.$Array<Schema.Struct<{
1084
- readonly modulePath: Schema.String;
1085
- readonly fullName: Schema.String;
1086
- readonly runs: Schema.$Array<Schema.Struct<{
1087
- readonly timestamp: Schema.String;
1088
- readonly state: Schema.Literals<readonly ["passed", "failed"]>;
1089
- }>>;
1090
- }>>;
1091
- }>;
1092
- /** @public */
1093
- type HistoryRecord = typeof HistoryRecord.Type;
1094
- //#endregion
1095
1095
  //#region src/services/DataReader.d.ts
1096
1096
  /** @public */
1097
1097
  interface ProjectRunSummary {