Repository navigation
test(reference): pin excluded package main resolution - #7941
Conversation
[Low impact] The test-only change appears safe to merge. SummaryAdds public CLI regression coverage for package mains omitted from the source inventory.
Review checks: traced the resolver, exclusion rules, CLI fixture, and cleanup helpers. The diff whitespace check passed. Tests were not rerun. Remote supersession could not be checked because GitHub authentication was unavailable. Reviews (1) · Last reviewed commit: "test(reference): pin excluded package ma..." · Reviewed by Greptile |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
Summary
Related to #7291. Add public CLI regression coverage for a declared package main omitted from the source inventory. The runtime fix already exists on main in
838f5f44dand keeps earlier unobserved candidates unresolved; this PR changes tests only.Problem and expected behavior
A declared main hidden by an exclusion must not be treated as absent and replaced with the package's index. The regression covers both a default-excluded directory and a project-excluded file, plus visible-main and genuinely missing-main controls. The existing excluded-manifest control remains covered.
Change and scope
Extend the public reference-source CLI boundary test. This does not change resolver behavior, exclusion policy or file access.
Contract and boundary impact
Expected effects:
Evidence and regression coverage
The test creates synthetic packages and verifies exclusions remain visible, excluded mains resolve as unknown, an observed main remains internal, and a truly absent main falls back to the observed index. It exercises the public compiled CLI. Current-main behavior was observed; the earlier failing revision was not rerun. MCP and real package inventories were not exercised.
Validation performed
npm run test:focused -- tests/boundary/cli/referenceSourceExcludedPackageManifest.test.ts tests/boundary/cli/referenceSourceDirectoryImports.test.ts— 3 tests passed.npm run check:fast— passed.git diff --check— passed.Compatibility, safety, and release
No runtime or schema change. Synthetic local source fixtures only.
Author readiness
Human owner: @morluto
Before merge
type(scope): outcome.