public void SetProperty_WithSameValue_ShouldNotRaiseNotifyPropertyChanged( SampleBindable sut, string value1) { //arrange sut.Property = value1; sut.MonitorEvents(); //act sut.Property = value1; //assert sut.ShouldNotRaise("PropertyChanged"); }
public void SetProperty_WithNewValue_ShouldRaiseNotifyPropertyChanged( SampleBindable sut, string value1, string value2) { //arrange sut.Property = value1; sut.MonitorEvents(); //act sut.Property = value2; //assert sut.ShouldRaise("PropertyChanged").WithArgs<PropertyChangedEventArgs>(arg => arg.PropertyName == "Property"); }
public void SetProperty_WithNewValue_ShouldRaiseNotifyPropertyChanged( SampleBindable sut, string value1, string value2) { //arrange sut.Property = value1; sut.MonitorEvents(); //act sut.Property = value2; //assert sut.ShouldRaise("PropertyChanged").WithArgs <PropertyChangedEventArgs>(arg => arg.PropertyName == "Property"); }