Part 3. Testing

 

Testing your application gives you confidence that your code does what it’s supposed to. This part focuses on testing .NET applications.

In chapter 6, you’ll learn what unit tests are, what the SOLID principles are and why they matter, and how to build and run unit tests.

Chapter 7 delves into the trickier aspects of testing where external dependencies need to be replaced. You’ll see that .NET has some built-in substitutions; for other substitutions, you’ll need fakes.

Chapter 8 goes one level higher to integration testing. You’ll learn how to write tests for code that interacts with external databases or web services. You’ll also get experience with ASP.NET’s built-in integration-testing components, which allow you to test a web service from top to bottom. By the end of this part, you’ll have the tools to build a full test suite and prove that your code works as intended.