Benutzer-Werkzeuge

Webseiten-Werkzeuge


se:tdd

Test Driven Development

[Beck2003, S. ix] In TDD, we

  • write new code only if an automated test has failed
  • eliminate duplication.

The TDD mantra [Beck2003, S. x]

  1. red: write a little test that doesn't work, and perhaps doesn't even compile at first.
  2. green: make the test work quickly, committing whatever sins necessary in the process.
  3. refactor: eliminate all of the duplication created in merely getting the test to work.

The rhythm of TDD [Beck2003, S. 1]

  1. quickly add a test
  2. run all tests and see the new one fail
  3. make a little change
  4. run all tests and see them all succeed
  5. refactor to remove duplication
se/tdd.txt · Zuletzt geändert: 2014-04-05 11:42 (Externe Bearbeitung)