Chapter 6. Digging deeper into isolation frameworks

This chapter covers

  • Working with constrained versus unconstrained frameworks
  • Understanding how unconstrained profiler-based frameworks work
  • Defining the values of a good isolation framework

In the previous chapter, we used NSubstitute to create fakes. In this chapter, we’ll step back to look at the bigger picture of isolation frameworks both in .NET and outside it. The world of isolation frameworks is vast, and there are many different things to consider when you choose one.

Let’s start with a simple question: Why do some frameworks have more abilities than others? For example, some frameworks are able to fake static methods, and some aren’t. Some are even able to fake objects that haven’t ...

Get The Art of Unit Testing, 2nd Edition now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.