Test Driven Development

Students will learn test driven design (TDD), refactoring, test doubles usage, mocking frameworks, and dependency injection. Students will apply the lessons introduced in the presentation through a series of hands-on exercises. The course is highly interactive and the material is a blend of presentation and a hands-on tutorial.

Objectives (tools and techniques participants will learn)

  • Effective use of test driven design (TDD) to drive development.
  • The proper use of refactoring to help cultivate a resilient and communicative code base.
  • The value of test doubles usage within your TDD efforts. Mocking frameworks will be introduced.
  • The value of the dependency injection (DI) design pattern usage.

Audience (who will benefit - who should attend)

Developers and managers interested in jump starting their TDD and refactoring efforts or improving their existing TDD behaviors with the use of test doubles and dependency injection.

Agenda (content and format)

Day One

Introductions and Logistics

  • Introductions
  • Logistics
  • Expectations

Introducing Test Driven Design (TDD)

  • What is test driven design? Why should I use TDD?
  • Driving your development with unit tests
  • Hands-on exercises

Introducing refactoring

  • What is refactoring? When and why should I refactor?
  • Hands-onexercises

Day Two

Introducing test doubles

  • What are test doubles? When should test doubles be used?
  • Survey of test doubles, including stubs, fakes, test spies, and mock objects.
  • Introduction to mocking frameworks for student’s particular platform.

Introducing dependency injection (DI)

  • What is dependency injection and how does it help in building better quality software?
  • Survey of dependency injection frameworks available for student’s particular platform.