Building Operable Software with TDD (but not the way you think) by Martin Thwaites

Take a deeper dive into TDD with Martin Thwaites, exploring how to build operable software by tracing the system, testing contracts, and more. Discover the benefits and challenges of Test-Driven Development.

Key takeaways
  • TDD (Test-Driven Development) is not just about writing tests, but about understanding the behavior and requirements of the system.
  • The goal of TDD is to write software that is operational and can be debugged, not just to write unit tests.
  • Observability is a key part of TDD, tracing the entire system from the outside in, including database interactions, network calls, and system performance.
  • Contract testing is another important part of TDD, testing the contracts between different components of the system, not just individual classes.
  • The benefits of TDD include having a system that is fully tested and operable, allowing for easier debugging and maintenance.
  • The main challenge is to write tests that are readable and reusable, making it easy to understand what is being tested.
  • Component testing is an important aspect of TDD, focusing on testing individual components of the system, not just individual classes.
  • Integration testing is not a valuable concept, as it can mean different things to different people.
  • Outside-in testing is an important approach to testing, focusing on the external interface of the system, rather than internal implementation details.
  • The .NET framework has a good implementation of OpenTelemetry, allowing for easy instrumentation of code.
  • Writing descriptive test names is important, as it makes it easier to understand what is being tested.
  • TDD is not about testing implementation details, but about testing the behavior and requirements of the system.