TDD in the AI EraBarry S. StahlSolution Architect & DeveloperMicrosoft .NET MVPPhysics & Math Nerd@bsstahl@cognitiveinheritance.comhttps://CognitiveInheritance.com |
|
Favorite Physicists
Other notables: Stephen Hawking, Edwin Hubble, Leonard Susskind, Christiaan Huygens |
Favorite Mathematicians
Other notables: Daphne Koller, Grady Booch, Leonardo Fibonacci, Evelyn Berezin, Benoit Mandelbrot |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Key takeaways - If the tests are right, the code can be anything - If the tests are wrong or missing, the code can't be trusted |
|
|
|
|
|
|
|
|
|
|
|
|
|
Change Password service
|
Test Cases:[*] < [ ] old <> current → false [ ] All rules satisfied → true |
| Language | Canonical Stub Mechanism |
|---|---|
| C# | throw new NotImplementedException(); |
| C++ | throw std::logic_error("Not implemented"); |
| Elixir | raise "not implemented" |
| Go | panic("not implemented") |
| Java | throw new UnsupportedOperationException("Not implemented"); |
| JavaScript / TypeScript | throw new Error("Not implemented"); |
| Kotlin | TODO("Not implemented") |
| PHP | throw new \BadMethodCallException("Not implemented"); |
| Python | raise NotImplementedError("Not implemented") |
| Ruby | raise NotImplementedError, "Not implemented" |
| Rust | todo!() |
| Swift | fatalError("Not implemented") |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Research: Barke et al. (2023); Nair et al. (2023); Chen et al. (2021). |
|
|
|
|
|
|
|
|
|
| Tool | Code Gen | Spec Gen | Workflow | Reference |
|---|---|---|---|---|
| Claude | Primary | Supported | Supported | Claude Code Docs |
| Cline/Roo | Primary | Supported | Supported | Cline Docs & Roo Docs |
| Copilot Chat | Primary | Supported | Supported | Copilot Chat Docs |
| Copilot CLI | Primary | Supported | Supported | Copilot CLI Docs |
| Cursor | Primary | Supported | Supported | Cursor Docs |
| Kiro | Supported | Primary | Supported | Kiro Docs |
| OpenClaw | Supported | Supported | Primary | OpenClaw Repos |
| OpenCode | Primary | Supported | Supported | OpenCode Repos |
| OpenSpec | Supported | Primary | Supported | OpenSpec Repos |
| SpecKit | Supported | Primary | Supported | SpecKit Repo |
| Squad/Ralph | Supported | Supported | Primary | Squad Repos |
|
|
|
|
|
|
|
|
|
|
|