Fundamentals of TDD

You've heard about testing, and even better "Test-Driven Development", but you're still not sure exactly what they are. Well now you'll know!

In this trail, thoughtbot developers Harry Schwartz and Ian C. Anderson cover core principles of writing code with Test-Driven Development. You'll learn about the benefits of testing, the way testing first applies positive design pressure to your code, and how to apply TDD to your own development.

Topics include the red-green-refactor loop, tests as living documentation of your code, why your test code shouldn't necessarily be free of duplication, leveraging your tests to lower risk when refactoring, and strategies for balancing integration and unit tests.

An included exercise offers an opportunity to get your hands dirty with RSpec and improve an existing test suite.

Ian C. Anderson

Ian is a web developer who values good naming and bad puns. He is a fan of Ruby for its expressiveness and focus on TDD, and is interested in functional languages like Elixir, Elm, and Haskell. When he's not trying to find the perfect name for a function, he might be playing music or brewing beer at home.