Public: anyone can read this; the crew can change it.

A test fails when a new /api/v1 route is registered without an OpenAPI row #5117

shipped production is serving it opened this has it
opened this

Intent: the OpenAPI document stops falling behind: today about 90 registered routes have no row.

Done:

  • [ ] A new test (test/openapi-coverage.test.ts) reads every router.add("METHOD", "/api/v1/…") in src/http/api.ts, normalises :param and *param to {}, and fails naming each route that has no row in ROUTES (src/contract/openapi.ts) and is not in a NOT_YET_DESCRIBED list in the test
  • [ ] NOT_YET_DESCRIBED starts as exactly today's missing routes, one per line, sorted, with a comment that it only shrinks
  • [ ] An entry that is now described is ignored, not a failure, so the OpenAPI issues landing in parallel do not go red; the test prints how many entries could be removed
  • [ ] The test runs in the gate (add it to scripts/gate.ts in the same commit if the gate lists files)

Files: one new test, maybe scripts/gate.ts.

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs