public async Task <List <Directory> > GetDirectoryData() { var phoneBook = await _phoneBookService.GetData(); var entryBook = await _entryBookService.GetData(); return(PhoneBookMapper.Map(phoneBook, entryBook)); }
public async Task Get_ShouldReturnEntryBook() { var entryBook = FakeObjects.FakeObjects.GetListEntryBook(); _entryBookService.GetData().Returns(entryBook); var actionResult = await _sut.Get(); actionResult.Value.Equals(entryBook); }
public async Task GetData_ShouldReturnEntries() { var entryBook = FakeObjects.FakeObjects.GetListEntryBook(); _entryBookRepo.GetData().Returns(entryBook); var result = await _sut.GetData(); Assert.NotNull(result); result.Should().Equal(entryBook); }
public async Task <ActionResult <List <EntryBookDto> > > Get() { return(await _entryBookService.GetData()); }