public void SettingTheSameValueDoesNotRaisePropertyChangedEvents() { _formStore.Handle( new UpdateFormAction( "test-form", FormUpdate.FieldValue("test-field", _field.Value) ) ); AssertCollections( _storePropertyChanges, new[] { nameof(IFormStore.Forms) } ); AssertCollections( _formPropertyChanges, new[] { nameof(IFormData.Fields) } ); Assert.False(_fieldPropertyChanges.Any()); }
public void UpdatingAFormFieldValueSetsItsValue() { var value = new object(); _formStore.Handle( new UpdateFormAction( "test-form", FormUpdate.FieldValue("test-field", value) ) ); Assert.Same(value, _form["test-field"].Value); AssertCollections( _storePropertyChanges, new[] { nameof(IFormStore.Forms), "Items['test-form']['test-field'].Value" } ); AssertCollections( _formPropertyChanges, new[] { nameof(IFormData.Fields), "Items['test-field'].Value" } ); AssertCollections( _fieldPropertyChanges, new[] { nameof(IFormFieldData.Value) } ); }