Skip to content

consolidation-package test files exceed 300-line/40-line caps (pre-#237, untouched by #276's own cap sweep) #300

Description

@cdeust

Description

Three test files in the mcp_server/handlers/consolidation test family exceed
this repo's local 300-line/file, 40-line/method caps (CLAUDE.md § Code Style).
All three predate PR #277 (fix-consolidation-import-cycle-237) — confirmed by
diffing against origin/main before that PR's rebase — and PR #277's own
issue #276 cap-sweep only touched the four production consolidation files
(candidate_scan.py, drain_operations.py, cycle_orchestration.py,
headless_authoring.py), leaving these three sibling test files untouched:

$ git show origin/main:tests_py/handlers/test_headless_authoring_throttle.py | wc -l
786
$ git show origin/main:tests_py/handlers/test_ble001_sweep_handlers.py | wc -l
475
$ git show origin/main:tests_py/handlers/test_s110_sweep_handlers.py | wc -l
328

Measured against sizecheck.py (file/function line-count per coding-standards.md
§4, tightened to 300/40 by this repo's CLAUDE.md):

FILE OVER CAP: tests_py/handlers/test_ble001_sweep_handlers.py = 470
FILE OVER CAP: tests_py/handlers/test_headless_authoring_throttle.py = 788
FN OVER CAP: tests_py/handlers/test_headless_authoring_throttle.py::test_max_concurrent_pages_respects_cap = 45
FN OVER CAP: tests_py/handlers/test_headless_authoring_throttle.py::test_expired_deadline_skips_remaining = 57
FN OVER CAP: tests_py/handlers/test_headless_authoring_throttle.py::test_usd_cap_stops_further_calls = 44
FN OVER CAP: tests_py/handlers/test_headless_authoring_throttle.py::test_drain_missing_anchors_skips_ungroundable = 49
FN OVER CAP: tests_py/handlers/test_headless_authoring_throttle.py::test_cycle_never_invokes_ungroundable_scopes = 46
FILE OVER CAP: tests_py/handlers/test_s110_sweep_handlers.py = 326

(Line counts on PR #277's rebased head, bc1902c-derived tree — the 8-10 line
diffs PR #277 makes to these three files are mechanical monkeypatch-target
updates from its Move/Extract Function work, not new size growth; the file
totals above are within a couple of lines of the pre-PR origin/main baseline
quoted at the top.)

Why deferred rather than fixed in PR #277

PR #277 is scoped as a rebase-only change (see PR body / task note). Splitting
three files this large (one nearly 800 lines) the same way #276 split the
production siblings is a substantial Extract Function / Move Function exercise
in its own right, mixing an unrelated large refactor into a rebase PR
(coding-standards.md §15.1 — "never mix the enabling refactor and the feature
in one PR", read here as never mixing an unscoped refactor into a mechanical
rebase). Filed per §14.3 rather than silently deferred.

Acceptance criteria

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions