public void Change_Property_From_Value_To_Null_Should_Not_Throw() { var trackable = new Order { Id = 321, Address = new Address() }.AsTrackable(); trackable.Invoking(o => o.Address = null).Should().NotThrow <NullReferenceException>(); }
public void When_AsTrackable_CastToIChangeTrackable_Should_Not_Throw_InvalidCastException() { var order = Helper.GetOrder(); Order trackable = order.AsTrackable(); trackable.Invoking(o => o.CastToIChangeTrackable()).Should().NotThrow <InvalidCastException>(); }
public void Change_Property_From_Null_To_Value_Should_Not_Throw() { var trackable = new Order { Id = 321, CustomerNumber = null }.AsTrackable(); trackable.Invoking(o => o.CustomerNumber = "Test").Should().NotThrow <NullReferenceException>(); }
public void Change_Property_From_Null_To_Value_Should_Not_Throw() { var trackable = new Order { Id = 321, CustomerNumber = null }.AsTrackable(); trackable.Invoking(o => o.CustomerNumber = "Test").ShouldNotThrow<NullReferenceException>(); }