TDD Like You've Never Seen it Before
Join the DZone community and get the full member experience.
Join For FreeTest-driven development is a popular (but not yet mainstream) practice for developing software in fully-working increments of functionality. Advocates claim it results in well-designed code that "just works", accompanied by "living documentation" in the form of automated tests.
Test-driven development, or TDD, consists of the following loop:
- Write a failing test case that encodes some behavior you need.
- Write just enough code to pass the test case in the simplest possible way.
- Refactor to improve the design of the code.
- Repeat until you have all the behavior you need.
In a new screencast published on Vimeo, agile software developer John A. De Goes demonstrates the basics of TDD in a shared development environment. The twenty-minute screencast shows John and two other developers as they TDD a basic Stack in the Java programming language.
Test case
Test-driven development
Software developer
Testing
dev
Software
Pass (software)
Documentation
Opinions expressed by DZone contributors are their own.
Comments