3 ms·
Have you read the original TDD book by Kent Beck? There's a lot of tips inside. Part of it is starting with what's easy but not obvious. Like a 1+1 might be too
by muzani 6y ago
Have you read the original TDD book by Kent Beck? There's a lot of tips inside. Part of it is starting with what's easy but not obvious. Like a 1+1 might be too obvious, but testing addition and deletion from a list might not be. You don't need a detailed plan. It might also help to just build tests moving forward rather than changing the structure.
The book handholds you through getting stuck on things so I highly recommend it. Tips include: If you know what to type, then type the Obvious Implementation. If not, fake it. If it's still not clear, write more tests and triangulate.
Also remember that refactoring without tests is not really refactoring. So ironically writing the tests first will help a lot.