Pros and cons of TDD

Why do TDD?

  • if you are starting your journey with software development it might be a good path to follow
  • TDD is an effective way of discovering relationships between objects while doing OOP
  • tests document the code
  • it is easier to spot errors and code smells in production code when we have good tests, one just has to seek for simple patterns in the tests
  • there is an increasing need for TDD skills in IT market
  • do it for fun, experience new approach to software development
  • any other ideas? 🙂

When it might not be the best idea?

  • prototyping
  • example: project runs for 3 months and then goes to production only for one month, we might then test only the critical paths through the system
  • sometimes there is no business value in TDD, for example you do a project on you own and you are a very experienced developer, then you might test only the critical paths of the application
  • very little time to release the product, but willing to pay the technical debt and intrest for the technical debt in the future
  • any other ideas? 🙂