FakeItEasy 8.3.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 6.0

.NET 8.0

.NET Standard 2.0

.NET Standard 2.1

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