Benutzer-Werkzeuge

Webseiten-Werkzeuge


se:tdd

Test Driven Development

\cite[S. ix]{Beck2003} In TDD, we

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

The TDD mantra \cite[S. x]{Beck2003}

  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 \cite[S. 1]{Beck2003}

  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)