public void partial_update_updates_value() { var newName = "updated name"; var updateId = 4; var model = new JsonPatchDocument <ValueUpdateDto>(); model.Add("Name", newName); var updated = _fcd.Update(updateId, model).Result; updated.Name.ShouldBe(newName); var value = _fcd.Get(updateId).Result; value.Name.ShouldBe(newName); }
public async Task <IHttpActionResult> Put(int id, [FromBody] ValueWriteDto value) { var updated = _valuesFcd.Update(id, value); return(Ok(await updated)); }