Choose your language:

Hong Kong
New Zealand
United Kingdom
United States

Introduction to Test-Driven Development (TDD) for C#

Course Code



2 Days

Familiarity and suitable competence with the selected programming language(s) is required. Participants will support and provide each other feedback as the workshop instructor provides overviews. A familiarity with basic object-oriented principles of design is also required. Basic familiarity with an Agile process such as Scrum, XP, or Kanban.
This agile training course engages participants in the concepts, actions, and techniques associated with Test-Driven Development (TDD). Participants learn a multitude of models, including legacy code, building test-coverage for critical areas, and advanced practices in Low-Defect Agile Software Development. The course is 2-days and will summarize the theories of a testing first mind-set, refactoring, mock objects, regression testing, and emergent design. The benefits of consistent TDD use will be aligned with the agile best-practices. Participants can expect more assurance in the detection, location, and correction of errors, have the ability to build a library of successful tests, and adapt up-front testing as a preferred methodology. Ensuring a streamlined, cost-effective, Agile way to work. Lab immersion is threaded throughout the course allowing participants to practice what they learn in the workshop setting, discuss, and then use upon returning to operations in their field.
This course is designed for astute Software Developers, with a passion for innovation. Testers and Managers can also benefit from the course, but must have capability to read and understand the basic syntax and conventions of the selected programming language. Interested participants who want to ensure automated testing is accurate and correct time and time again, will benefit from this course. It is important to know “real” work will be happening during lab time, and this will require advanced knowledge and comfort in a development environment. Observation can take place during class for those who are not at the expert level, but wish to be part of the classroom lab engagement.

In this course, participants will:

  • Define Unit Testing concepts and best practices
  • Examine Unit Testing concepts and best practices in a practice focused workshop setting
  • Explore the Test-First mindset
  • Outline the importance of testing
  • Identify what needs to be tested
  • Identify what constitutes poorly designed code
  • Assess the steps to take toward improving poorly designed code
  • Describe unit test frameworks
  • Discover the history and value of TDD
  • Associate Agile practices to TDD
  • Discover how to write effective unit tests
  • Explore the properties of effective unit tests
  • Examine the use of Mock Objects to decouple difficult dependencies
  • Interpret the meaning of technical debt
  • Define the process and concepts of refactoring
  • Discover how to locate code to be refactored
  • Experiment with refactoring techniques
  • Explain the necessity of adding tests to legacy code
  • Measure the success of unit testing
  • Assess the success of the testing by completing “mini tests” within the practice workshop environment
  • Construct intricate and challenging concepts into decipherable, well-thought-out, and resourceful code, without down time
Test Driven Development (TDD)
TDD History
TDD Benefits

TDD and Agile
The Agile Manifesto
Where Does TDD Fit into Agile Practice
Unit Testing Background
What is a Unit Test?
Unit Test Best Practices
Black Box vs. White Box Test
Lab 1

Unit Testing Framework
What is a Unit Test Framework?
Test Harness
Lab 2

Red, Green, Refactor
Do’s and Don’ts of Unit Tests
Keep Unit Tests Reliable
Elements of a Successful Test
Test Writing Checklist
Legacy Unit Testing

Understanding Requirements
Deciding What to Test
User Stories and Acceptance Criteria

Code Coverage
Lab 3

Code, Smells, Technical Debt and Design
Technical Debt
Finding Technical Debt and What to Do About It
Common Code Smells

Addressing Technical Debt
Relationship between Tests and Design
Refactoring Concepts
Smells and Refactoring
Limitation of Refactoring Tools and Patterns
Lab 4

Test Doubles
What is a Test Double?
Fakes, Stubs, and Mock Objects
Manual vs. Mock Framework
Lab 5

Succeeding with TDD
Organizational Challenges and How to Overcome Them

Unit Test vs Acceptance Test
BDD Participants and Interactions
How to Write Behavioral Unit Tests
BDD Framework
BDD Examples

Mutation Testing
What is Mutation Testing and Why it is Good to Use It
Mutation testing Integration
Send Us a Message
Choose one