Commit 491cadc
test(rest): pay down the one annotation-reachable error of rest.test.ts's four, and measure the other three (#13380)
* test(rest): drop rest.test.ts's unused RouteGroupBuilder import and re-record the ledger
The `@objectstack/rest` test-layer ledger held 4 errors for `src/rest.test.ts`,
fenced until PR #12421 landed. Measured, exactly one of the four is reachable by
an annotation-only repair:
src/rest.test.ts(5,24) TS6133 'RouteGroupBuilder' is declared but its value is never read
src/rest.test.ts(1267,26) TS2345 Buffer<ArrayBuffer> vs exceljs' own module-local Buffer
src/rest.test.ts(2064,7) TS2345 request literal missing IHttpRequest's headers/method/path
src/rest.test.ts(2089,7) TS2345 request literal missing IHttpRequest's headers/method/path
Only the TS6133 is repaired here: the import specifier is unused (one occurrence
in the file, the import itself; `RouteManager` beside it has 13). Removing it
changes no emitted JavaScript.
The other three are stopped and reported, not forced. The two TS2345 request
literals are the same class as the two already out of scope on this card — they
need the fixture's data, not its annotation, and the durable answer is a typed
IHttpRequest builder. The exceljs one is a third-party declaration defect and
its only in-repo answer today is `as any`, which this card forbids.
Ledger regenerated with `pnpm --filter @objectstack/rest gen:test-typecheck-debt`,
never hand-edited: src/rest.test.ts 4 -> 3, both other entries byte-identical, no
number raised, no entry reached zero so none was deleted.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01TvqBFLRzXdSPcbusDoED9k
* test(rest): record in the ledger's authored _note which card holds each remaining entry
The entries left in `@objectstack/rest`'s test-typecheck ledger are not
annotation repairs, and two rounds on this ledger have now each had to
re-measure that fact from scratch before learning it. `_note` is the field
built for exactly this: unlike the generated `_comment`, it is authored,
preserved verbatim, and never written by the generator.
Written as card pointers rather than as readings — no TS codes, no line
numbers, no counts. Those are the parts that go stale, they already live on
the cards and in the PR that measured them, and a pointer expires only when
the card it names closes, by which time the ledger entry is gone too.
Verified rather than assumed, since preservation is the whole premise:
regenerating with `pnpm --filter @objectstack/rest gen:test-typecheck-debt`
leaves the file byte-identical (sha256 c88a74929f880fa55ea838c8ec8b1021ef
559a4ebf88aa0930454c30321a0e33 before and after) — `_note` unchanged, entries
unchanged, `_comment` rewritten identically.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01TvqBFLRzXdSPcbusDoED9k
---------
Co-authored-by: Claude <noreply@anthropic.com>1 parent 4feeadb commit 491cadc
2 files changed
Lines changed: 3 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
| 5 | + | |
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
| 3 | + | |
3 | 4 | | |
4 | 5 | | |
5 | 6 | | |
6 | | - | |
| 7 | + | |
7 | 8 | | |
8 | 9 | | |
0 commit comments