Testing Strategy
Ideon uses Jest with ESM support and focused test suites.
Current Suites
options.test.ts: T2I coercion/sanitization/defaultsarticleSchema.test.ts: schema boundary validationmarkdown.test.ts: markdown rendering contractpipeline.runner.test.ts: stage orchestration behavior (multi-targets, generation dirs, resume semantics)config.resolver.test.ts: precedence and idea resolutionpreviewHelpers.test.tsandpreviewServer.test.ts: recursive discovery, generation grouping, preview resilience, asset servingpreviewServer.internals.test.tsandpreviewServer.branches.test.ts: preview branch/error-path and shell/API behaviorsrc/preview-app/App.test.tsx: React preview integration behavior (selection, tab switching, logs inspector)src/preview-app/interactions.test.ts: interaction normalization and grouping utilitiesprompts.framework.test.ts: framework/style/content-type prompt layeringwrite.command.test.ts: target parsing and CLI write option behavior
Run Tests
npm test
npm run test:watch
npm run test:coverage
Quality Gates
Recommended baseline before merge:
npm run lint
npm test
npm run build
npm run docs:build
Extending Coverage
Priority additions:
- More preview UI interaction coverage (theme, mobile drawer, and empty/error states)
- Additional failure-path coverage for provider responses
- Integration coverage for delete semantics in mixed generation directories