Test-Driven Development Using Visual Studio and MSTest
Course Description
This one-day course for developers explains the methodology of test-driven development and the use of Microsoft’s MSTest unit testing framework that comes with Visual Studio 2026, including the free Community version.
The course is practical, with many example programs and tests written in C#, including a cumulative case study. The goal is to quickly bring you up to speed in doing unit testing in your .NET development projects.
1 Day
Contact us for pricing
Learning Objectives
Understand the principles of test-driven developmentAcquire fluency in developing tests using the Visual Studio unit testing framework
Efficiently exercise test suites using Visual Studio and MSTest
Pre-requisites
Participants should have a basic knowledge of .NET Core and experience programming in C# with Visual Studio.This course is designed to run on .NET 9.0, which is the latest version of .NET Core.
Test-Driven Development
What Is Test-Driven Development (TDD)?Functional Tests / Customer Tests
Unit Tests / Programmer Tests
Test Automation
Simple Design
Refactoring
A Visual Studio Test Drive
TDD with Legacy Code
Visual Studio Unit Testing Fundamentals
Structure of Unit TestsUnit Testing Framework
Assertions
Test Cases
Test Classes
Test Runners
Ignoring Tests
Initialization and Cleanup
More about MSTest Framework
Expected ExceptionsCustom Asserts
Playlists
Debugging Unit Tests
Command-line Test Runner
Refactoring
.NETC#Visual StudioVisual Studio 2022VS2022Microsoft Visual Studio 2022VS 2022TDDTest Driven DevelopmentSoftware TestSoftware TestingMSTestMS TestVisual Studio 2026VS2026