import type { Command } from 'commander'; import { type CommandIO, type CommandResult } from '../../services/io.js'; /** * `cadence tutorial` — run one real DRAFT→BUILD→SETTLE loop inside an ephemeral * sandbox, built around the catch: the loop stages a lie (a task marked DONE * with no test backing its AC), settle REFUSES to close, the tutorial fixes it, * and settle then genuinely passes. The refusal is the money moment. * * Every step composes the real engine services — no `--ac` manual assertion and * no coverage bypass — so the walkthrough can never drift from real behavior, * and a skeptic could reproduce each command by hand. */ export interface TutorialOpts { /** Skip the between-step pause (always true for non-TTY / CI / agents). */ noPause?: boolean; } /** A single walkthrough step, run against the sandbox root. */ type Step = (ctx: { root: string; io: CommandIO; }) => Promise; /** Test seam: lets a test inject steps (e.g. a throwing one) to exercise the * sandbox-cleanup `finally` without running the full loop. */ export interface TutorialDeps { steps?: Step[]; } /** * Run the tutorial. Creates a sandbox, runs the steps, and always removes the * sandbox (even on error). Returns `loopPosition` + `summaryWritten` read back * from the sandbox before cleanup. Throws if a step throws. */ export declare function runTutorial(opts: TutorialOpts, io: CommandIO, deps?: TutorialDeps): Promise; export declare function registerTutorialCommand(program: Command): void; export {}; //# sourceMappingURL=tutorial.d.ts.map