test(gates): the register test parses ruff's TOML and holds pytest.ini line by line

Round 2 of the E32 review found the key whitelists blind: a line regex saw neither a
[lint.per-file-ignores] table nor a quoted key, and pytest.ini's continuation lines and
key: value form slipped past. Ruff's config is now parsed (smol-toml) and held to its
key paths; pytest.ini to its whole lines; the CI ruff steps to --config backend/ruff.toml,
which is what makes that file the whole configuration.

ESLint: every glob of a block must reach a sample (reactPlugin.ts and devOnlyGuard.ts
rode along unseen), a block's own severity is held to src, a no-restricted-* list is held
to the src block's declaration rather than Feed.tsx's effective config, named global
ignores count, an ignored sample is named, and linterOptions are checked. tsconfig.node
must keep allowJs + checkJs while it lists a .js file; knip's positive glob is pinned.
This commit is contained in:
2026-10-04 04:16:52 +02:00
parent 64e8f1da3d
commit 3f6a9efd57
4 changed files with 141 additions and 71 deletions
+6 -4
View File
@@ -15,10 +15,12 @@ not an oversight; a narrowing missing from here is a test failure.
How the test matches: each narrowing must appear in a table row below as its `code-quoted` id, in a
row whose **Scope** cell names the scope exactly as the test reports it. For ESLint it reads each
scope's effective config through a sample file AND every config block on its own: a block that
targets files no sample reaches fails as an `unsampled block` (add a sample), a rule a block or src
sets weaker than src counts, so does a `no-restricted-*` list that leaves out an entry src has, and
so does an option that lets something through (`allow…`, `ignore…`, `except…`) (E32 review).
scope's effective config through its sample files AND every config block on its own: a block glob
that no sample matches fails as an `unsampled block` (add a sample), a rule a block or src sets
weaker than src counts, so does a `no-restricted-*` list that leaves out an entry the src block
declares, so does an option that lets something through (`allow…`, `ignore…`, `except…`), and so
does any `linterOptions` but an erroring `reportUnusedDisableDirectives` (E32 review). Ruff's TOML
is parsed and held to a whitelist of key paths, pytest.ini to a whitelist of whole lines.
## ESLint (frontend)