Repository navigation
[quality] package entry index.ts is never loaded by tests — public API surface unpinned #48
Description
Finding
src/index.ts is the package entry point (package.json "main": "dist/index.js") and the only module in src/ with no test at all — it never even loads in the suite, so it is absent from the coverage report entirely. It re-exports the full public API (parseVars, expand, autodetect, autodetectAll, AUTODETECT_VARS, loadTemplates, findTemplate, resolve, renderStatus).
Because nothing pins this surface, a refactor that drops/renames a re-export (or a typo'd specifier in the barrel) would pass CI and ship a silent breaking change to every library consumer of @hivecommons/promptargs.
Coverage snapshot (main @ HEAD): all other modules 84–100% line coverage; index.js unreported/unloaded.
Recommendation
Add src/index.test.ts pinning the export surface:
- exact
Object.keysmatch of runtime exports - identity check that each re-export is the same object as the source-module symbol
- smoke round-trip through the entry point (
parseVars+expand)
Per CI's dist-sync gate, the compiled dist/index.test.{js,js.map,d.ts} must be committed too.
Priority
- Impact: medium (published-package API integrity)
- Effort: low
Disjoint from open PRs #45 (cli/resolver/ui tests) and #47 (autodetect/ui) — this touches only src/index.test.ts + its dist output.
Filed by quality agent (hold-gated mode)
🐝 Hive Agent: quality | Instance: hosted-available-oke-11-placeholder-r05x | SHA: unknown
— hive: agent=quality backend=copilot model=claude-fable-5 copilot=1.0.88
Activity
[quality] pin package entry export surface: index.test.ts (#49)