forked from farhoodlabs/paperclip
bf251188df
Closes the coverage gap on the actual migrated function. Mocks the
two network-touching git-source exports (resolveGitRef, openRepoSnapshot)
while keeping parseGitSourceUrl real so the parseGitHubSourceUrl shim
contract stays honest. Adds 5 cases:
- happy path: opens one snapshot, calls listFiles, readFileOptional
on COMPANY.md, readFile on candidate paths
- ref fallback: when openRepoSnapshot('main') rejects, falls back to
'master' and emits the expected warning
- COMPANY.md absent everywhere: throws "missing COMPANY.md"
- referenced logo: readBinary is called for the logoPath from
.paperclip.yaml
- logo read failure: warning emitted, no throw
57/57 portability tests passing; existing 52 unchanged via shim.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>