public async Task GetAllSchedules_SchedulesFound_ShouldReturnOkStatus()
        {
            //Arrange
            var data = FakeData();

            scheduleBusiness.Setup(x => x.GetSchedules(It.IsAny <Guid>())).ReturnsAsync(data);

            //Act
            var mockresponse = await controller.GetAllSchedules() as OkObjectResult;

            var list = mockresponse.Value as IList <ScheduleResponse>;

            //Assert
            Assert.Equal(data.First().Name, list.First().Name);
        }
        private void BindSchedules()
        {
            var schedules = scheduleController.GetAllSchedules();

            foreach (var s in schedules)
            {
                ddlSchedules.Items.Add(new ListItem(s.Name, s.ScheduleID.ToString()));
            }
        }
 private void BindSchedules()
 {
     dgSchedules.AddEnabled         = editEnabled;
     dgSchedules.AddImageUrl        = "~/images/add_activity.gif";
     dgSchedules.BulkUpdateEnabled  = false;
     dgSchedules.DeleteEnabled      = editEnabled;
     dgSchedules.EditEnabled        = false;
     dgSchedules.ExportEnabled      = true;
     dgSchedules.MailEnabled        = true;
     dgSchedules.MergeEnabled       = false;
     dgSchedules.MoveEnabled        = false;
     dgSchedules.PersonMergeEnabled = false;
     dgSchedules.SMSEnabled         = false;
     dgSchedules.DataSource         = scheduleController.GetAllSchedules();
     dgSchedules.DataBind();
 }