Fluent Assertions MVC

FluentAssertions MVC is a set of MVC focused assertions and helper extensions to the excellent FluentAssertions library.

Status: Beta Release


What is this?

This is a .Net library for ASP.NET MVC focused assertions in Unit Tests. It is dependent on the core FluentAssertions library.

Assertions are written with fluent method chaining:

Example Incoming Route Assertions
public void IncomingDefaultRoute_GivenValidRoute_ShouldReturnExpected()
     var routes = GetRoutes();  //Get Routes from MvcApplication

     var routeData = routes.GetRouteDataForUrl("product/view/444");
              .HaveValue("Id", "444")
              .HaveDataToken("Area", "products");

Why should I use it?

1. Rich Fluent API that is MVC focused
2. MVC Testing Helper Methods
3. Test Framework Agnostic
4. Meaningful Failure Messages
5. Human Readable Test Assertions


0.2.0 - 28th August 2013
  • Added Xml comments.
  • Fluent Assertions dependency upgraded to v2.1.

0.1.0 - 15th February 2013
  • Initial preview release.

Last edited Aug 28, 2013 at 2:44 PM by KevinKuszyk, version 21