public void EditShouldReturnFalseIfItIsNotSuccessfull() { // Arrange var beerService = new AdminBeerService(this.db); // Act var result = beerService.Edit(2, "test", 2m, 1, "test", 2, 2, "", BeerColor.Amber, 1, 2, 3, 2, 1, 1); // Assert result .Should() .BeFalse(); }
public void EditShouldReturnTrueIfItIsSuccessfull() { // Arrange var beer = new Beer { Id = 1, Name = "Test" }; this.db.Beers.Add(beer); this.db.SaveChanges(); var beerService = new AdminBeerService(this.db); // Act var result = beerService.Edit(1, "test", 2m, 1, "test", 2, 2, "", BeerColor.Amber, 1, 2, 3, 2, 1, 1); // Assert result .Should() .BeTrue(); }