// ReSharper disable once InconsistentNaming public async Task GetEpisodesByShowIdAsync_should_return_empty_array_with_showId_that_does_not_exist() { using (var context = CreateContext()) { await SeedEpisodesAsync(context); var repository = new EpisodeRepository(context); int showId = 0; var episodes = await repository.GetEpisodesByShowIdAsync(showId); Assert.Equal(0, episodes.Length); } }
// ReSharper disable once InconsistentNaming public async Task GetEpisodesByShowIdAsync_should_return_episodes_with_a_given_showId() { using (var context = CreateContext()) { await SeedEpisodesAsync(context); var repository = new EpisodeRepository(context); int showId = 100; var episodes = await repository.GetEpisodesByShowIdAsync(showId); Assert.Equal(1, episodes.Length); Assert.Equal(showId, episodes.First().ShowId); } }