Test Driven Development by Sameer Arora

  • 789 views
Uploaded on

 

  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Be the first to comment
    Be the first to like this
No Downloads

Views

Total Views
789
On Slideshare
0
From Embeds
0
Number of Embeds
0

Actions

Shares
Downloads
10
Comments
0
Likes
0

Embeds 0

No embeds

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
    No notes for slide

Transcript

  • 1. Test-Driven Development
    • What is Test-Driven Development?
    • Origins of TDD
    • Clean code with no defects
    • TDD in conjunction with Agile
  • 2. Why TDD ?
    • Much less time needed to debug
    • Code proven to meet requirements
    • Quick feedback at each step
    • Rhythm of Success
  • 3. Mechanics of TDD
    • Start with a failing test
    • Write the simplest code needed to pass the test
    • Remove duplication ( Refactor )
    • Repeat as needed to meet requirements
    RED GREEN REFACTOR
  • 4. What should be tested?
    • Valid inputs
    • Invalid inputs
    • Errors, exceptions, and events
    • Boundary conditions
    • Everything that could possibly break!
  • 5. TDD as a Design Technique
    • Design only what you need to make the test pass
    • Requirements drive the design of code
    • Design evolves with time
  • 6. Fixing Bugs – TDD Style
    • Go after the most painful defect
    • Write a test to expose it
    • Write code needed to fix it
    • Refactor
    • Measure the results
  • 7. TDD Benefits for Business
    • Shorter development cycles
    • Near zero defects
    • Tests become an asset
    • Tests are documentation
    • Competitive advantage!
  • 8.
    • Get some training
    • Start with a small visible project
    • Shoot for 100% test coverage
    • Don’t expect to be perfect
    • Expect to improve dramatically in time
    • Measure the results
    Getting started with TDD
  • 9. Test-Driven Development TDD Demonstration