Skip to content

Instantly share code, notes, and snippets.

@plioi plioi/Assertions.cs
Created Jan 27, 2016

Embed
What would you like to do?
public static class Assertions
{
public static void ShouldMatch<T>(this T actual, T expected)
=> Json(actual).ShouldEqual(Json(expected), "Expected two objects to match on all properties.");
private static string Json<T>(T actual)
=> JsonConvert.SerializeObject(actual, Formatting.Indented);
...
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.