Files
gstack/test/design-primary-action-aj.test.ts
T
Garry TanandOpenAI Codex 9f81911136 v1.86.0.0 feat: route outside reviews by harness (#2850)
* feat: add a restricted and supervised Claude Code runner

Preserve configured authentication and models while enforcing tool access, strict completion JSON, bounded output and process cleanup. Cover argv, failure handling, session metadata and Windows process containment.

* feat: route outside reviews by harness and migrate wrapper installs

Use Claude Code from Codex and Codex from other supported hosts, with shared invocation rendering, positive gate validation and per-phase provenance. Rename /claude to /claude-code, repair managed shared and copied installations safely, and generate native Kiro skills. Add installed-workflow, failure-injection and live cross-harness regression coverage.

* test: recognize CEO mode labels without terminal spacing

The paid workflow rendered SCOPEEXPANSION at option 4, but its driver required a literal space. Match the leading mode title without cursor-spacing artifacts and ignore adjacent preview text. Preserve missing-target failures and downstream posture assertions.

* test: isolate plan-count fixtures before starting review workflows

Seed the complete test plan in a private git repository before launching Claude, so a bare slash command cannot review the live workspace while a delayed fixture message remains queued. Preserve count thresholds, parsers and budgets. Add initial-context and installed-discovery tests, and retain startup/terminal diagnostics on failed evaluations.

* test: stabilize review fixtures and Claude eval startup

Preserve source boundaries in workflow judge inputs, isolate CEO mode plans, and wait for interactive trust input readiness. Keep startup failure evidence and retain existing models, budgets, and assertions.

Co-Authored-By: OpenAI Codex <noreply@openai.com>

* test: classify collapsed review modes and isolate seeded findings

Keep review questions out of the setup count when terminal cursor positioning removes spaces. State existing webhook safeguards so the five-finding control measures its seeded defects without accidental extra security and concurrency gaps. Preserve question bands and the paired control.

Co-Authored-By: OpenAI Codex <noreply@openai.com>

* test: isolate browser daemon state across free shards

Co-Authored-By: OpenAI Codex <noreply@openai.com>

* test: stabilize native review counting and interactive navigation

Co-Authored-By: OpenAI Codex <noreply@openai.com>

* chore: prepare v1.82.0.0 release

Co-Authored-By: OpenAI Codex <noreply@openai.com>

* fix: eliminate browser and process-cleanup test flakes

Pin every CI surface to Bun 1.4.0 to avoid extra-stdio finalizers closing
reused live sockets. Add an isolated GC/listener regression that fails on
Bun 1.3.13, and prevent coordinated rollback to an affected CI runtime.

Check renderer cleanup against the render's own staging directory so
concurrent renders cannot invalidate the assertion. Make the no-pgrep
process-tree walk tolerate disappearing /proc entries, and synchronize
its test fixture through child readiness and pipe EOF instead of sleeps.

Validation: 9,157 passed, 31 skipped, zero failures across 556 files with
retries disabled. Build, all-host generation freshness, and skill checks
passed. All three races have failing-before/passing-after regressions.

* fix: count completed native review questions in evals

* fix: drive review navigation from confirmed native choices

* fix: require complete section-loading eval reports

* test: isolate telemetry HTTP transport from local assertions

* fix: keep review input on the active native question

* test: let tunnel revocation daemon choose an available port

* test: allocate available ports for pairing and watchdog fixtures

* fix: stabilize planning eval navigation and phase reporting

* test: isolate installed runtime paths in planning evals

* test: stabilize review evidence and concurrent refresh fixtures

* fix: resolve design findings before editing the plan

* fix: honor and persist disabled outside plan reviews

* fix: preserve planning decisions and terminal evidence

Load installed host reviews at autoplan phase entry and wait for completed
reviewers and saved artifacts. Reuse approved remedies while preserving
individual finding decisions.

Drive interactive evals from the current terminal viewport, bind native
questions across scrolling, and require complete native report evidence.
Cover captured stale menus, permission lifecycles, setup classification,
and disabled-review tool availability with deterministic regressions.

Advance release metadata and the upgrade migration to the unclaimed
1.83.0.0 slot.

* fix: drive native review questions and preserve current plans

Use the native single-choice keyboard protocol and current terminal viewport,
with per-question navigation inside packets and completed-call coverage.
Keep permissions, multi-select menus, and Submit controls distinct.

Send Autoplan reviewers the amended implementation plan, keep its review record
separate, and supply retained application contracts in the chain fixture.
Clarify individual DevEx decisions and complete CEO fix options; use one active
plan destination for the section-loading report.

* fix: preserve complete plan-review decisions

* fix: recognize native plan dialogs and reviewer controls

* fix: preserve review decisions and phase completion

* fix: recognize completed reviews without losing findings

* fix: preserve review continuity and native eval completion

* test: fix native review completion and eval retry isolation

* test: handle native review menus and complete eval fixtures

* test: fix native review setup, completion, and isolation failures

* test: limit native skill discovery to runtime assets

* fix: bind Autoplan reviews to full ordered phase inputs

* test: fix planning eval routing, counting, and timeout handling

* chore: advance queued release to v1.84.0.0

* fix: preserve complete review inputs and planning decisions

* fix: reconcile review approvals and preserve phase obligations

* fix: preserve review obligations and unblock eval permissions

Carry recorded Autoplan requirements into blind phase inputs, require Eng
review approvals before exit, and exercise combined asynchronous flows in
CEO reviews. Correct native finding and handoff classification and unblock
repeated report edits using scoped request identities.

* fix: retain plan requirements and complete native review dialogs

* fix: complete native review prompts and retain plan references

* fix: preserve review inputs and classify native eval evidence

* fix: check competing completion orders in CEO reviews

* fix: recognize review decisions and require phase methodology

Require the current phase methodology before Autoplan snapshots. Correct
substantive decision, closed handoff, and cache-finding classification, and
honor the recommended implementation approach in native review dialogs.

Add captured-transcript regressions without changing review thresholds,
provider models, retries, or deadlines.

* test: bind native review decisions and close completed handoffs

* fix: complete review dialogs and verify methodology delivery

* fix: preserve review evidence and unblock native eval prompts

* fix: handle native review question completions

* fix: recognize native review narration and controls

* fix: count native review decisions and isolate eval fixtures

* test: verify seeded review coverage and current artifact permissions

* test: isolate model and brain-aware skill renders

* fix: repair native workflow evaluation and clarify review steps

* fix: stabilize workflow eval evidence and review guidance

* test: repair native workflow observation and fixture isolation

* fix: recognize completed workflow evidence and owned skill reads

* test: repair seeded workflow delivery and completion evidence

* test: recognize current review evidence across native forms

* test: handle native review variants and permission redraws

* fix: honor review preferences and recognize native eval evidence

* test: recognize completed review decisions and queued permissions

* test: match current review contracts and partial-line edits

* test: recognize completed workflow evidence and bounded human waits

* fix: preserve review entry gates and native eval interactions

* fix: recognize native workflow evidence and preserve review gates

* test: recognize current review evidence and preconfigure workflow fixtures

* test: recognize completed review findings and scoped artifact permissions

* fix: stabilize native workflow review and permission evidence

* fix: recognize current review evidence and scoped edit confirmations

Clarify Design and engineering review entry instructions and Design scoring.
Recognize required legacy coverage and public Autoplan completion recaps.
Bind the pending Edit confirmation to its exact file, ordered digest, and
one-request approval when a preceding command display remains visible.
Keep reviews within their existing size limits and preserve scope gates
when extracting workflow fixtures from either supported preamble header.

Keep failure outcomes, review thresholds, provider choices, and eval budgets.

* fix: recover review workflow progress and eval evidence

* fix: recognize valid review evidence and scope selection

* test: fix review evidence parsing and repeated artifact prompts

* test: recognize valid review decisions and pending native cards

* fix(plan-eng-review): keep final navigation consistent with approved tasks

* test: recognize valid review evidence and bind legacy diff requests

* fix: stabilize review eval evidence and harness repair guidance

* docs: update project documentation for v1.85.0.0

Co-Authored-By: OpenAI Codex <noreply@openai.com>

* test: fix Windows CI fixtures and credential scan

Rebase captured JSON values and filesystem evidence using the appropriate
path convention. Compile native fake CLIs on Windows and synchronize pipe
holder readiness, with cleanup retained when assertions fail.

Assemble synthetic credential fixtures at runtime so the added-line scan
keeps enforcing the same gate without flagging its own rejection controls.

Discover generated skills directly for the empty-find regression check,
avoiding a recursive scan through saved evaluation artifacts and dependencies.

* fix: preserve source renders on Windows

Compare canonical generator paths using native separators so an output
sidecar pointing at the source cannot overwrite its skill or metadata.
Keep the regression fixture isolated from the real checkout and expose
freshness diagnostics before asserting subprocess status.

Detach Windows drain-test pipe holders from the fake provider's automatic
child cleanup while preserving the enclosing runner job and its assertions.

* fix: clarify outside review fallback and CEO decisions

Render one applicable own-harness fallback path and retain native review,
disabled policy, and missing-coverage semantics. Align report field names
and mode labels, and make the existing per-cut scope approval explicit.

Regenerate skill outputs and keep the workflow judge's model, thresholds,
and retry policy unchanged.

* chore: move release to free version slot (v1.86.0.0)

PR #2852 now claims v1.85.0.0. Align the release metadata and
rename migration so upgrades from that version still receive it.

Co-Authored-By: OpenAI Codex <noreply@openai.com>

* fix: include engineering review prerequisites and restore branch context

* fix: recognize coverage diagrams and clarify design review instructions

* fix: preserve file identities and join Windows test processes

---------

Co-authored-by: OpenAI Codex <noreply@openai.com>
2026-09-14 14:32:45 -07:00

232 lines
16 KiB
TypeScript

import { expect, test } from 'bun:test';
import captured from './fixtures/design-primary-action-aj.json';
import { isDesignCountFirstReview, isDesignCountSetup } from './helpers/design-count-review';
import { designStep0Boundary, planCountQuestionPhase } from './helpers/claude-pty-runner';
test('the exact completed current primary-action choice starts Design review', () => {
expect(isDesignCountFirstReview(captured)).toBe(true);
expect(planCountQuestionPhase(captured, false, designStep0Boundary, isDesignCountFirstReview, isDesignCountSetup))
.toMatchObject({ preReview: false, reviewStarted: true });
});
function fresh(): any { return structuredClone(captured); }
function changeText(fp: any, change: (text: string) => string) {
const q = fp.nativeCall.questions[0], answer = fp.nativeCall.answers[q.question];
q.question = change(q.question); fp.nativeCall.answers = { [q.question]: answer };
}
function changeMenu(fp: any, change: (q: any) => void) {
const q = fp.nativeCall.questions[0]; change(q);
fp.options = q.options.map((o: any, i: number) => ({ index: i + 1, label: o.label }));
fp.nativeCall.answers = { [q.question]: q.options[0].label };
}
test('an offered deferral, reordered menu and consistently renamed control remain review decisions', () => {
for (const option of captured.nativeCall.questions[0]!.options) {
const fp = fresh(); fp.nativeCall.answers = { [fp.nativeCall.questions[0].question]: option.label };
expect(isDesignCountFirstReview(fp)).toBe(true);
}
const reordered = fresh(); changeMenu(reordered, q => q.options.reverse());
expect(isDesignCountFirstReview(reordered)).toBe(true);
const renamed = fresh(); changeText(renamed, s => s.replaceAll('Save', 'Submit'));
changeMenu(renamed, q => q.options.forEach((o: any) => {
o.label = o.label.replaceAll('Save', 'Submit'); o.description = o.description.replaceAll('Save', 'Submit');
}));
expect(isDesignCountFirstReview(renamed)).toBe(true);
const numbered = fresh(); changeText(numbered, s => s.replaceAll('Issue 1', 'Issue 6').replaceAll('1A', '6A').replaceAll('1B', '6B').replaceAll('1C', '6C'));
changeMenu(numbered, q => { q.header = 'Issue 6'; q.options.forEach((o: any) => { o.label = o.label.replace(/^1/, '6'); }); });
expect(isDesignCountFirstReview(numbered)).toBe(true);
});
test('native completion, owned identity, offered answers and aligned numbering are necessary', () => {
for (const change of [
(f: any) => { delete f.nativeCall; },
(f: any) => { f.nativeCall.answered = false; },
(f: any) => { f.nativeCall.failed = true; },
(f: any) => { f.nativeCall.sessionId = 'foreign-session'; },
(f: any) => { f.nativeCall.toolUseId = 'foreign-request'; },
(f: any) => { f.nativeCall.answeredAt = 'invalid'; },
(f: any) => { delete f.nativeCall.answeredAt; },
(f: any) => { f.nativeCall.unansweredQuestionIndices = [0]; },
(f: any) => { f.nativeQuestionIndex = 1; },
(f: any) => { f.nativeCall.answers = {}; },
(f: any) => { f.nativeCall.answers[f.nativeCall.questions[0].question] = 'unoffered'; },
(f: any) => { f.nativeCall.questions[0].question += ' altered'; },
(f: any) => { f.nativeCall.questions[0].header = 'Issue 2'; },
(f: any) => { f.nativeCall.questions[0].multiSelect = true; },
(f: any) => { f.options.reverse(); },
(f: any) => { changeMenu(f, q => { q.options[0].label = q.options[0].label.replace('1A', '2A'); }); },
]) { const fp = fresh(); change(fp); expect(isDesignCountFirstReview(fp)).toBe(false); }
});
test('quoted, hypothetical, future and explicitly withdrawn assessments cannot borrow style choices', () => {
for (const change of [
(s: string) => 'Example: ' + s,
(s: string) => '```text\n' + s + '\n```',
(s: string) => s.replace('ELI10: Right now', 'ELI10: Suppose right now'),
(s: string) => s.replace('ELI10: Right now', 'ELI10: If approved, right now'),
(s: string) => s.replace(/^ELI10: (.+)$/m, 'ELI10: "$1"'),
(s: string) => s.replace(/^ELI10: (.+)$/m, "ELI10: '$1'"),
(s: string) => s.replace(/^ELI10: (.+)$/m, 'ELI10: $1 This issue is withdrawn.'),
(s: string) => s.replace(/^ELI10: (.+)$/m, 'ELI10: $1 We have resolved this finding.'),
(s: string) => s.replace(/^ELI10: (.+)$/m, 'ELI10: $1 No current gap remains.'),
(s: string) => s + '\nCorrection: this issue is withdrawn.',
(s: string) => s.replace('make Save the only filled primary action?', 'make Save the only filled primary action in a future redesign?'),
(s: string) => s.replace('make Save the only filled primary action?', 'make the primary reviewer the next step?'),
(s: string) => s.replace('ELI10: Right now Save,', 'ELI10: Right now Publish,'),
]) { const fp = fresh(); changeText(fp, change); expect(isDesignCountFirstReview(fp)).toBe(false); }
});
test('the named amendment and unresolved violation belong to distinct current offered choices', () => {
for (const change of [
(q: any) => { q.options[0].description = q.options[0].description.replace('✅ Save is', '✅ Publish is'); },
(q: any) => { q.options[0].description = '✅ Example only: ' + q.options[0].description; },
(q: any) => { q.options[0].description = '✅ Save is not the single filled primary action.'; },
(q: any) => { q.options[0].description += ' This issue is withdrawn.'; },
(q: any) => { q.options[2].description = 'All buttons already comply. No current issue remains.'; },
(q: any) => { q.options[2].description = '❌ Hypothetical: Primary-action ambiguity ships; documented DESIGN.md violation remains.'; },
(q: any) => { q.options[2].description += ' Correction: this issue is resolved.'; },
(q: any) => { q.options[0].description += ' ' + q.options[2].description; q.options[2].description = 'Another compliant option.'; },
]) { const fp = fresh(); changeMenu(fp, change); expect(isDesignCountFirstReview(fp)).toBe(false); }
});
test('conditional stakes and an unrelated quoted historical claim retain the current choice', () => {
const fp = fresh(); changeText(fp, s => s.replace('Stakes if we pick wrong:', 'Stakes if we pick wrong: If unchanged,'));
expect(isDesignCountFirstReview(fp)).toBe(true);
const history = fresh(); changeText(history, s => s.replace('\nStakes if we pick wrong:', ' The old report claimed "This issue is resolved.", but that claim was wrong.\nStakes if we pick wrong:'));
expect(isDesignCountFirstReview(history)).toBe(true);
});
import { E2E_TOUCHFILES, selectTests } from './helpers/touchfiles';
test('the exact public fixture and controls select only the affected Design count workflow', () => {
for (const file of ['test/design-primary-action-aj.test.ts', 'test/fixtures/design-primary-action-aj.json'])
expect(selectTests([file], E2E_TOUCHFILES, []).selected).toEqual(['plan-design-finding-count']);
});
import deferredTodo from './fixtures/design-future-todo-aj.json';
import { isDesignArtifactGeneration } from './helpers/design-artifact-question';
test('the actual completed future-only TODO recording is administrative and retains freshness', () => {
expect(isDesignArtifactGeneration(deferredTodo)).toBe(true);
expect(planCountQuestionPhase(deferredTodo, true, designStep0Boundary, isDesignCountFirstReview,
isDesignCountSetup, undefined, isDesignArtifactGeneration)).toEqual({ preReview: false, reviewStarted: true, administrative: 'artifact-generation' });
});
test('skipping a future TODO is administrative, while building it now remains a review decision', () => {
for (const index of [0, 1, 2]) {
const fp: any = structuredClone(deferredTodo), q = fp.nativeCall.questions[0];
fp.nativeCall.answers = { [q.question]: q.options[index].label };
expect(isDesignArtifactGeneration(fp)).toBe(index !== 2);
const phase = planCountQuestionPhase(fp, true, designStep0Boundary, isDesignCountFirstReview,
isDesignCountSetup, undefined, isDesignArtifactGeneration);
expect(phase.preReview).toBe(false);
expect(phase.administrative).toBe(index !== 2 ? 'artifact-generation' : undefined);
}
const fp: any = structuredClone(deferredTodo);
expect(planCountQuestionPhase(fp, false, designStep0Boundary, isDesignCountFirstReview,
isDesignCountSetup, undefined, isDesignArtifactGeneration).reviewStarted).toBe(false);
});
test('a deferred artifact requires completed native identity, the exact answer and full aligned menu', () => {
for (const change of [
(f: any) => { delete f.nativeCall; },
(f: any) => { f.nativeCall.answered = false; },
(f: any) => { f.nativeCall.failed = true; },
(f: any) => { f.nativeCall.sessionId = 'foreign'; },
(f: any) => { f.nativeCall.answeredAt = 'invalid'; },
(f: any) => { f.nativeCall.unansweredQuestionIndices = [0]; },
(f: any) => { f.nativeQuestionIndex = 1; },
(f: any) => { f.nativeCall.answers = {}; },
(f: any) => { f.nativeCall.answers[f.nativeCall.questions[0].question] = 'unoffered'; },
(f: any) => { f.options.reverse(); },
(f: any) => { f.nativeCall.questions[0].multiSelect = true; },
(f: any) => { f.nativeCall.questions.push(structuredClone(f.nativeCall.questions[0])); },
(f: any) => { f.nativeCall.questions[0].options.pop(); },
]) { const fp: any = structuredClone(deferredTodo); change(fp); expect(isDesignArtifactGeneration(fp)).toBe(false); }
});
test('a deferred TODO cannot conceal current implementation, changed scope or source-only declarations', () => {
for (const change of [
(s: string) => 'Example: ' + s,
(s: string) => '```text\n' + s + '\n```',
(s: string) => s.replace('ELI10: DESIGN.md', 'ELI10: Suppose DESIGN.md'),
(s: string) => s.replace(/^ELI10: (.+)$/m, 'ELI10: "$1"'),
(s: string) => s.replace('so nothing changes now.', 'but replace the font now.'),
(s: string) => s.replace('in a later design pass?', 'in this update?'),
(s: string) => s + '\nCorrection: font replacement is now in scope; implement it now.',
]) { const fp: any = structuredClone(deferredTodo); changeText(fp, change); expect(isDesignArtifactGeneration(fp)).toBe(false); }
for (const index of [0, 1, 2]) {
const fp: any = structuredClone(deferredTodo);
fp.nativeCall.questions[0].options[index].description += ' Also fix the current form typography in this PR.';
expect(isDesignArtifactGeneration(fp)).toBe(false);
}
const current = fresh();
expect(isDesignArtifactGeneration(current)).toBe(false);
expect(isDesignCountFirstReview(current)).toBe(true);
});
test('deferred artifact classification follows offered identities and the current approved font', () => {
const reordered: any = structuredClone(deferredTodo);
changeMenu(reordered, q => q.options.reverse());
reordered.nativeCall.answers = { [reordered.nativeCall.questions[0].question]: 'A Add to TODOS.md (recommended)' };
expect(isDesignArtifactGeneration(reordered)).toBe(true);
const renamed: any = structuredClone(deferredTodo);
changeText(renamed, s => s.replaceAll('system-ui', 'ApprovedSans'));
changeMenu(renamed, q => q.options.forEach((o: any) => { o.description = o.description.replaceAll('system-ui', 'ApprovedSans'); }));
expect(isDesignArtifactGeneration(renamed)).toBe(true);
});
test('the deferred TODO fixture selects the same affected Design count workflow', () => {
expect(selectTests(['test/fixtures/design-future-todo-aj.json'], E2E_TOUCHFILES, []).selected).toEqual(['plan-design-finding-count']);
});
test('deferred TODO scope survives benign explanations, estimates and a concise equivalent proposal', () => {
for (const change of [
(s: string) => s.replace('Why: a chosen typeface is the cheapest tell that the app was designed rather than assembled. Pros: brand voice across the whole app.', 'Why: a deliberate typeface could make the application recognizable. Pros: a consistent future brand voice.'),
(s: string) => s.replace('(for example DM Sans, Instrument Sans, IBM Plex Sans)', '(for example Atkinson Hyperlegible)'),
(s: string) => s.replace('Stakes if we pick wrong: either the debt is forgotten, or a note lands in TODOS.md that you consider noise.', 'Stakes if we pick wrong: the future debt may be forgotten, or the backlog may become noisy.').replace('Recommendation: A because the debt is real but explicitly out of scope, and a written TODO costs nothing.', 'Recommendation: A to retain the explicitly out-of-scope debt for later.').replace('Net: keep the typography debt visible vs. drop it.', 'Net: record the deferred typography debt or omit the note.'),
(s: string) => s.replace('DESIGN.md and this plan keep system-ui as the app font, and you excluded visual exploration from this update, so nothing changes now.', 'DESIGN.md and this plan retain system-ui as the app font. Visual exploration remains out of scope for this update, so nothing changes now.'),
]) { const fp: any = structuredClone(deferredTodo); changeText(fp, change); expect(isDesignArtifactGeneration(fp)).toBe(true); }
const estimate: any = structuredClone(deferredTodo);
estimate.nativeCall.questions[0].options[0].description = estimate.nativeCall.questions[0].options[0].description.replace('human: ~5min / CC: ~1min to record', 'human: ~10min / CC: ~2min to record');
expect(isDesignArtifactGeneration(estimate)).toBe(true);
const concise: any = structuredClone(deferredTodo);
changeText(concise, s => s.replace('record a deferred TODOS.md item to evaluate a real body typeface', 'add a deferred TODOS.md note to consider an alternate body typeface').replace('in a later design pass?', 'during a future design pass?').replace(/^ELI10: .+$/m,
'ELI10: DESIGN.md and the current plan preserve system-ui as the app font. Visual exploration is out of scope for this update, so the current design remains unchanged. This question only records a deferred TODOS.md note for a future /design-consultation; it does not change the current design.'));
changeMenu(concise, q => {
q.options[0].description = '✅ Records only a TODOS.md note for a future /design-consultation. No design changes in this update; DESIGN.md and system-ui remain unchanged.';
q.options[1].description = '✅ No TODO is recorded. No follow-up work.';
q.options[2].description = '✅ Replace the font now in this PR.';
});
expect(isDesignArtifactGeneration(concise)).toBe(true);
});
test('paraphrased facts still require affirmative preservation and reject present work', () => {
for (const change of [
(s: string) => s.replace('so nothing changes now.', 'so it is false that nothing changes now.'),
(s: string) => s.replace('ELI10: DESIGN.md and this plan keep system-ui as the app font', 'ELI10: DESIGN.md and this plan keep Roboto as the app font'),
(s: string) => s.replace('Net: keep the typography debt visible vs. drop it.', 'Net: replace the font now.'),
(s: string) => s.replace('Net: keep the typography debt visible vs. drop it.', 'Net: this scope is withdrawn.'),
]) { const fp: any = structuredClone(deferredTodo); changeText(fp, change); expect(isDesignArtifactGeneration(fp)).toBe(false); }
const conditional: any = structuredClone(deferredTodo);
conditional.nativeCall.questions[0].options[0].description = conditional.nativeCall.questions[0].options[0].description.replace('Nothing changes in this update;', 'If approved: Nothing changes in this update;');
expect(isDesignArtifactGeneration(conditional)).toBe(false);
const additional: any = structuredClone(deferredTodo);
additional.nativeCall.questions[0].options[0].description += ' Add a 48px button target to this plan.';
expect(isDesignArtifactGeneration(additional)).toBe(false);
for (const suffix of ['Add a TODOS.md note and make the Save button 48px.', 'Add a TODOS.md note for the future font review and make the Save button 48px.']) {
const mixed: any = structuredClone(deferredTodo);
mixed.nativeCall.questions[0].options[0].description += ' ' + suffix;
expect(isDesignArtifactGeneration(mixed)).toBe(false);
}
const recordingOnly: any = structuredClone(deferredTodo);
recordingOnly.nativeCall.questions[0].options[0].description += ' Add a TODOS.md note for the future font review.';
expect(isDesignArtifactGeneration(recordingOnly)).toBe(true);
for (const suffix of ['Visual exploration is no longer out of scope.', 'This plan no longer keeps system-ui.']) {
const fp: any = structuredClone(deferredTodo);
changeText(fp, s => s.replace(/^ELI10: (.+)$/m, 'ELI10: $1 ' + suffix));
expect(isDesignArtifactGeneration(fp)).toBe(false);
}
const archival: any = structuredClone(deferredTodo);
changeText(archival, s => s.replace(/^ELI10: (.+)$/m, 'ELI10: $1 Historical note: "Visual exploration is no longer out of scope."'));
expect(isDesignArtifactGeneration(archival)).toBe(true);
});