feat(review): reuse review.instructions/pathInstructions for E2E test generation - #4208
Merged
Merged
Conversation
… generation Adds resolveE2eTestGenInstructions, combining a repo's existing review.instructions (repo-wide brief) with any review.pathInstructions entries matching the PR's changed files into one instructions block for AI-generated E2E test coverage (#4189 epic). Reuses the config-as-code mechanism already parsed and already feeding the AI reviewer end to end (resolveReviewPathInstructions), rather than inventing a second, e2e-test-gen-specific instructions schema: a maintainer's repo conventions and path-scoped rules apply equally well to steering an AI reviewer or an AI test generator, so both draw from the same maintainer-authored brief written once. Closes #4200.
Contributor
|
Superagent didn't find any vulnerabilities or security issues in this PR. |
Deploying with
|
| Status | Name | Latest Commit | Preview URL | Updated (UTC) |
|---|---|---|---|---|
| ✅ Deployment successful! View logs |
gittensory-ui | 5452058 | Commit Preview URL Branch Preview URL |
Jul 08 2026, 12:11 PM |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #4208 +/- ##
=======================================
Coverage 93.75% 93.75%
=======================================
Files 389 389
Lines 36495 36499 +4
Branches 13373 13376 +3
=======================================
+ Hits 34217 34221 +4
Misses 1621 1621
Partials 657 657
🚀 New features to boost your workflow:
|
12 tasks
This was referenced Jul 10, 2026
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.
Summary
#4200's original ask (a dedicatedreview.e2eTestGeneration.instructions/pathInstructionsconfig block, CodeRabbit-path_instructions-style) against the current codebase, and found the codebase already has a fully general-purpose, working mechanism for exactly this:review.instructions(repo-wide brief) andreview.pathInstructions({path, instructions}[]), already parsed, validated, and fed into the AI reviewer's prompt today (resolveReviewPathInstructionsinsrc/signals/focus-manifest.ts).resolveE2eTestGenInstructions— a small pure function that combines the SAME existingreview.instructions+ matchingreview.pathInstructionsentries into one instructions block forE2eTestGenInput.instructions(the field feat(review): LLM core to turn a PR diff into Playwright E2E test source #4191/PR feat(review): LLM core to turn a PR diff into Playwright E2E test source #4207 already built and wired to accept).src/checkout/**") apply equally well to steering an AI reviewer or an AI test generator, so both now draw from the same maintainer-authored brief, written once.pathInstructions/instructions(engine package + both public/self-host.gittensory.ymlexamples) to note this second consumer, so a maintainer reading the existing docs knows their instructions now also steer test generation once that feature is enabled.Closes #4200.
Scope
type(scope): short summaryConventional Commit format.CONTRIBUTING.mdand does not reintroduce GitHub Pages, VitePress,site/, orCNAME.Validation
git diff --checknpm run typechecknpm run test:coverage(targeted at the changed files + the config-example drift tests) — 100% statements/branches/functions/lines on the changed portion ofsrc/services/ai-e2e-test-gen.ts(82/82 stmts, 76/76 branches, 9/9 funcs, 71/71 lines, confirmed via--coverage.include);test/unit/config-templates.test.ts(verifies.gittensory.yml.example↔config/examples/gittensory.full.ymlbyte-for-byte parity) andtest/unit/focus-manifest.test.tsboth still pass, confirming the doc updates didn't break the existing mirror check.npm run docs:drift-check— clean, no new env vars introduced.npm audit --audit-level=moderate— N/A, no dependency changes (not re-run this PR; nothing inpackage.json/lockfiles touched).Safety
parsePublicSafeText-validated fields verbatim; no new text-handling path).UI Evidencesection — N/A, no UI changes..gittensory.ymlexamples updated to note the new consumer);CHANGELOG.mditself is untouched.Notes
@gittensory generate-testscommand) actually callsrunGittensoryE2eTestGenerationwith a resolvedinstructionsvalue.