public void can_cast_to_simple_property() { var target = new TargetSimplistProperty(); var proxy = Duck.Cast <ISimplistProperty>(target); proxy.Value = 2; Assert.AreEqual(2, target.Value); }
public void can_cast_to_simple_generic_interface_with_property() { var target = new TargetSimplistProperty(); var proxy = Duck.Cast <ISimplistProperty <int> >(target); proxy.Value = 2; Assert.AreEqual(2, target.Value); }
public static void can_cast_to_simple_property(Test t) { var target = new TargetSimplistProperty(); var proxy = Duck.Cast <ISimplistProperty>(target); proxy.Value = 2; t.Assert(2, target.Value); }