public void AllGenres_Empty_RetunsAllGenresFromDatabase() { var genres = new List <Genre> { new Genre { Id = Guid.NewGuid() }, new Genre { Id = Guid.NewGuid() } }; _context.Genres.AddRange(genres); _context.SaveChanges(); var results = _inventoryService.AllGenres(); Assert.AreEqual(genres.Count, results.Count); }
public void AllGenres_Empty_CallsRepoGet() { _inventoryService.AllGenres(); _genreRepository.Verify(x => x.Get(), Times.AtLeastOnce); }