public async Task ComicUseCaseTest_GetListAsync_Success() { // Arrange var comicInput = ComicInputFaker.Create().Generate(); var comicDataWrapper = ComicDataWrapperFaker.Create().Generate(); // Setup _comicRepository .Setup(p => p.GetComicsByCharacter(1, comicInput)) .Returns(Task.FromResult(comicDataWrapper)); // Act var result = await _comicUseCase.GetListAsync(1, comicInput); //Assert Assert.True(result.Data.Results.Any()); }
public async Task <IActionResult> GetCharacterComics(ApiVersion apiVersion, int characterId, [FromQuery] ComicInput comicInput) { return(Ok(await _comicUseCase.GetListAsync(characterId, comicInput))); }