public async Task PartService_ShouldDeleteCorrectlyPart() { //Arrange var db = DatabaseInitializer.GetDbForPartService(); var service = new PartService(db); //Act await service.Delete(1); //Assert db.Parts.Should().HaveCount(1); }
public async Task <IActionResult> Delete(int id) { return(Ok(partService.Delete(id))); }