@vitest-agent/reporter 2.0.16 → 2.0.17

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.
Files changed (3) hide show
  1. package/index.d.ts +26 -0
  2. package/index.js +1 -1
  3. package/package.json +3 -3
package/index.d.ts CHANGED
@@ -135,6 +135,16 @@ declare const RenderState: Schema.Struct<{
135
135
  readonly detail: Schema.String;
136
136
  readonly targetTool: Schema.optional<Schema.String>;
137
137
  }>>;
138
+ /**
139
+ * Count of every collected module, passing modules included. Folded
140
+ * from `RunFinished.collectedModules`. Renderers prefer this over
141
+ * `moduleOrder.length` for "N modules all-passed" copy — a report
142
+ * replay only queues failing modules, so `moduleOrder` alone
143
+ * undercounts a green run to zero (issue #204). Optional — a run
144
+ * that never carried the field (older replay data, hand-built
145
+ * fixtures) falls back to `moduleOrder.length`.
146
+ */
147
+ readonly collectedModules: Schema.optional<Schema.Number>;
138
148
  }>;
139
149
  /** @public */
140
150
  type RenderState = typeof RenderState.Type;
@@ -274,6 +284,14 @@ declare const AgentReport: Schema.Struct<{
274
284
  readonly failed: Schema.Number;
275
285
  readonly skipped: Schema.Number;
276
286
  readonly duration: Schema.Number;
287
+ /**
288
+ * Count of every collected module, passing modules included.
289
+ * `AgentReport.failed` only carries failing modules, so a green run
290
+ * has no other way to know how many files actually ran — without
291
+ * this a fully-passing replay reads as "0 modules all-passed"
292
+ * (issue #204). Optional to keep existing fixtures/reports valid.
293
+ */
294
+ readonly modules: Schema.optional<Schema.Number>;
277
295
  }>;
278
296
  readonly failed: Schema.$Array<Schema.Struct<{
279
297
  readonly file: Schema.String;
@@ -603,6 +621,14 @@ declare const RunEvent: Schema.Union<readonly [Schema.TaggedStruct<"RunStarted",
603
621
  readonly skipCount: Schema.Number;
604
622
  readonly durationMs: Schema.Number;
605
623
  readonly timeoutCount: Schema.optional<Schema.Number>;
624
+ /**
625
+ * Count of every collected module, passing modules included.
626
+ * Carries `AgentReport.summary.modules` (or the live module
627
+ * count) into the event stream so the reducer can fold the
628
+ * true count into `RenderState` even when `moduleOrder` only
629
+ * tracks failing modules (report replay). See issue #204.
630
+ */
631
+ readonly collectedModules: Schema.optional<Schema.Number>;
606
632
  }>]>;
607
633
  /** @public */
608
634
  type RunEvent = typeof RunEvent.Type;
package/index.js CHANGED
@@ -9,7 +9,7 @@ import { DefaultVitestAgentReporter, buildDispatchInputs, renderAgentStringForRe
9
9
  *
10
10
  * @public
11
11
  */
12
- const CURRENT_REPORTER_VERSION = "2.0.16";
12
+ const CURRENT_REPORTER_VERSION = "2.0.17";
13
13
 
14
14
  //#endregion
15
15
  export { CURRENT_REPORTER_VERSION, DefaultVitestAgentReporter, createLiveInk as _createLiveInk, buildDispatchInputs, renderAgentStringForReport, renderHumanStringForReport, resolveCellOptions };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vitest-agent/reporter",
3
- "version": "2.0.16",
3
+ "version": "2.0.17",
4
4
  "private": false,
5
5
  "description": "Named VitestAgentReporterFactory implementations for the vitest-agent ecosystem.",
6
6
  "keywords": [
@@ -41,8 +41,8 @@
41
41
  "dependencies": {
42
42
  "@effect/platform-node": "4.0.0-beta.107",
43
43
  "@effect/sql-sqlite-node": "4.0.0-beta.107",
44
- "@vitest-agent/sdk": "2.0.16",
45
- "@vitest-agent/ui": "2.0.16",
44
+ "@vitest-agent/sdk": "2.1.0",
45
+ "@vitest-agent/ui": "2.1.0",
46
46
  "effect": "4.0.0-beta.107",
47
47
  "ink": "^7.1.1",
48
48
  "react": "^19.2.8"