C# revised labs - 2023

  • Introduction to testing and test first driven approach

  • Outline where test data comes from (important because most developers really get it and think they have to dream up test data)

  • TDD lifecycle

  • Introduction to HighestNumberFinder using TDD (walkthrough) - this is the case study

  • Quicklab - complete the tests for the requirements that the walkthrough does not complete

  • Quicklab - String Splitter (API calls not allowed lol)

  • Anatomy of Unit Tests

  • Quicklab - UK Car Registration numbers

  • Decoupling code so it is more testable - introduction to TopicManager (walkthrough), this extends the case study

  • Test Doubles - Stubs

  • TopicManager and a HighestNumberFinder stub (walkthrough)

  • Quicklab - Compleee TopicManage tests but using Stub for HighestNumberFinder

  • Introduction to Mocking and mocking concepts - walkthrough lots of sample code

  • Handling IO with Mocks (walkthrough with quicklabs) - solve a complex IO problem from scratch using TDD and Mocks

  • Working with untestable (legacy) code