Repository navigation
Closed
Labels
effort/mediumEffort Mediumpriority/p3-lowPriority P3: a small improvementsource/agentFiled by an agenttype/testType test: a new or changed testvalue/mediumValue Medium
Description
Problem or Motivation
- 41 cases of
test_request_plan_flag_order_global_dry_runrepeat the local case of each command, and only generic resolver lines differ (67.4 s in a local full run with per-test coverage contexts). - 15 'removed from gaps' tests repeat the ratchet invariant (0.8 s).
- 11 dry-run files repeat a subprocess block that the session floor already applies (
tests/conftest.py:444). - The dry-run test family has 3.70% duplicate lines (pylint symilar,
-d 8).
Saving: About 19 s of CI worker time (estimated) and less test code.
Found by the CI and test audit of 2026-11-11. The account runs at most 20 hosted jobs at one time (measured), so each job that does no work makes the queue of each pull request longer.
Proposed Solution & Architectural Design
- In
tests/commands/test_global_dry_run.py, test the root--dry-runthrough the resolver on a table of argv shapes: options with values, positionals and--. Drop the per-command twins. - Delete the gaps tests whose list equals their class table, and keep the review prefix rule.
- Make one
tests/supportfixture for the network block of dry runs only, and delete the subprocess blocks.
Risk: Medium. The per-command case was the only check that the resolver walks the argv of each command.
Target Subsystem
SDLC, Git & PR Governance (tests/commands/test_global_dry_run.py, tests/commands/test_ai_*_dry_run.py, tests/support/).
Existing Tool Considered
pytest parametrize. pylint symilar measures the duplicate share. No new tool. Cost: about 40,000 tokens and 3 hours.
Acceptance Criteria
- The twin cases are gone, and the resolver table covers the given argv shapes.
- The share of duplicate lines in the dry-run test family (pylint symilar,
-d 8) is 1% or less (from 3.70%).
Dependencies
None.
Metadata
Metadata
Assignees
Labels
effort/mediumEffort Mediumpriority/p3-lowPriority P3: a small improvementsource/agentFiled by an agenttype/testType test: a new or changed testvalue/mediumValue Medium
Activity
dan-petty commentedon Nov 11, 2026
Intake placed this item to the backlog: intake puts every new item in the backlog. A person plans the milestones.
testprefix of the title gives the type.dry-run, and .github/labels.yml declares no scope/dry-run label. Add the label to the file to give the scope to this item.Saves about 19 s of CI time and reduces test code, but no user-facing behaviour changes.Reduces CI queue wait and maintenance burden for the dry-run test family.Requires rewriting 41 twin cases into a parametrized table, deleting 15 ratchet tests, and adding one shared fixture across 11 files.Both concern the dry-run ratchet invariant, but #2230 adds the ratchet mechanism while the candidate removes 15 redundant tests that repeat it.