Correct two test headers that described the removed cross-check

This commit is contained in:
Marc-André Bombeck committed 2026-07-19 05:53:05 +02:00
1 parent 4183202ed3
commit f96c18574b
2 files changed
+9 -12

No files matched your search

@@ -19,14 +19,11 @@ import {
* Empty / missing → schema parse fails. The model cannot
* fabricate a recommendation that points at "nothing".
*
* 2. Every recommendation's `metricSource` MUST be backed by an
* entry in `citations[]` (matching `type` + `timeRange`).
* Cross-check enforced by `findUncitedRecommendations` and run
* by the wrapper after schema parse.
*
* 3. Two separate failure modes (missing metricSource vs. missing
* citation) both surface as zod / wrapper errors so the route
* can return 422 in either case.
* Point 2 of the original contract — every recommendation's
* `metricSource` must also appear in `citations[]` — was a cross-check
* run by a wrapper that had no production caller. Both the wrapper and
* the cross-check are gone; what remains here is the schema-level half,
* which is a real definition and is exercised below.
*/
const baseMetricSource = {
@@ -28,10 +28,10 @@ import {
* bundle when present — defence in depth on top of the rec-level
* `referenceId`.
*
* `findRecommendationsMissingRationale()` flags legacy (pre-B5c)
* payloads where the rationale object is absent. Used by the legacy-
* payload migration path so the UI can show a "regenerate for new
* explainability features" CTA without auto-regenerating.
* A companion helper once flagged legacy (pre-B5c) payloads with an
* absent rationale object, for a regenerate CTA. It ran only inside a
* wrapper that had no production caller and has been removed; the
* schema-level requirement asserted below is the live part.
*/
const baseRationale = {