FakeItEasy 9.0.0

Are you mocking me?

NuGet version Build status

A .NET dynamic fake library for creating all types of fake objects, mocks, stubs etc.

  • Easier semantics, all fake objects are just that - fakes - the use of the fakes determines whether they're mocks or stubs.
  • Context-aware fluent interface guides the developer.
  • Designed for ease of use.
  • Full compatibility with both C# and VB.Net.

Faking amazing example

// Creating a fake object is very easy!
// No mocks, or stubs; everything's a fake.
var shop = A.Fake<ICandyShop>();

// Easily set up a call to return a value.
var lollipop = new Lollipop();
A.CallTo(() => shop.GetTopSellingCandy()).Returns(lollipop);

// Exercise your system under test by using the fake as you
// would an instance of the faked type.
var customer = new SweetTooth();
customer.BuyTastiestCandy(shop);

// Asserting uses the same syntax as configuring calls.
A.CallTo(() => shop.BuyCandy(lollipop)).MustHaveHappened();

Resources


FakeItEasy logo designed by Vanja Pakaski.

No packages depend on FakeItEasy.

.NET Framework 4.6.2

.NET 8.0

.NET 10.0

Version Downloads Last updated
9.0.0 5 01/12/2026
8.3.0 5 12/12/2025
8.2.0 2 12/14/2025
8.1.0 1 12/14/2025
8.0.1 5 12/12/2025
8.0.0 4 12/14/2025
8.0.0-alpha.1.10 2 12/14/2025
8.0.0-alpha.1 4 01/01/2026
7.4.0 4 12/12/2025
7.3.1 1 12/11/2025
7.3.0 2 12/14/2025
7.2.0 2 12/14/2025
7.1.0 5 12/12/2025
7.0.2 3 12/14/2025
7.0.1 5 12/11/2025
7.0.0 3 12/10/2025
6.2.1 4 12/11/2025
6.2.0 3 12/12/2025
6.1.0 5 12/14/2025
6.0.1 4 12/14/2025
6.0.0 4 12/12/2025
5.5.0 2 12/14/2025
5.4.1 1 12/14/2025
5.4.0 3 12/14/2025
5.3.0 5 12/09/2025
5.2.0 3 12/13/2025
5.1.2 6 12/14/2025
5.1.1 2 12/14/2025
5.1.0 6 12/13/2025
5.0.1 1 12/14/2025
5.0.0 3 12/10/2025
4.9.2 3 12/14/2025
4.9.1 3 12/14/2025
4.9.0 2 12/14/2025
4.8.1 4 12/14/2025
4.8.0 2 12/14/2025
4.7.1 2 12/14/2025
4.7.0 2 12/14/2025
4.6.0 2 12/14/2025
4.5.1 2 12/13/2025
4.5.0 4 12/14/2025
4.4.0 1 12/14/2025
4.3.0 7 12/14/2025
4.2.0 2 12/14/2025
4.1.1 4 12/14/2025
4.1.0 3 12/14/2025
4.0.0 3 12/13/2025
3.4.2 2 12/14/2025
3.4.1 6 12/14/2025
3.3.2 5 12/12/2025
3.3.1 5 12/13/2025
3.3.0 2 12/14/2025
3.2.0 3 12/14/2025
3.1.0 2 12/11/2025
3.0.0 5 12/12/2025
2.3.3 4 12/14/2025
2.3.2 4 12/14/2025
2.3.1 6 12/13/2025
2.3.0 3 12/12/2025
2.2.0 4 12/13/2025
2.1.0 5 12/12/2025
2.0.0 2 12/13/2025
1.25.3 8 12/14/2025
1.24.0 6 12/14/2025
1.23.0 1 12/14/2025
1.22.0 3 12/12/2025
1.21.0 3 12/15/2025
1.20.0 1 12/14/2025
1.19.0 4 12/14/2025
1.18.0 4 12/12/2025
1.17.0 4 12/13/2025
1.16.0 4 12/12/2025
1.15.0 7 12/12/2025
1.14.0 5 12/10/2025
1.13.1 7 12/14/2025
1.12.0 5 12/13/2025
1.11.0 6 12/14/2025
1.10.0 7 12/14/2025
1.9.1 3 12/12/2025
1.8.0 7 12/10/2025
1.7.4626.65 5 12/13/2025
1.7.4582.63 4 12/14/2025
1.7.4574.62 10 12/14/2025
1.7.4507.61 5 12/10/2025
1.7.4257.42 4 12/12/2025
1.7.4166.27 3 12/14/2025
1.7.4117.2 2 12/14/2025
1.7.4109.1 3 12/13/2025
1.6.4075.221 6 12/12/2025
1.6.4062.205 6 12/11/2025
1.5.3970.199 6 12/12/2025
1.0.0.5 6 12/12/2025