Context: prpack has no automated tests. The CLI has been manually verified on real repos, but a basic smoke test would catch regressions in output structure.
Goal: add a tiny test that:
- Creates a temp directory with a 2-commit git repo (2 files, one renamed, one modified)
- Runs `node bin/prpack.js --base HEAD~1 --head HEAD --out /out.md --quiet`
- Asserts the output contains:
- The string `# Pull Request Context`
- The string `## Commits`
- The string `## Files changed`
- One `### Diff` block per modified file
- One `### Full content (post-change)` block per modified file
Plain Node assertions are fine — no test framework needed (zero-deps philosophy).
Wiring: add a `test` script to package.json and a `.github/workflows/test.yml` that runs it on push.
Acceptance: test passes locally and in CI.
Context: prpack has no automated tests. The CLI has been manually verified on real repos, but a basic smoke test would catch regressions in output structure.
Goal: add a tiny test that:
Plain Node assertions are fine — no test framework needed (zero-deps philosophy).
Wiring: add a `test` script to package.json and a `.github/workflows/test.yml` that runs it on push.
Acceptance: test passes locally and in CI.