TDD & DDD from the Ground Up Live Coding
summary
Live coding builds a tiny university API with live coding tests that start as API-level TDD and evolve into focused unit tests, using Spring Boot controllers, repositories and CompletableFuture to reproduce a concurrency race; each commit is a single, small step you can replay from the GitHub history so you see the refactor path. The demo adds a scheduler that replaces the enrollment capacity check, shows a reproducible concurrency failure, and ends with a working scheduling algorithm and clearer domain model.
AI-written summary · about
chapters (30)
- 0:00TDD and DDD intro
- 2:48Understanding TDD and behavior
- 3:51Spring Boot setup
- 4:55First test: student registration
- 6:18ID allocation and DDD refactor
- 7:01Ubiquitous language in code
- 8:47Location header and API response
- 10:11Tests with implementation benefits
- 11:55API vs domain models
- 13:01Domain terms with ContexDiv
- 14:25Testing student persistence
- 17:35Code by domain concepts
- 19:44Rooms with capacity
- 20:26Courses in catalog
- 21:09Linking courses to rooms
- 22:12Room ID validation
- 23:51Balancing tests and steps
- 26:39Domain services for logic
- 27:43Course enrollment checks
- 30:10Refactoring to avoid debt
- 34:17Testing and deploying enrollment
- 35:05Race conditions in production
- 38:15Concurrency testing
- 40:45Event storming revisit
- 43:51Redesigning scheduling
- 45:17Removing unnecessary features
- 46:41Scheduling algorithm
- 48:28Testing business logic
- 51:15Finalizing scheduling service
- 51:58Resources and closing
related talks
47mTDD & DDD from the Ground Up
46mHow John Started to Like TDD (Instead of Hating It)
58mTDD for database related code, how is it possible?
45mTDD makes you a better everyday developer
54mTDD Workshop: Outward-in Development, Unit Tests, and Fixture Data
56mTDD: seriously, try it!
56mBuilding Operable Software with TDD (but not the way you think)
29mAh, Wonderful TDD — Peace of Mind for Apps and Engineers
