public void GetCalendarsInLibrary_ShouldntReturnDeletedCalendars() { var expectedCalendars = new List <Calendar>(); for (int i = 0; i < 3; ++i) { var calendar = CreateAndRetrieveCalendar(); expectedCalendars.Add(calendar); } var deletedCalendar = CreateAndRetrieveCalendar(); repository.DeleteCalendar(deletedCalendar.CalendarId); var calendars = repository.GetCalendarsInLibrary(testLibrary.LibraryId, GetFirstPage(), "").Result.Results; CollectionAssert.AreEquivalent(expectedCalendars, calendars); }
public async Task <PaginationResult <Calendar> > GetCalendarsInLibrary(Pagination pagination, long libraryId, string nameFilter) { return(await calendarRepository.GetCalendarsInLibrary(libraryId, pagination, nameFilter)); }