public void GetNextStepStatistic()
        {
            EventStorePatientStepSchedulingService eventStepService         = SetupEventStepService();
            SchedulingStepsStatisticDTO            schedulingStepsStatistic = eventStepService.SchedulingStepsStatistic();

            Assert.Equal(7, schedulingStepsStatistic.NumberOfNextSteps);
        }
        public void GetNumberOfPreviousOnAppointmentStep()
        {
            EventStorePatientStepSchedulingService eventStepService = SetupEventStepService();
            StepPreviousStatisticDTO stepStatistic = eventStepService.PreviousSchedulingStepStatistic();

            Assert.Equal(1, stepStatistic.NumberOfPreviousOnAppointmentStep);
        }
        public void GetClosedStepStatistic()
        {
            EventStorePatientStepSchedulingService eventStepService = SetupEventStepService();
            StepClosureStatisticDTO stepStatistic = eventStepService.ClosedSchedulingStepStatistic();

            Assert.Equal(3, stepStatistic.TotalNumberOfClosures);
        }
        public void GetPreviousStepStatistic()
        {
            EventStorePatientStepSchedulingService eventStepService = SetupEventStepService();
            StepPreviousStatisticDTO stepStatistic = eventStepService.PreviousSchedulingStepStatistic();

            Assert.Equal(4, stepStatistic.TotalNumberOfPrevious);
        }
        public void SuccessGetAllStepEvent()
        {
            EventStorePatientStepSchedulingService   eventStepService = SetupEventStepService();
            IEnumerable <PatientStepSchedulingEvent> stepEvents       = eventStepService.GetAll();

            Assert.NotEmpty(stepEvents);
        }
        public void GetMostClosedStep()
        {
            EventStorePatientStepSchedulingService eventStepService = SetupEventStepService();
            StepClosureStatisticDTO stepStatistic = eventStepService.ClosedSchedulingStepStatistic();

            Assert.Equal(EventStep.Specialty, stepStatistic.MostClosedStep);
        }
        public void GetNumberOfClosuresOnDoctorStep()
        {
            EventStorePatientStepSchedulingService eventStepService = SetupEventStepService();
            StepClosureStatisticDTO stepStatistic = eventStepService.ClosedSchedulingStepStatistic();

            Assert.Equal(1, stepStatistic.NumberOfClosuresOnDoctorStep);
        }
        public void GetMostReturnedStep()
        {
            EventStorePatientStepSchedulingService eventStepService = SetupEventStepService();
            StepPreviousStatisticDTO stepStatistic = eventStepService.PreviousSchedulingStepStatistic();

            Assert.Equal(EventStep.Doctor, stepStatistic.MostReturnedStep);
        }
        public void SuccessAddNewStepEvent()
        {
            EventStorePatientStepSchedulingService eventStepService = SetupEventStepService();
            PatientStepSchedulingEvent             stepEvent        = eventStepService.Add(new PatientStepSchedulingEventDTO()
            {
                TriggerTime = DateTime.Now, StartSchedulingEventId = 1, UserAge = 35, UserGender = EventSourcingService.Model.Enum.Gender.Female, EventStep = EventSourcingService.Model.Enum.EventStep.Date, ClickEvent = EventSourcingService.Model.Enum.ClickEvent.Next
            });

            Assert.True(eventStepService.Contain(stepEvent.Id));
        }