FluentAssertions 1.7.0

There is a newer version of this package available.
See the version list below for details.
Install-Package FluentAssertions -Version 1.7.0
dotnet add package FluentAssertions --version 1.7.0
<PackageReference Include="FluentAssertions" Version="1.7.0" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add FluentAssertions --version 1.7.0
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: FluentAssertions, 1.7.0"
#r directive can be used in F# Interactive, C# scripting and .NET Interactive. Copy this into the interactive tool or source code of the script to reference the package.
// Install FluentAssertions as a Cake Addin
#addin nuget:?package=FluentAssertions&version=1.7.0

// Install FluentAssertions as a Cake Tool
#tool nuget:?package=FluentAssertions&version=1.7.0
The NuGet Team does not provide support for this client. Please contact its maintainers for support.

A very extensive set of extension methods for .NET 3.5, 4.0 and Silverlight 4.0 that allow you to more naturally specify the expected outcome of a TDD or BDD-style unit test.

This package has no dependencies.

NuGet packages (318)

Showing the top 5 NuGet packages that depend on FluentAssertions:

Package Downloads
FluentAssertions.Json

Fluent Assertions extensions for Newtonsoft.Json

FluentValidation.Validators.UnitTestExtension

A unit test library for .NET that allows you to build tests for FluentValidation rules in easy way.

FluentAssertions.AspNetCore.Mvc

Fluent Assertions extensions for ASP.NET Core MVC.

FluentAssertions.Autofac

Fluent Assertions extensions for Autofac

FluentAssertions.Mvc5

Fluent Assertions extensions for ASP.NET MVC 5.

GitHub repositories (448)

Showing the top 5 popular GitHub repositories that depend on FluentAssertions:

Repository Stars
App-vNext/Polly
Polly is a .NET resilience and transient-fault-handling library that allows developers to express policies such as Retry, Circuit Breaker, Timeout, Bulkhead Isolation, and Fallback in a fluent and thread-safe manner. From version 6.0.1, Polly targets .NET Standard 1.1 and 2.0+.
IdentityServer/IdentityServer4
OpenID Connect and OAuth 2.0 Framework for ASP.NET Core
felixse/FluentTerminal
A Terminal Emulator based on UWP and web technologies.
restsharp/RestSharp
Simple REST and HTTP API Client for .NET
dotnet/orleans
Orleans is a cross-platform framework for building distributed applications with .NET
Version Downloads Last updated
6.1.0 1,066,785 8/22/2021
6.0.0 237,132 8/13/2021
6.0.0-beta0003 4,494 8/11/2021
6.0.0-beta0002 3,714 8/5/2021
6.0.0-beta0001 64,504 6/1/2021
6.0.0-alpha0002 208,494 1/7/2021
6.0.0-alpha0001 287,325 7/24/2020
5.10.3 35,570,584 3/21/2020
5.10.2 4,196,731 2/9/2020
5.10.0 3,703,732 1/2/2020
5.9.0 9,018,352 8/28/2019
5.8.0 1,354,210 8/9/2019
5.7.0 4,923,466 6/8/2019
5.6.0 9,624,751 1/11/2019
5.5.3 2,770,034 11/20/2018
5.5.1 209,086 11/16/2018
5.4.2 2,915,366 9/14/2018
5.4.1 4,135,603 6/20/2018
5.4.0 455,597 6/13/2018
5.3.2 690,152 5/30/2018
5.3.0 1,896,001 4/19/2018
5.2.0 1,361,846 3/15/2018
5.1.2 1,022,370 2/19/2018
5.1.1 172,944 2/14/2018
5.0.0 1,235,227 2/4/2018
4.19.4 6,584,596 8/24/2017
4.19.3 1,346,729 7/4/2017
4.19.2 3,223,878 3/8/2017
4.19.0 1,189,030 2/4/2017
4.18.0 1,661,325 12/4/2016
4.17.0 712,399 11/9/2016
4.16.0 307,188 10/26/2016
4.15.0 258,009 10/11/2016
4.14.0 814,577 9/5/2016
4.13.1 90,341 9/1/2016
4.13.0 399,453 8/2/2016
4.12.0 620,856 7/15/2016
4.11.0 224,479 7/6/2016
4.10.0 20,336 7/5/2016
4.9.1 220,105 6/23/2016
4.9.0 146,055 6/13/2016
4.8.0 77,768 6/7/2016
4.7.0 51,905 6/6/2016
4.6.3 294,281 5/24/2016
4.6.2 43,326 5/22/2016
4.6.1 131,596 5/13/2016
4.5.0 263,062 4/25/2016
4.4.0 162,343 4/17/2016
4.3.2 81,023 4/3/2016
4.3.1 4,866 4/1/2016
4.3.0 68,675 3/31/2016
4.2.2 579,171 2/5/2016
4.2.1 322,541 1/10/2016
4.2.0 209,222 1/8/2016
4.1.1 155,858 12/13/2015
4.1.0 330,252 11/24/2015
4.0.1 356,589 10/21/2015
4.0.0 455,307 8/24/2015
4.0.0-beta0001 2,799 8/7/2015
3.5.0 308,346 8/2/2015
3.4.1 288,523 7/3/2015
3.4.0 98,035 6/22/2015
3.3.0 785,540 2/18/2015
3.2.2 233,987 12/12/2014
3.2.1 365,897 9/11/2014
3.1.229 205,730 7/29/2014
3.0.107 326,706 4/30/2014
2.2.0 590,059 12/30/2013
2.1.0 244,140 8/23/2013
2.0.1 257,641 3/3/2013
2.0.0.1 111,837 10/15/2012
1.7.1.1 79,641 3/24/2012
1.7.0 9,544 1/13/2012
1.6.0 13,703 10/31/2011
1.5.0 8,961 6/29/2011
1.4.0 5,345 3/14/2011
1.3.0.1 17,495 1/15/2011

- Added methods for asserting that a collection of types matching a predicate have specific methods that are virtual or marked with a specific attribute.
     - Added methods for asserting XElements and Xattributes
     - Added support for recursively comparing the properties of nested (collection of objects ). By default it will compare all properties of the expected object graph, unless SharedProperties is used.
     - Added a fallback mechanism so that if FA cannot find any of the supported frameworks, it will fall back to using a custom AssertFailedException exception class rather than crashing.
     - Added support for ComparisonMode.StartWith and ComparisonMode.StartWithEquivalent when asserting the message of an exception.
     - For assertions that verify against a Type, the failure message will use the AssemblyQualifiedName rather than just the name of the type.
     - Fixed a bug so that collection.Should().OnlyContain(lamba) now throws if the collection is empty. See this discussion for more details.
     - Minor fix that ignores trailing blank characters when looking for the 'because' text in the reason of an assertion.
     - Added better and deeper detection of cyclic references when recursively comparing properties or generating a string representation of a complex object graph.
     - For long strings, the error message for string.Should().StartWith() places the actual and expected strings on seperate lines. This makes it easier to find the differences.