Build UI More Confident Using Component Testing
summary
Demonstrates using component testing in a real browser (not E2E) with Cypress (also workable in Playwright/Storybook), React Query and XState, mounting components in a memory router and mocking a custom query client to force deterministic responses. Shows an editor that sends CRDT operations and how tests assert operations sent to backend instead of UI markup, uses data-testids, CI + local pre-push runs with retries to reduce flakiness, and reports multiple editor rewrites that keep passing unchanged tests.
AI-written summary · about
chapters (12)
- 0:00Introduction and welcome
- 1:04Starting with a quote
- 2:30Who am I and talk overview
- 3:11Defining confidence in code
- 6:02Confidence journey: Hills and valleys
- 8:29Example one: State machines in Minter
- 11:17Example two: Minter from zero to essential
- 15:34What is component testing?
- 17:40Demo one: React Query app
- 27:21Demo two: Minter editor tests
- 31:38Testing subjectivity and balance
- 34:53Q&A session
