- Learn the history and value of Test-Driven Development
- Explore the five practices that comprise TDD
- Understand the test-first mindset and use it as Just-in-Time problem analysis
- Learn refactoring as Just-in-Time design
- Practice adding tests to legacy code
- Learn about emergent design and simple design
- Use mock objects to decouple difficult dependencies
Essential Test-Driven Development is a 3-day course for developers, providing hands-on experience with the techniques of Test-Driven Development (TDD). This course is designed for experienced developers who are comfortable with their programming language and the basics of object-oriented design. Attendees learn the techniques of test-first, refactoring, mock objects, and others. They learn how these techniques provide and maintain a very low defect-count, plus why TDD helps developers work fearlessly, swiftly, and comfortably on new features and bug-fixes. Attendees will also learn how to work on legacy code: building test-coverage for critical areas, and protecting areas of the legacy system that do not yet require any alteration.
This set of practices for developers is at the heart of low-defect agile software development. These techniques allow incremental development and Emergent Design to flourish, without degrading quality. This course also contains a significant section on the not-so-pleasant task of adding unit tests to legacy code. The course is currently offered in Java, JavaScript, C#, VB.net, or C++.
Who Should Attend/Prerequisites
This is an intermediate to experienced level course intended for software developers. Attendees should have competence with either the Java, JavaScript, VB.net, C++, or C# programming languages, a familiarity with basic object-oriented principles of design and a basic familiarity with an agile process such as Scrum or XP.
This course involves hands-on programming. Please bring a laptop with your IDE loaded. If you have any difficulty bringing a laptop, please let us know immediately.
3-Day Course Outline
Introductions and Logistics
High-Level Overview, Basics, and Getting Started
Basic syntax for the xUnit family of unit-testing frameworks
Group TDD exercise/lab
Review the basic steps
Parsing "unit test"
The big picture exercise
Discipline: A user-friendly definition
Refactoring
Refactoring exercise
Tested-trek exercise
Refactoring and Design
The developers "Oath of Athens"
Brief review of "simple design" rules, emergent design and others
Refactoring to OCP
Map of Mars: Demonstrating the Open-Closed Principle (OCP), refactoring, and emergent design
Exercise
Test-First
Just-in-Time problem analysis
The computer-science perspective
Password checker exercise
The broken set exercise
Mock Objects
Mock historian exercise
Painful dependencies
Two simple approaches to building mocks
The LunEx exercise
Legacy Code
Definitions of "legacy"
What code to deal with today
The testing/refactoring, chicken/egg problem
The Mess-Trek exercise
Putting it All Together
Immersion
The battleship game exercise
Other Topics (Time Permitting)
TDD and agile
ATDD overview
Course Retrospective
Class Daily Schedule
Training Course Fee Includes





