public void Bind_Field() { var binding = MemberBinding.Bind(Field, AssociatedExpression); Assert.That(binding, Is.InstanceOf(typeof(FieldInfoBinding))); Assert.That(binding.BoundMember, Is.SameAs(Field)); Assert.That(binding.AssociatedExpression, Is.SameAs(AssociatedExpression)); }
public void Bind_Property() { var binding = MemberBinding.Bind(Property, AssociatedExpression); Assert.That(binding, Is.InstanceOf(typeof(PropertyInfoBinding))); Assert.That(binding.BoundMember, Is.SameAs(Property)); Assert.That(binding.AssociatedExpression, Is.SameAs(AssociatedExpression)); }