fix: pre-landing review fixes (CEO bullet bounds code by accepted scope; tests bind each completeness rule)

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
This commit is contained in:
garrytanandcapy-ai[bot] committed 2026-10-26 01:43:58 +00:00
1 parent 53545c6165
commit b8fd285002
5 files changed
+15 -6

No files matched your search

+9 -1
View File
@@ -2,7 +2,7 @@ import { describe, expect, test } from 'bun:test';
import { readFileSync } from 'node:fs';
import { resolve } from 'node:path';
import { readWorkflowJudgeInput } from './helpers/workflow-judge-input';
import { expectMentions } from './helpers/prompt-structure';
import { expectAbsent, expectMentions } from './helpers/prompt-structure';
const root = resolve(import.meta.dir, '..');
const compact = (text: string) => text.replace(/\s+/g, ' ').trim();
@@ -93,3 +93,11 @@ for (const source of sources) describe(`CEO clarity routing — ${source.label}`
expectMentions(opening, [['do not', 'another', 'handoff']], 'opening');
});
});
describe('CEO completeness posture', () => {
test('the Philosophy bullet measures completeness in coverage, not code', () => {
const philosophy = readFileSync(resolve(root, 'plan-ceo-review/SKILL.md.tmpl'), 'utf8').split('## Philosophy')[1]!.split('## Prime Directives')[0]!;
expectMentions(philosophy, [['whole requirement', '90% shortcut', 'no code beyond', 'equal coverage', 'smaller diff']], 'philosophy');
expectAbsent(philosophy, ['COMPLETENESS IS CHEAP', '~150 LOC'], 'philosophy');
});
});
+1 -1
View File
@@ -122,7 +122,7 @@ describe('GPT-5.6 Sol model profile', () => {
expect(generic).toContain('make your best judgment and proceed');
expect(completeness).toContain('Complete coverage, minimal code.');
expect(completeness).toContain('prefer the smaller diff');
expectMentions(completeness, [['full coverage', 'requirement', 'error paths'], ['equal coverage', 'smaller diff'], ['impossible states'], ['never', 'gap']], 'default completeness section');
expectMentions(completeness, [['full coverage', 'requirement', 'error paths', 'no code beyond'], ['equal coverage', 'smaller diff'], ['no checks', 'impossible states'], ['unrelated', 'separate scope', 'never', 'gap']], 'default completeness section');
});
test('terse mode still suppresses the completeness section for Sol', () => {