public async Task <DataBase.ViewModels.Hospital> UpdateAsync( [FromRoute] int id, [FromBody] DataBase.Models.Hospital hospital, CancellationToken ct ) { var result = await _hospitalServices.UpdateAsync(id, hospital, ct); return(result.ToViewModel()); }
public async Task UpdateTestAsync() { var hospital = await business.UpdateAsync( 1, new Hospital() { Nome = "S.Joao" }, CancellationToken.None ); Assert.AreEqual(hospital.Nome, "S.Joao"); }