Like many modern programming frameworks, .NET has built-in support for testing. In this chapter, we’ll cover the basics of writing and running unit tests. The dotnet command-line interface (CLI) tool has a command to initiate tests but doesn’t perform the tests on its own. Instead of forcing one test framework for all of .NET, the dotnet CLI tool looks for a test harness. The test harness usually comes from a package. Many test harnesses and frameworks are available, but in this chapter and beyond, we’ll use the xUnit framework for testing. Your company may use a different framework, but many of the strategies and concepts should translate.