public async Task SearchAnime_NonEmptyQuery_ShouldReturnNotNullSearchAnime(string query) { // When AnimeSearchResult returnedAnime = await _jikan.SearchAnime(query); // Then returnedAnime.Should().NotBeNull(); }
public async Task SearchAnime_TVConfig_ShouldReturnNotNullSearchAnime(string query) { // Given var searchConfig = new AnimeSearchConfig { Type = AnimeType.TV }; // When AnimeSearchResult returnedAnime = await _jikan.SearchAnime(query, searchConfig); // Then returnedAnime.Should().Be(returnedAnime); }
public async Task SearchAnime_OneQueryActionCompletedAnimeSecondPage_ShouldReturnNotEmptyCollection() { // Given var searchConfig = new AnimeSearchConfig { Status = AiringStatus.Completed, Genres = new List <GenreSearch> { GenreSearch.Action } }; // When AnimeSearchResult returnedAnime = await _jikan.SearchAnime("one", 2, searchConfig); // Then using (new AssertionScope()) { returnedAnime.Should().NotBeNull(); returnedAnime.Results.Should().NotBeEmpty(); } }
public async Task SearchAnime_GenreExclusion_ShouldReturnNotEmptyCollection() { // Given var searchConfig = new AnimeSearchConfig { Genres = new List <GenreSearch> { GenreSearch.Action, GenreSearch.Adventure }, GenreIncluded = false, OrderBy = AnimeSearchSortable.Score, SortDirection = SortDirection.Descending }; // When AnimeSearchResult returnedAnime = await _jikan.SearchAnime(searchConfig); // Then using (new AssertionScope()) { returnedAnime.Should().NotBeNull(); returnedAnime.Results.Should().NotBeEmpty(); } }