Skip to content

Commit f087b77

Browse files
authored
chore(review): remove never-wired test-generation dead slice (#4108) (#4126)
GITTENSORY_REVIEW_TEST_GENERATION, the review.testGeneration manifest field, and their resolver/gate functions (resolveTestGenerationManifestToggle, isTestGenerationEnabled, shouldOfferTestGenerationSpec) had zero callers anywhere in the review pipeline -- the spec-attachment slice that was supposed to consume them was never built. Removes the whole orphaned surface plus its test file and the stale doc mentions in the example configs and docs pages. The live, ungated MCP test-generation tools (gittensory_generate_tests, boundary-test-generation) are untouched.
1 parent 6cbd0e8 commit f087b77

14 files changed

Lines changed: 9 additions & 173 deletions

.gittensory.yml.example

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -484,15 +484,6 @@ review:
484484
# (CI green, gate passing, mergeable-clean, valid linked issue). SURFACE ONLY — never changes the decision.
485485
# auto_merge_summary: false
486486

487-
# Boundary-safe test-generation advisory (#1972, kill-switch config slice #2189). Bool | null. Default:
488-
# null/false — byte-identical (no boundary scan runs at all). Requires the operator's
489-
# GITTENSORY_REVIEW_TEST_GENERATION flag to be on AND this toggle. When both are on, a diff that touches a
490-
# small, precise set of boundary-condition patterns (off-by-one array/index bounds, null/undefined branches,
491-
# empty-collection checks) with NO test evidence anywhere in the PR gets an advisory finding plus a
492-
# LOCAL-execution test-generation action spec (criteria/hints for your OWN agent to scaffold tests with —
493-
# gittensory never writes or runs test code).
494-
# test_generation: false
495-
496487
# Deterministic label suggestions (#2045). Each rule SUGGESTS a non-scoring label when a PR matches ALL of the
497488
# `when` criteria it sets (at least one is required): when_paths (any changed path matches a glob), title_contains,
498489
# description_contains (both case-insensitive). Suggestions are advisory; they are auto-applied only when the repo's
@@ -913,12 +904,6 @@ settings:
913904
# # fallback for whatever it omits. Only takes effect when inline_comments is already on. Bool or null.
914905
# # Default: null/false.
915906
# finding_categories: false
916-
# # When true, a diff touching a small, precise set of boundary-condition patterns (off-by-one array/index
917-
# # bounds, null/undefined branches, empty-collection checks) with no test evidence in the PR gets an
918-
# # advisory finding plus a LOCAL-execution test-generation action spec (criteria/hints only -- never
919-
# # generated test code; your own agent scaffolds it). Also requires the operator flag
920-
# # GITTENSORY_REVIEW_TEST_GENERATION. Bool or null. Default: null/false (byte-identical).
921-
# test_generation: false
922907
# # How strictly a linked issue must actually be SATISFIED by the PR (distinct from linkedIssuePolicy,
923908
# # which only checks a link EXISTS). off = not evaluated; advisory = surface a finding; block = can
924909
# # become a hard blocker (confirmed-contributor-gated). This is the config knob only — parsed and

apps/gittensory-ui/src/routes/docs.privacy-security.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,6 @@ GITTENSORY_REVIEW_REPUTATION="true" # submitter-reputation spend co
9292
GITTENSORY_REVIEW_UNIFIED_COMMENT="true" # one in-place unified PR comment
9393
GITTENSORY_REVIEW_ENRICHMENT="true" # external analyzer registry (REES) findings
9494
GITTENSORY_REVIEW_INLINE_COMMENTS="true" # diff-anchored inline PR review comments
95-
GITTENSORY_REVIEW_TEST_GENERATION="true" # boundary-safe test-gen action spec (contributor-run)
9695
GITTENSORY_REVIEW_FIX_HANDOFF="true" # machine-readable fix-handoff block (contributor-run)
9796
GITTENSORY_REVIEW_PLANNER="true" # @gittensory plan on-demand implementation plan
9897
GITTENSORY_REVIEW_SCREENSHOTS="true" # before/after visual capture for UI changes

apps/gittensory-ui/src/routes/docs.tuning.tsx

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -183,12 +183,6 @@ function Tuning() {
183183
<code>GITTENSORY_REVIEW_INLINE_COMMENTS</code> — posts AI-review findings as inline
184184
diff-anchored PR review comments instead of (or alongside) the summary comment. Per-PR.
185185
</li>
186-
<li>
187-
<code>GITTENSORY_REVIEW_TEST_GENERATION</code> — offers a boundary-safe local-write action
188-
spec alongside a missing-test-evidence finding, describing what test cases should exist
189-
for the repo's detected framework; the contributor's own agent scaffolds and runs the
190-
tests locally. Per-PR.
191-
</li>
192186
<li>
193187
<code>GITTENSORY_REVIEW_FIX_HANDOFF</code> — renders a review finding as a structured,
194188
machine-readable "apply this fix" block for the contributor's own local agent to consume —

config/examples/gittensory.full.yml

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -497,15 +497,6 @@ review:
497497
# (CI green, gate passing, mergeable-clean, valid linked issue). SURFACE ONLY — never changes the decision.
498498
# auto_merge_summary: false
499499

500-
# Boundary-safe test-generation advisory (#1972, kill-switch config slice #2189). Bool | null. Default:
501-
# null/false — byte-identical (no boundary scan runs at all). Requires the operator's
502-
# GITTENSORY_REVIEW_TEST_GENERATION flag to be on AND this toggle. When both are on, a diff that touches a
503-
# small, precise set of boundary-condition patterns (off-by-one array/index bounds, null/undefined branches,
504-
# empty-collection checks) with NO test evidence anywhere in the PR gets an advisory finding plus a
505-
# LOCAL-execution test-generation action spec (criteria/hints for your OWN agent to scaffold tests with —
506-
# gittensory never writes or runs test code).
507-
# test_generation: false
508-
509500
# Deterministic label suggestions (#2045). Each rule SUGGESTS a non-scoring label when a PR matches ALL of the
510501
# `when` criteria it sets (at least one is required): when_paths (any changed path matches a glob), title_contains,
511502
# description_contains (both case-insensitive). Suggestions are advisory; they are auto-applied only when the repo's
@@ -926,12 +917,6 @@ settings:
926917
# # fallback for whatever it omits. Only takes effect when inline_comments is already on. Bool or null.
927918
# # Default: null/false.
928919
# finding_categories: false
929-
# # When true, a diff touching a small, precise set of boundary-condition patterns (off-by-one array/index
930-
# # bounds, null/undefined branches, empty-collection checks) with no test evidence in the PR gets an
931-
# # advisory finding plus a LOCAL-execution test-generation action spec (criteria/hints only -- never
932-
# # generated test code; your own agent scaffolds it). Also requires the operator flag
933-
# # GITTENSORY_REVIEW_TEST_GENERATION. Bool or null. Default: null/false (byte-identical).
934-
# test_generation: false
935920
# # How strictly a linked issue must actually be SATISFIED by the PR (distinct from linkedIssuePolicy,
936921
# # which only checks a link EXISTS). off = not evaluated; advisory = surface a finding; block = can
937922
# # become a hard blocker (confirmed-contributor-gated). This is the config knob only — parsed and

packages/gittensory-engine/src/focus-manifest.ts

Lines changed: 3 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -430,17 +430,6 @@ export type FocusManifestReviewConfig = {
430430
* source, same display-only (never touches the AI prompt) shape. null/false (default, absent) = no chip =
431431
* byte-identical behavior. (#1955) */
432432
effortScore: boolean | null;
433-
/** `review.test_generation` (#1972, kill-switch config slice #2189): when true, a diff that touches a small,
434-
* precise set of boundary-condition patterns (off-by-one array/index bounds, null/undefined branches,
435-
* empty-collection checks — see `src/signals/boundary-test-generation.ts`) with NO test evidence anywhere in
436-
* the PR gets an additional advisory finding plus a boundary-safe LOCAL-execution
437-
* `gittensory_generate_tests` action spec (criteria/hints only, never generated test code — see
438-
* `src/mcp/local-write-tools.ts`'s `buildTestGenSpec`). Also gated by the operator's
439-
* `GITTENSORY_REVIEW_TEST_GENERATION` kill-switch (`src/review/test-generation.ts`'s
440-
* `isTestGenerationEnabled`) — the caller ANDs both. Purely additive and deterministic; it never changes what
441-
* `missingTestEvidence` already does. null/false (default, absent) ⇒ byte-identical behavior — no boundary
442-
* scan runs and no spec is ever built. */
443-
testGeneration: boolean | null;
444433
/** `review.impact_map` (#2184, config slice of #1971): when true, gates BOTH the deterministic impact-map
445434
* computation (`computeImpactMap`, `src/review/impact-map.ts`) and its rendering as a compact section in
446435
* the unified review comment (#2185) / additive AI-review grounding context (#2186). Deterministic/display
@@ -887,7 +876,7 @@ const EMPTY_MANIFEST: FocusManifest = {
887876
publicNotes: [],
888877
gate: { ...EMPTY_GATE_CONFIG },
889878
settings: {},
890-
review: { present: false, footerText: null, note: null, fields: {}, enrichmentAnalyzers: {}, profile: null, tone: null, securityFocus: null, inlineComments: null, fixHandoff: null, autoMergeSummary: null, suggestions: null, changedFilesSummary: null, effortScore: null, testGeneration: null, impactMap: null, cultureProfile: null, selftune: null, reviewMemory: null, findingCategories: null, inlineCommentsPerCategory: null, minFindingSeverity: null, maxFindings: { ...EMPTY_MAX_FINDINGS_CONFIG }, commentVerbosity: null, pathInstructions: [], instructions: null, excludePaths: [], pathFilters: [], preMergeChecks: [], autoReview: { ...EMPTY_AUTO_REVIEW_CONFIG }, labelingRules: [], aiModel: { ...EMPTY_SELF_HOST_AI_MODEL_CONFIG }, visual: { ...EMPTY_VISUAL_CONFIG }, linkedIssueSatisfaction: null, sharedConfigSource: null },
879+
review: { present: false, footerText: null, note: null, fields: {}, enrichmentAnalyzers: {}, profile: null, tone: null, securityFocus: null, inlineComments: null, fixHandoff: null, autoMergeSummary: null, suggestions: null, changedFilesSummary: null, effortScore: null, impactMap: null, cultureProfile: null, selftune: null, reviewMemory: null, findingCategories: null, inlineCommentsPerCategory: null, minFindingSeverity: null, maxFindings: { ...EMPTY_MAX_FINDINGS_CONFIG }, commentVerbosity: null, pathInstructions: [], instructions: null, excludePaths: [], pathFilters: [], preMergeChecks: [], autoReview: { ...EMPTY_AUTO_REVIEW_CONFIG }, labelingRules: [], aiModel: { ...EMPTY_SELF_HOST_AI_MODEL_CONFIG }, visual: { ...EMPTY_VISUAL_CONFIG }, linkedIssueSatisfaction: null, sharedConfigSource: null },
891880
features: { ...EMPTY_FEATURES_CONFIG },
892881
contentLane: { ...EMPTY_CONTENT_LANE_CONFIG },
893882
repoDocGeneration: { ...EMPTY_REPO_DOC_GENERATION_CONFIG },
@@ -917,7 +906,7 @@ function emptyManifest(source: FocusManifestSource, warnings: string[] = []): Fo
917906
warnings,
918907
gate: { ...EMPTY_GATE_CONFIG },
919908
settings: {},
920-
review: { present: false, footerText: null, note: null, fields: {}, enrichmentAnalyzers: {}, profile: null, tone: null, securityFocus: null, inlineComments: null, fixHandoff: null, autoMergeSummary: null, suggestions: null, changedFilesSummary: null, effortScore: null, testGeneration: null, impactMap: null, cultureProfile: null, selftune: null, reviewMemory: null, findingCategories: null, inlineCommentsPerCategory: null, minFindingSeverity: null, maxFindings: { ...EMPTY_MAX_FINDINGS_CONFIG }, commentVerbosity: null, pathInstructions: [], instructions: null, excludePaths: [], pathFilters: [], preMergeChecks: [], autoReview: { ...EMPTY_AUTO_REVIEW_CONFIG }, labelingRules: [], aiModel: { ...EMPTY_SELF_HOST_AI_MODEL_CONFIG }, visual: { ...EMPTY_VISUAL_CONFIG }, linkedIssueSatisfaction: null, sharedConfigSource: null },
909+
review: { present: false, footerText: null, note: null, fields: {}, enrichmentAnalyzers: {}, profile: null, tone: null, securityFocus: null, inlineComments: null, fixHandoff: null, autoMergeSummary: null, suggestions: null, changedFilesSummary: null, effortScore: null, impactMap: null, cultureProfile: null, selftune: null, reviewMemory: null, findingCategories: null, inlineCommentsPerCategory: null, minFindingSeverity: null, maxFindings: { ...EMPTY_MAX_FINDINGS_CONFIG }, commentVerbosity: null, pathInstructions: [], instructions: null, excludePaths: [], pathFilters: [], preMergeChecks: [], autoReview: { ...EMPTY_AUTO_REVIEW_CONFIG }, labelingRules: [], aiModel: { ...EMPTY_SELF_HOST_AI_MODEL_CONFIG }, visual: { ...EMPTY_VISUAL_CONFIG }, linkedIssueSatisfaction: null, sharedConfigSource: null },
921910
features: { ...EMPTY_FEATURES_CONFIG },
922911
contentLane: { ...EMPTY_CONTENT_LANE_CONFIG },
923912
repoDocGeneration: { ...EMPTY_REPO_DOC_GENERATION_CONFIG },
@@ -1921,7 +1910,7 @@ function parsePublicSafeText(value: JsonValue | undefined, field: string, warnin
19211910
* throws; invalid/unsafe values are dropped with warnings.
19221911
*/
19231912
function parseReviewConfig(value: JsonValue | undefined, warnings: string[]): FocusManifestReviewConfig {
1924-
const empty: FocusManifestReviewConfig = { present: false, footerText: null, note: null, fields: {}, enrichmentAnalyzers: {}, profile: null, tone: null, securityFocus: null, inlineComments: null, fixHandoff: null, autoMergeSummary: null, suggestions: null, changedFilesSummary: null, effortScore: null, testGeneration: null, impactMap: null, cultureProfile: null, selftune: null, reviewMemory: null, findingCategories: null, inlineCommentsPerCategory: null, minFindingSeverity: null, maxFindings: { ...EMPTY_MAX_FINDINGS_CONFIG }, commentVerbosity: null, pathInstructions: [], instructions: null, excludePaths: [], pathFilters: [], preMergeChecks: [], autoReview: { ...EMPTY_AUTO_REVIEW_CONFIG }, labelingRules: [], aiModel: { ...EMPTY_SELF_HOST_AI_MODEL_CONFIG }, visual: { ...EMPTY_VISUAL_CONFIG }, linkedIssueSatisfaction: null, sharedConfigSource: null };
1913+
const empty: FocusManifestReviewConfig = { present: false, footerText: null, note: null, fields: {}, enrichmentAnalyzers: {}, profile: null, tone: null, securityFocus: null, inlineComments: null, fixHandoff: null, autoMergeSummary: null, suggestions: null, changedFilesSummary: null, effortScore: null, impactMap: null, cultureProfile: null, selftune: null, reviewMemory: null, findingCategories: null, inlineCommentsPerCategory: null, minFindingSeverity: null, maxFindings: { ...EMPTY_MAX_FINDINGS_CONFIG }, commentVerbosity: null, pathInstructions: [], instructions: null, excludePaths: [], pathFilters: [], preMergeChecks: [], autoReview: { ...EMPTY_AUTO_REVIEW_CONFIG }, labelingRules: [], aiModel: { ...EMPTY_SELF_HOST_AI_MODEL_CONFIG }, visual: { ...EMPTY_VISUAL_CONFIG }, linkedIssueSatisfaction: null, sharedConfigSource: null };
19251914
if (value === undefined || value === null) return empty;
19261915
if (typeof value !== "object" || Array.isArray(value)) {
19271916
warnings.push(`Manifest field "review" must be a mapping; ignoring it.`);
@@ -1963,7 +1952,6 @@ function parseReviewConfig(value: JsonValue | undefined, warnings: string[]): Fo
19631952
const suggestions = normalizeOptionalBoolean(r.suggestions, "review.suggestions", warnings);
19641953
const changedFilesSummary = normalizeOptionalBoolean(r.changed_files_summary, "review.changed_files_summary", warnings);
19651954
const effortScore = normalizeOptionalBoolean(r.effort_score, "review.effort_score", warnings);
1966-
const testGeneration = normalizeOptionalBoolean(r.test_generation, "review.test_generation", warnings);
19671955
const impactMap = normalizeOptionalBoolean(r.impact_map, "review.impact_map", warnings);
19681956
const cultureProfile = normalizeOptionalBoolean(r.culture_profile, "review.culture_profile", warnings);
19691957
const selftune = normalizeOptionalBoolean(r.selftune, "review.selftune", warnings);
@@ -2005,7 +1993,6 @@ function parseReviewConfig(value: JsonValue | undefined, warnings: string[]): Fo
20051993
suggestions !== null ||
20061994
changedFilesSummary !== null ||
20071995
effortScore !== null ||
2008-
testGeneration !== null ||
20091996
impactMap !== null ||
20101997
cultureProfile !== null ||
20111998
selftune !== null ||
@@ -2034,7 +2021,6 @@ function parseReviewConfig(value: JsonValue | undefined, warnings: string[]): Fo
20342021
aiModel,
20352022
visual,
20362023
linkedIssueSatisfaction,
2037-
testGeneration,
20382024
enrichmentAnalyzers,
20392025
profile,
20402026
tone,
@@ -2139,7 +2125,6 @@ function computeReviewConfigPresent(review: Omit<FocusManifestReviewConfig, "pre
21392125
review.suggestions !== null ||
21402126
review.changedFilesSummary !== null ||
21412127
review.effortScore !== null ||
2142-
review.testGeneration !== null ||
21432128
review.impactMap !== null ||
21442129
review.cultureProfile !== null ||
21452130
review.selftune !== null ||
@@ -2184,7 +2169,6 @@ export function overlayReviewConfig(
21842169
suggestions: pickOverlayNullable(override.suggestions, base.suggestions),
21852170
changedFilesSummary: pickOverlayNullable(override.changedFilesSummary, base.changedFilesSummary),
21862171
effortScore: pickOverlayNullable(override.effortScore, base.effortScore),
2187-
testGeneration: pickOverlayNullable(override.testGeneration, base.testGeneration),
21882172
impactMap: pickOverlayNullable(override.impactMap, base.impactMap),
21892173
cultureProfile: pickOverlayNullable(override.cultureProfile, base.cultureProfile),
21902174
selftune: pickOverlayNullable(override.selftune, base.selftune),
@@ -2674,7 +2658,6 @@ export function reviewConfigToJson(review: FocusManifestReviewConfig): JsonValue
26742658
if (review.suggestions !== null) out.suggestions = review.suggestions;
26752659
if (review.changedFilesSummary !== null) out.changed_files_summary = review.changedFilesSummary;
26762660
if (review.effortScore !== null) out.effort_score = review.effortScore;
2677-
if (review.testGeneration !== null) out.test_generation = review.testGeneration;
26782661
if (review.impactMap !== null) out.impact_map = review.impactMap;
26792662
if (review.cultureProfile !== null) out.culture_profile = review.cultureProfile;
26802663
if (review.selftune !== null) out.selftune = review.selftune;

src/env.d.ts

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -192,12 +192,6 @@ declare global {
192192
* inline comments on specific changed lines, layered on top of the decision summary. Default OFF —
193193
* unset/false keeps the review path byte-identical (the model is never asked for inline findings). */
194194
GITTENSORY_REVIEW_INLINE_COMMENTS?: string;
195-
/** Boundary-safe test generation (#2189, config slice of #1972): when truthy (AND the repo's `.gittensory.yml`
196-
* sets `review.test_generation: true`), a missing-test-evidence finding is ALSO accompanied by a
197-
* `gittensory_generate_tests` local-write action spec — criteria/content supplied by gittensory, execution
198-
* on the contributor's own machine (no source upload, no server-side write). Default OFF — unset/false
199-
* keeps the review path byte-identical (no spec is ever built). */
200-
GITTENSORY_REVIEW_TEST_GENERATION?: string;
201195
/** Fix-handoff blocks (#2176, config slice of #1962): when truthy (AND the repo is in GITTENSORY_REVIEW_REPOS
202196
* AND the repo's `.gittensory.yml` sets `review.fixHandoff: true`), a review finding is ALSO rendered as a
203197
* structured, machine-readable "apply this fix" block (src/review/fix-handoff-render.ts) for the

src/review/test-generation.ts

Lines changed: 0 additions & 25 deletions
This file was deleted.

0 commit comments

Comments
 (0)