Send the link below via email or IMCopy
Present to your audienceStart remote presentation
- Invited audience members will follow you as you navigate and present
- People invited to a presentation do not need a Prezi account
- This link expires 10 minutes after you close the presentation
- A maximum of 30 users can follow your presentation
- Learn more about this feature in our knowledge base article
Do you really want to delete this prezi?
Neither you, nor the coeditors you shared it with will be able to recover it again.
Make your likes visible on Facebook?
Connect your Facebook account to Prezi and let your likes appear on your timeline.
You can change this under Settings & Account at any time.
Transcript of TDD
One of the 17 behind the Agile Manifesto,
also the creator of XP, and Agile Software Development in general.
What is TDD?
A Development Practice that turns testing into
a Design activity.
Tests are written before the code.
Unit Tests Are?
A unit test is an automated piece of code that invokes a unit of work in the system and checks a single assumption about the behavior of that unit of work.
Properties of Unit Tests
Test-driven development (TDD) is a way
of managing fear during programming
Only test one Thing.
Uses Self Explanatory Data.
Serves as Documentation.
Good Unit Tests are
Three Laws of TDD
You may not write production code until you have written a failing Unit Test.
You may not write more of a Unit Test than is sufficient to fail.
You may not write more production code than is sufficient to pass the currently failing test.
The TDD Cycle
Add a Failing Unit Test
Add minimal amount of code
to produce a failing Test.
The TDD cycle again
Externalize & crystallize your thoughts
Add a failing Unit Test
Be the customer of your own code. Write the tests you would like to see.
Make The Test Pass
Add the minimal amount
of code to make the test pass.
Make the Test Pass
Make it work
Focus on making it work.
Committing any sins.
Avoid gold plating.
Make it Pretty
You should not feel ashamed if this source was put on display for the whole world.
TDD is a skill like any other
Must be practiced
TDD is easy to get going with, but it can be hard to know which tests are the right ones.
It can also be tricky to know which should be the first test.
Test-Driven Development - By Example.
Growing Object-Oriented Software, Guided By Tests
Steve Freeman and Nat Pryce
Clean Code - A Handbook Of Agile Software Craftsmanship
Robert C. Martin
The Clean Coder - A Code of Conduct for Professional Programmers
Robert C. Martin