spec-controller 0.1.231 → 0.1.233

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/dist/cli.js CHANGED
@@ -11656,7 +11656,7 @@ function evidenceObligationsOf(evidenceObligations2) {
11656
11656
  return evidenceObligations2.filter((obligation) => !obligation.pending);
11657
11657
  }
11658
11658
  function pendingItemsOf(scenario) {
11659
- return scenario.evidenceObligations.filter((obligation) => obligation.pending).map((obligation) => ({ qualityCheckKind: obligation.qualityCheckKind }));
11659
+ return scenario.evidenceObligations.filter((obligation) => obligation.pending).map((obligation) => ({ qualityCheckKind: obligation.qualityCheckKind ?? null }));
11660
11660
  }
11661
11661
  function evidenceOfRunResult(result) {
11662
11662
  if (result === "inconclusive")
@@ -11806,19 +11806,18 @@ function noScnCodeReconciliations() {
11806
11806
  }
11807
11807
  function duplicateScnCodeReconciliationsOf(obligations, scenario) {
11808
11808
  const naming = scenario === void 0 ? {} : { scenario };
11809
- const firstNaming = /* @__PURE__ */ new Map();
11809
+ const kinds = /* @__PURE__ */ new Set();
11810
11810
  for (const obligation of obligations) {
11811
- if (obligation.qualityCheckKind !== void 0 && !firstNaming.has(obligation.qualityCheckKind)) {
11812
- firstNaming.set(obligation.qualityCheckKind, obligation);
11813
- }
11811
+ if (obligation.qualityCheckKind !== void 0)
11812
+ kinds.add(obligation.qualityCheckKind);
11814
11813
  }
11815
- if (firstNaming.size === 0) {
11814
+ if (kinds.size === 0) {
11816
11815
  return [makeQualityCheckReconciliation({ outcome: "duplicate-scn-code", evidenceObligation: { qualityCheckKind: null }, ...naming })];
11817
11816
  }
11818
- return [...firstNaming].map(([qualityCheckKind, evidenceObligation]) => makeQualityCheckReconciliation({
11817
+ return [...kinds].map((qualityCheckKind) => makeQualityCheckReconciliation({
11819
11818
  qualityCheckKind,
11820
11819
  outcome: "duplicate-scn-code",
11821
- evidenceObligation: { ...evidenceObligation, qualityCheckKind },
11820
+ evidenceObligation: { qualityCheckKind },
11822
11821
  ...naming
11823
11822
  }));
11824
11823
  }
@@ -11919,7 +11918,7 @@ function carriesQualityCheckKind(row, qualityCheckKind) {
11919
11918
  return row.qualityCheckReconciliations.some((r) => r.qualityCheckKind === qualityCheckKind && linesOf(r).some((line) => line.outcome !== "broken"));
11920
11919
  }
11921
11920
  function namesQualityCheckKind(row, qualityCheckKind) {
11922
- return evidenceObligationsOf(obligationsOf(row)).some((o) => o.qualityCheckKind === qualityCheckKind);
11921
+ return obligationsOf(row).some((o) => o.qualityCheckKind === qualityCheckKind);
11923
11922
  }
11924
11923
  function observationCountOf(row, qualityCheckKind) {
11925
11924
  return ranObservationsOf(row).filter((o) => o.qualityCheckKind === qualityCheckKind).length;
@@ -28331,7 +28330,7 @@ var init_messages_en = __esm({
28331
28330
  "verdict-column": "Verdict",
28332
28331
  "reconciling-items-column": "Reconciling items",
28333
28332
  "ci-steps-column": "CI steps",
28334
- "evidence-cell-key": "Key: each evidence cell reads *obligation*/*observations*.\n- The letter says the scenario's tags raise an Evidence Obligation of that kind: (F)itness, (U)nit, (I)ntegration, (E)2e, (P)erformance. `-` means they raise none of that kind, as a pending tag raises none.\n- The number counts the scenario's Evidence Observations of that kind that ran. `-` means none.\n- For example, `U/2` is a unit obligation answered by two unit tests; `U/-` is a unit obligation that no unit test answered; `-/1` is one unit test citing a scenario that raises no unit obligation, which puts the row out of balance even where its unit evidence is pending.\n- A blank cell means no obligation and no Evidence Observation that ran; `\u2014` marks the row of a phantom claim or of the unnamed claim.\n- A row named `feature file : scenario title` is a scenario that carries no @SCN code. The run reads none of its tags, so its evidence cells are blank, and its reconciling item says that no Evidence Observation can link to it.\n- In Reconciling items, `\u2014` means the row has no reconciling item, and *untagged* means a scenario that carries an @SCN code and no tag that raises an Evidence Obligation.\n- On the unnamed claim's row, the counts after an item, such as `1 ran, 1 passed, 0 failed`, are of that item's own tests, and a fitness item counts its CI steps; a broken item stands alone, outside those counts.\n- CI steps names the steps the Evidence observations table gives for each kind of quality check other than fitness that the row obligates or observes, whether or not an Evidence Observation of that kind ran for the row, and the step each of the row's fitness Evidence Observations names: `U/-` beside a step names the step that runs unit tests, none of which answered this row. A blank CI steps cell means no such step is known.",
28333
+ "evidence-cell-key": "Key: each evidence cell reads *obligation*/*observations*.\n- The letter says the scenario's tags raise an Evidence Obligation of that kind: (F)itness, (U)nit, (I)ntegration, (E)2e, (P)erformance. `-` means they raise none of that kind, as a pending tag raises none unless the scenario shares its `@SCN` code with another.\n- The number counts the scenario's Evidence Observations of that kind that ran. `-` means none.\n- For example, `U/2` is a unit obligation answered by two unit tests; `U/-` is a unit obligation that no unit test answered; `-/1` is one unit test citing a scenario that raises no unit obligation, which puts the row out of balance even where its unit evidence is pending.\n- A blank cell means no obligation and no Evidence Observation that ran; `\u2014` marks the row of a phantom claim or of the unnamed claim.\n- A row named `feature file : scenario title` is a scenario that carries no @SCN code. The run reads none of its tags, so its evidence cells are blank, and its reconciling item says that no Evidence Observation can link to it.\n- In Reconciling items, `\u2014` means the row has no reconciling item, and *untagged* means a scenario that carries an @SCN code and no tag that raises an Evidence Obligation.\n- On the unnamed claim's row, the counts after an item, such as `1 ran, 1 passed, 0 failed`, are of that item's own tests, and a fitness item counts its CI steps; a broken item stands alone, outside those counts.\n- CI steps names the steps the Evidence observations table gives for each kind of quality check other than fitness that the row obligates or observes, whether or not an Evidence Observation of that kind ran for the row, and the step each of the row's fitness Evidence Observations names: `U/-` beside a step names the step that runs unit tests, none of which answered this row. A blank CI steps cell means no such step is known.",
28335
28334
  "watermelon-item-key": "- Where a row's item says its CI step or its job sets `continue-on-error`, the name in parentheses after it is its fitness function. Remove `continue-on-error` from its CI step and from its job, or set it to false, and the check's red fails the CI run.",
28336
28335
  "pending-item": "pending",
28337
28336
  "pending-item-for": "pending: {qualityCheckKind}",
@@ -32109,7 +32108,8 @@ function resultOf(o) {
32109
32108
  return o.status === void 0 ? "" : ` \u2014 ${coreMessage(RESULT_MESSAGE[o.status])}`;
32110
32109
  }
32111
32110
  function renderPendingItem(item) {
32112
- return item.qualityCheckKind === void 0 ? coreMessage(CoreMessage.PendingItem) : coreMessage(CoreMessage.PendingItemFor, { qualityCheckKind: item.qualityCheckKind });
32111
+ const kind = item.qualityCheckKind;
32112
+ return kind === void 0 || kind === null ? coreMessage(CoreMessage.PendingItem) : coreMessage(CoreMessage.PendingItemFor, { qualityCheckKind: kind });
32113
32113
  }
32114
32114
  function renderFileGroup(group) {
32115
32115
  const remarks = group.remarks.flatMap((remark) => remarkHeadlineOf(remark, reportedName) ?? []);
@@ -32944,7 +32944,8 @@ var init_inputShapes = __esm({
32944
32944
  fields: {
32945
32945
  qualityCheckReconciliations: {
32946
32946
  list: { fields: { evidenceObligation: { fields: { qualityCheckKind: "anything" }, required: ["qualityCheckKind"] } } }
32947
- }
32947
+ },
32948
+ pendingItems: { list: { fields: { qualityCheckKind: "anything" }, required: ["qualityCheckKind"] } }
32948
32949
  }
32949
32950
  }
32950
32951
  },
@@ -882,9 +882,6 @@
882
882
  "type": "null"
883
883
  }
884
884
  ]
885
- },
886
- "pending": {
887
- "type": "boolean"
888
885
  }
889
886
  },
890
887
  "required": [
@@ -1095,9 +1092,19 @@
1095
1092
  "type": "object",
1096
1093
  "properties": {
1097
1094
  "qualityCheckKind": {
1098
- "$ref": "#/definitions/QualityCheckKind"
1095
+ "anyOf": [
1096
+ {
1097
+ "$ref": "#/definitions/QualityCheckKind"
1098
+ },
1099
+ {
1100
+ "type": "null"
1101
+ }
1102
+ ]
1099
1103
  }
1100
1104
  },
1105
+ "required": [
1106
+ "qualityCheckKind"
1107
+ ],
1101
1108
  "additionalProperties": false
1102
1109
  }
1103
1110
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "spec-controller",
3
- "version": "0.1.231",
3
+ "version": "0.1.233",
4
4
  "description": "Reconcile the behaviour your scenarios name against the evidence that actually ran — the deterministic `balance` CLI.",
5
5
  "keywords": [
6
6
  "reconciliation",
@@ -26,7 +26,7 @@
26
26
  "fast-xml-parser": "^5.11.2",
27
27
  "ts-json-schema-generator": "^2.9.0",
28
28
  "yaml": "^2.9.0",
29
- "@3f-consulting/spec-controller-core": "0.1.231"
29
+ "@3f-consulting/spec-controller-core": "0.1.233"
30
30
  },
31
31
  "publishConfig": {
32
32
  "access": "public"