public void SettingFacadeIntPropertyUpdatesDependencyIntProperty() { var expectedResult = 999; var facade = new FacadeModel(new BaseModel()); facade.IntProperty = expectedResult; Assert.Equal(expectedResult, facade.Dependency.IntProperty); }
public void SettingAnotherStringPropertyUpdatesTheDependencyStringProperty() { var expectedResult = "New String Value"; var facade = new FacadeModel(new BaseModel()); facade.AnotherStringProperty = expectedResult; Assert.Equal(expectedResult, facade.Dependency.StringProperty); }
public void AnotherStringPropertyOnFacadeReturnsBaseModelStringPropertyDefaultValueTest() { var model = new BaseModel(); var expectedResult = model.StringProperty; var facade = new FacadeModel(model); Assert.Equal(expectedResult, facade.AnotherStringProperty); }
public void IntPropertyOnWeavedFacadeReturnsBaseModelIntPropertyDefaultValueTest() { var model = new BaseModel(); var expectedResult = model.IntProperty; var facade = new FacadeModel(model); Assert.Equal(expectedResult, facade.IntProperty); }
public void FacadeAnotherStringPropertyChangedEventFiresOnAssignementTest() { var expectedPropertyChanged = "AnotherStringProperty"; var resultPropertyChanged = string.Empty; var facade = new FacadeModel(new BaseModel()); var obj = (INotifyPropertyChanged)facade; obj.PropertyChanged += (sender, args) => resultPropertyChanged = args.PropertyName; facade.AnotherStringProperty = "Some New Value"; Assert.Equal(expectedPropertyChanged, resultPropertyChanged); }
public void FacadeIntPropertyChangedEventFiresOnAssignmentTest() { var expectedPropertyChanged = "IntProperty"; var resultPropertyChanged = string.Empty; var facade = new FacadeModel(new BaseModel()); var obj = (INotifyPropertyChanged)facade; obj.PropertyChanged += (sender, args) => resultPropertyChanged = args.PropertyName; facade.IntProperty = 999; Assert.Equal(expectedPropertyChanged, resultPropertyChanged); }