public void BodyExpressionWorksWithDefaultConstructor() { // Arrange & Act var body = new BodyExpression(); // Assert Assert.Equal("body", body.Expression); }
public Distinctions Compare <T1>(T1 expected, T1 actual, string propertyName) { var a = (T)(object)expected; var b = (T)(object)actual; return(CompareFunc.Compile()(a, b) ? Distinctions.None() : Distinctions.Create(new[] { _display.GetDistinction(a, b, propertyName, BodyExpression.Get(CompareFunc).ToString()) })); }
public void BodyExpressionConstructorCreateCorrectBodyExpression() { // Arrange string expression = "#/user/uuid"; JsonPointer pointer = new JsonPointer(expression); // Act var body = new BodyExpression(pointer); // Assert Assert.Equal("body#/user/uuid", body.Expression); Assert.Equal("/user/uuid", body.Fragment); }