test: coverage-driven hardening pass — detector matrix, unit tests, node/python parity gate#9
Merged
Merged
Conversation
…ode/python parity gate Grows the smoke suite from 246 to 327 checks and lifts measured Node installer coverage from 78.6% to 85.8% lines (66.6% to 76.4% branches): - table-driven orient detector tests for every supported stack (Gradle, Go, Rust, Ruby, PHP, CMake, Makefile fallback + suppression, pip, yarn/bun/Pipenv locks, Turborepo, build-script-less and malformed package.json, empty repo, multi-stack note), flag overrides, and README description-extraction edge cases — orient.mjs is now at 100% lines - per-ecosystem indepth dependency-parsing tests (pip, Poetry, Go, Cargo, Bundler, Composer) and a real-git-repo fixture for the git-history analyzer, both runtimes - unit tests for classifyAction pinning the full re-run matrix, including the kit-upgrade "update" outcome that end-to-end tests cannot reach, and for the intake wizard's detectBranch (exported for testing) - verify edge cases (no docs, duplicate basenames) and CLI surface checks - a node<->python parity test: both installers must write identical orient profiles (minus timestamp) for the same fixture - npm run coverage (c8 via npx) plus a CI coverage job enforcing a floor Fixes the one divergence the parity test caught: lib/orient.py recorded fork evidence with an ASCII '->' where the Node installer writes '→'. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01483R5qNvQeZ78kE52kGLHy
PRs #5-#7 changed '/', 'templates/', and 'docs/' after the previous baseline (ba964e9) without re-anchoring, so 'drift --git --strict' — and with it the ai-check workflow on main — has been failing with 3 stale findings ever since. Point the baseline at the human-merged main tip 1fd11db; verified locally that the check now runs clean (0 stale). The per-row human audit dates in MODULE_MAP.md are untouched and remain the authoritative signatures. Includes the regenerated drift/verification reports. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01483R5qNvQeZ78kE52kGLHy
There was a problem hiding this comment.
Pull request overview
This PR strengthens the project’s installer smoke suite and adds coverage/consistency gates, with the goal of making stack detection and cross-runtime behavior (Node vs Python) harder to regress.
Changes:
- Expands
test/run-tests.mjswith table-drivenorientdetector coverage, per-ecosystemindepthdependency parsing checks,verifyedge cases, git-history fixture coverage, and unit-level pinning forclassifyAction+detectBranch. - Adds a Node coverage entrypoint (
npm run coverage) and a CI coverage-floor job usingc8. - Enforces Node↔Python parity for
orientoutput (minus timestamp) and fixes the one detected divergence in Python fork-evidence formatting.
Reviewed changes
Copilot reviewed 9 out of 9 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| test/run-tests.mjs | Adds bare-fixture helper plus extensive new smoke/unit/parity test coverage across orient, indepth, verify, CLI surface, and git-history analysis. |
| test/README.md | Documents the new npm run coverage workflow and what it measures/enforces. |
| package.json | Adds coverage script running run-tests.mjs under c8 instrumentation. |
| lib/orient.py | Aligns fork evidence string formatting with Node (→) to satisfy parity. |
| lib/intake.mjs | Exports detectBranch (annotated as internal) to enable direct unit testing. |
| CHANGELOG.md | Records the coverage-driven hardening work and the parity-driven fix. |
| ai/guide/MODULE_MAP.md | Updates the “Last verified” baseline metadata text. |
| ai/analysis/audit-reports/DRIFT_REPORT.md | Updates committed drift report content (removes the stale-check note line for this snapshot). |
| .github/workflows/test.yml | Adds a dedicated coverage job enforcing c8 coverage floors for the Node installer. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
kunalsuri
pushed a commit
that referenced
this pull request
Jul 3, 2026
Resolves the conflicts with main's coverage-hardening and workflow-fix merges (#9, #11): - lib/indepth.py, lib/orient.py: modify/delete — deletion stands (their parity fix is moot with the Python runtime gone) - test/run-tests.mjs: adopt main's expanded suite (detector matrix, dependency-parsing and git-history fixtures, classifyAction/detectBranch unit tests, CLI surface checks) and drop the Python installer pass and the Node <-> Python orient-parity gate along with pythonCmd() - test.yml: keep main's coverage job; reword its stale Python comment - CHANGELOG [Unreleased]: retire the parity-test bullet and the Python-only Fixed entry; note the gate was retired with the runtime - MODULE_MAP: templates/claude/ row downgraded to [inferred] (files under it changed vs the re-anchored 1fd11db baseline) for human re-audit - CHECKSUMS.txt and ai/repo-indepth.json regenerated Verified: npm test 190/190; npm run deep-test 5/5; c8 coverage passes the CI floor (85.8 % lines / 76.5 % branches / 96.4 % functions vs 83/73/90). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01WKkjYZLucrVffnG6cDRNmf
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Grows the smoke suite from 246 to 327 checks and lifts measured Node
installer coverage from 78.6% to 85.8% lines (66.6% to 76.4% branches):
Go, Rust, Ruby, PHP, CMake, Makefile fallback + suppression, pip,
yarn/bun/Pipenv locks, Turborepo, build-script-less and malformed
package.json, empty repo, multi-stack note), flag overrides, and README
description-extraction edge cases — orient.mjs is now at 100% lines
Bundler, Composer) and a real-git-repo fixture for the git-history
analyzer, both runtimes
the kit-upgrade "update" outcome that end-to-end tests cannot reach,
and for the intake wizard's detectBranch (exported for testing)
orient profiles (minus timestamp) for the same fixture
Fixes the one divergence the parity test caught: lib/orient.py recorded
fork evidence with an ASCII '->' where the Node installer writes '→'.
Co-Authored-By: Claude Fable 5 noreply@anthropic.com
Claude-Session: https://claude.ai/code/session_01483R5qNvQeZ78kE52kGLHy