public void GetBaseValue_LocalValue_Returns_Style_Value() { var target = new Class3(); target.SetValue(Class1.FooProperty, "style", BindingPriority.Style); target.SetValue(Class1.FooProperty, "animated", BindingPriority.Animation); Assert.Equal("style", target.GetBaseValue(Class1.FooProperty, BindingPriority.LocalValue).Value); }
public void GetBaseValue_Style_Returns_Style_Value() { var target = new Class3(); target.SetValue(Class1.FooProperty, "local"); target.SetValue(Class1.FooProperty, "style", BindingPriority.Style); target.Bind(Class1.FooProperty, new BehaviorSubject <string>("animated"), BindingPriority.Animation); Assert.Equal("style", target.GetBaseValue(Class1.FooProperty, BindingPriority.Style)); }
public void Validation_Can_Be_Overridden_With_Null() { var target = new Class3(); target.SetValue(Class1.QuxProperty, 50); Assert.Equal(50, target.GetValue(Class1.QuxProperty)); }
public void GetBaseValue_LocalValue_Ignores_Default_Value() { var target = new Class3(); target.SetValue(Class1.FooProperty, "animated", BindingPriority.Animation); Assert.False(target.GetBaseValue(Class1.FooProperty, BindingPriority.LocalValue).HasValue); }
public void GetBaseValue_Style_Ignores_LocalValue_Animated_Value() { var target = new Class3(); target.Bind(Class1.FooProperty, new BehaviorSubject <string>("animated"), BindingPriority.Animation); target.SetValue(Class1.FooProperty, "local"); Assert.False(target.GetBaseValue(Class1.FooProperty, BindingPriority.Style).HasValue); }