Ejemplo n.º 1
0
        public ActionResult <CompleteMedicalAppointmentResponse> PutComplete(CompleteMedicalAppointmentRequest request)
        {
            var service  = new CompleteMedicalAppointmentService(_unitOfWork);
            var response = service.Ejecute(request);

            return(Ok(response));
        }
Ejemplo n.º 2
0
        public void CompleteMedicalAppointmentTest()
        {
            var requestA = new RegisterMedicalAppointmentRequest
            {
                Doctor = new Doctor {
                    Id = "4444"
                }, Patient = new Patient {
                    Id = "1004", Stratum = 4
                },
                Date = DateTime.Now.AddDays(5)
            };
            var serviceA = new RegisterMedicalAppointmentService(new UnitOfWork(_context));

            serviceA.Ejecute(requestA);

            var request = new CompleteMedicalAppointmentRequest {
                Identification = 1
            };
            var service  = new CompleteMedicalAppointmentService(new UnitOfWork(_context));
            var response = service.Ejecute(request);

            Assert.AreEqual("Cita medica completada satisfactoriamente", response.Mensaje);
        }