Files
triggerdotdev--trigger.dev/scripts
Dan Sutton a871022b79 test(scripts): tighten mollifier parity script with body assertions (Phase F1)
Adds per-endpoint contract checks beyond the status-only comparison:

- Read endpoints assert response shape (trace.traceId present;
  events/attempts arrays; metadata-get { metadata, metadataType }
  keys; retrieve-v3 carries id + taskIdentifier + status). The result
  endpoint explicitly asserts 404 — its accidental-but-correct
  pre-Phase-A behaviour is now the locked contract.

- Mutation endpoints get a read-back assertion: after PUT metadata,
  re-read and confirm the snapshot reflects the patch. After POST
  tags, retrieve and confirm runTags contains the new tag. Catches
  the case where the API returns 200 but the snapshot didn't actually
  patch.

- Replay asserts the response carries a new run_-prefixed id.

- New listing probe: hits /api/v1/runs and asserts the buffered runId
  is present in the page. Locks in Phase E's listing-merge behaviour.

Script remains backwards-compatible — same exit codes, same env-var
contract. Drift count now reflects shape violations alongside status
divergences.
2026-05-21 08:52:44 +01:00
..
2024-08-23 13:10:15 +01:00