Skip to content

refactor: organize mapper tests by language and enforce typed fixtures - #205

Merged
steipete merged 1 commit into
mainfrom
refactor/phase-five-tests
Sep 12, 2026
Merged

refactor: organize mapper tests by language and enforce typed fixtures#205
steipete merged 1 commit into
mainfrom
refactor/phase-five-tests

Conversation

@steipete

Copy link
Copy Markdown
Contributor

What Problem This Solves

A single 17,410-line mapper test file mixed 434 cases from unrelated languages and frameworks, making focused runs and maintenance difficult. Retry tests bypassed the real provider contract with any, and fixture directories remained after tests.

User Impact

No CLI behavior changes. Contributors can run the relevant language's tests directly; test fixtures clean up after each case, and TypeScript catches unused locals and parameters.

Why This Change Was Made

Move the existing mapper cases beside their language modules, retaining cross-mapper coverage in mapper.test.ts. Preserve every mapper test body and existing platform gate. Use complete typed provider fixtures and remove the two unused parameters found by the compiler before enabling its unused-code checks.

Evidence

  • pnpm typecheck, pnpm lint, pnpm format:check, pnpm test, and pnpm build passed. The same 941 tests pass with the same 2 platform skips, now across 48 files.
  • A post-format SHA256/multiset check confirms all 434 original mapper test bodies are byte-for-byte preserved.
  • Isolated Codex autoreview completed all four evidence partitions: scoped-clean at P0–P2.
  • Live package proof: pnpm pack:smoke built the tarball, installed it with production dependencies offline, and ran the installed CLI: packaged CLI smoke mapped 13 features (3 CUDA).
  • Local full-suite duration was 43.78 s versus 29.18 s for the initial baseline on this shared machine; no speedup claim is made. The benefit is focused language runs and automatic fixture cleanup.

@steipete
steipete requested a review from a team as a code owner September 12, 2026 23:01
@clawsweeper

clawsweeper Bot commented Sep 12, 2026

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

@steipete
steipete merged commit 6750f2c into main Sep 12, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant