Guides
Testing
This guide is the entry point for testing Rezi apps and framework changes.
This guide is the entry point for testing Rezi apps and framework changes.
Quick start
Run the deterministic suite:
npm testRun package tests only:
npm run test:packagesRun script tests only:
npm run test:scriptsFilter to a subset:
node scripts/run-tests.mjs --filter "layout"What to test
- Unit behavior for pure helpers and validators.
- Integration behavior for rendering, routing, and event flow.
- Regression coverage for bugs (repro test first, then fix).
- Snapshot/visual stability for renderer-facing changes.
- Responsive behavior validation across multiple viewport sizes (
**/*.test.{ts,tsx,js,jsx}).
Renderer and widget tests
For high-level widget assertions, prefer createTestRenderer() so tests can use:
findById(...)findAll(...)findText(...)toText()
Snapshot workflow
Use the snapshot CLI:
node scripts/rezi-snap.mjs --verify
node scripts/rezi-snap.mjs --updateUI regression validation
For layout/theme/render regressions, include a live PTY run with frame-audit evidence: