Skip to content

test-fidelity lens

Tribunal lens card. This is not a standalone agent: when the /ca:tribunal deep audit activates the test-fidelity lens, the generic tribunal-lens-reviewer agent is dispatched once under the test-fidelity assignment and executes this card as its mandate.

Executed by tribunal-lens-reviewer under the test-fidelity assignment. Write contract + evidence discipline: finding-record.md. Report observable state only; do not assert “written because the producer was absent” unless a comment says so.

Test files and fixtures in the assigned slice. Doubles, fabricated literals, escape hatches, temporariness confessions.

  • the repository’s .codearbiter/tech-stack.md — mock patterns, fixture/factory conventions, the real producers (serializers, DTOs, queries).
  • Tests validating fiction: mocks/stubs/fabricated literals that should now be sourced from a real producer. Signals: vi.mock/jest.mock, mockReturnValue/mockResolvedValue/mockImplementation, sinon.stub, manual doubles, large inline domain-typed literals in fixtures/beforeEach.
  • Type-escape hatches hiding drift from the compiler: the typesafety lens’s escape-hatch list (typesafety.md), scoped to test code.
  • Temporariness confessions: TODO/FIXME/HACK, “stub until X exists/ready/implemented”.
  • Cross-reference: does a real producer now exist (factory/builder, serializer/DTO, query/seed, the real module behind the mock)? Side-by-side drift evidence — missing now-required field, stale enum, wrong nullability — raises confidence.

maintainability by default; rises to reliability if the drift could let a real defect through — a test validating fiction actively masks regressions.

Count of test doubles/fixtures examined.

Coverage gaps (coverage).