public void DeleteTourVariantSuccessful() { mockUnit.Setup(x => x.TourVariants.Get(It.IsAny <int>())).Returns(fixture.TourVariant); mockUnit.Setup(x => x.TourVariants.Delete(It.IsAny <TourVariant>())); mockUnit.Setup(x => x.Save()); service.DeleteTourVariant(1); mockUnit.VerifyAll(); }
public IHttpActionResult DeleteTourVariant(int id) { tourVariantService.DeleteTourVariant(id); return(StatusCode(HttpStatusCode.NoContent)); }