예제 #1
0
 public void AddStepToCaseStatCaseWithLaboratoryReportMin()
 {
     using (TestPixServiceClient c = new TestPixServiceClient())
     {
         PatientDto patient = (new SetData()).PatientSet();
         c.AddPatient(Global.GUID, Data.idlpu, patient);
     }
     using (TestEmkServiceClient client = new TestEmkServiceClient())
     {
         CaseStat caseStat = (new SetData()).MinCaseStatSetForCreate();
         client.CreateCase(Global.GUID, caseStat);
         StepStat stepStat = (new SetData()).MinStepStatSet();
         stepStat.MedRecords = new List <MedRecord>
         {
             (new SetData()).MinLaboratoryReport()
         };
         client.AddStepToCase(Global.GUID, Data.idlpu, caseStat.IdPatientMis, caseStat.IdCaseMis, stepStat);
     }
     if (Global.errors == "")
     {
         Assert.Pass();
     }
     else
     {
         Assert.Fail(Global.errors);
     }
 }
예제 #2
0
        public void AddStepToCaseAmbCaseWithAppointedMedicationMin()
        {
            using (TestPixServiceClient c = new TestPixServiceClient())
            {
                PatientDto patient = (new SetData()).PatientSet();
                c.AddPatient(Global.GUID, Data.idlpu, patient);
            }
            using (TestEmkServiceClient client = new TestEmkServiceClient())
            {
                CaseAmb caseAmb = (new SetData()).MinCaseAmbSetForCreate();
                client.CreateCase(Global.GUID, caseAmb);
                StepAmb stepAmb = (new SetData()).MinStepAmbSet();
                stepAmb.MedRecords = new List <MedRecord>
                {
                    (new  SetData()).MinAppointedMedication()
                };

                client.AddStepToCase(Global.GUID, Data.idlpu, caseAmb.IdPatientMis, caseAmb.IdCaseMis, stepAmb);
            }
            if (Global.errors == "")
            {
                Assert.Pass();
            }
            else
            {
                Assert.Fail(Global.errors);
            }
        }
예제 #3
0
        public void AddAmbStep_SameIdMin()
        {
            using (TestPixServiceClient PixClient = new TestPixServiceClient())
            {
                PatientDto patient = (new SetData()).PatientSet();
                PixClient.AddPatient(Global.GUID, Data.idlpu, patient);
            }
            using (TestEmkServiceClient EmkClient = new TestEmkServiceClient())
            {
                CaseAmb caseAmb = (new SetData()).MinCaseAmbSetForCreate();
                EmkClient.CreateCase(Global.GUID, caseAmb);

                StepAmb stepAmb = (new SetData()).MinOtherStepAmbSet();
                stepAmb.IdStepMis = CaseAmbData.step.IdStepMis;
                EmkClient.AddStepToCase(Global.GUID, Data.idlpu, caseAmb.IdPatientMis, caseAmb.IdCaseMis, stepAmb);
            }
            if (Global.errors == "")
            {
                Assert.Pass();
            }
            else
            {
                Assert.Fail(Global.errors);
            }
        }
예제 #4
0
        public void AddAmbStep_OtherIdFull()
        {
            using (TestPixServiceClient PixClient = new TestPixServiceClient())
            {
                PatientDto patient = (new SetData()).PatientSet();
                PixClient.AddPatient(Global.GUID, Data.idlpu, patient);
            }
            using (TestEmkServiceClient EmkClient = new TestEmkServiceClient())
            {
                CaseAmb caseAmb = (new SetData()).MinCaseAmbSetForCreate();
                EmkClient.CreateCase(Global.GUID, caseAmb);

                StepAmb stepAmb = CaseAmbData.otherStep;
                stepAmb.MedRecords = new List <MedRecord>
                {
                    (new SetData()).MinService(),
                    (new SetData()).MinAppointedMedication(),
                    (new SetData()).MinDiagnosis(),
                    MedRecordData.clinicMainDiagnosis,
                    MedRecordData.referral,
                    (new SetData()).MinLaboratoryReport()
                };
                EmkClient.AddStepToCase(Global.GUID, Data.idlpu, caseAmb.IdPatientMis, caseAmb.IdCaseMis, stepAmb);
            }
            if (Global.errors == "")
            {
                Assert.Pass();
            }
            else
            {
                Assert.Fail(Global.errors);
            }
        }
예제 #5
0
파일: UnitTest1.cs 프로젝트: nbIxMaN/EMKT
 public void _CreateStatCase()
 {
     using (TestPixServiceClient PixClient = new TestPixServiceClient())
     {
         PatientDto patient = (new SetData()).PatientSet();
         PixClient.AddPatient(Global.GUID, "1.2.643.5.1.13.3.25.78.118", patient);
     }
     using (TestEmkServiceClient EmkClient = new TestEmkServiceClient())
     {
         CaseStat caseStat = (new SetData()).FullCaseStatSetForCreate();
         caseStat.Guardian = null;
         caseStat.OpenDate = new DateTime(2014, 06, 01);
         SetData  set      = new SetData();
         StepStat stepStat = (new SetData()).MinStepStatSet();
         caseStat.Steps = new List <StepStat>
         {
             stepStat
         };
         caseStat.Steps[0].DateStart = new DateTime(2014, 06, 01);
         caseStat.Steps[0].DateEnd   = new DateTime(2014, 06, 04);
         EmkClient.CreateCase(Global.GUID, caseStat);
         StepStat s = CaseStatData.otherStep;
         s.MedRecords = new List <MedRecord>
         {
             MedRecordData.appointedMedication,
             MedRecordData.service
         };
         s.DateStart = new DateTime(2014, 06, 05);
         s.DateEnd   = new DateTime(2014, 06, 10);
         EmkClient.AddStepToCase(Global.GUID, caseStat.IdLpu, caseStat.IdPatientMis, caseStat.IdCaseMis, s);
         caseStat            = (new SetData()).FullCaseStatSetForClose();
         caseStat.Guardian   = null;
         caseStat.CloseDate  = new DateTime(2014, 06, 10);
         caseStat.MedRecords = new List <MedRecord>
         {
             MedRecordData.clinicMainDiagnosis,
             GetEpic()
         };
         EmkClient.CloseCase(Global.GUID, caseStat);
     }
     if (Global.errors == "")
     {
         Assert.Pass();
     }
     else
     {
         Assert.Fail(Global.errors);
     }
 }
예제 #6
0
        public void AddAmbStep_CloseCase()
        {
            using (TestPixServiceClient PixClient = new TestPixServiceClient())
            {
                PatientDto patient = (new SetData()).PatientSet();
                PixClient.AddPatient(Global.GUID, Data.idlpu, patient);
            }
            using (TestEmkServiceClient EmkClient = new TestEmkServiceClient())
            {
                CaseAmb caseAmb = (new SetData()).MinCaseAmbSet();
                EmkClient.AddCase(Global.GUID, caseAmb);

                StepAmb stepAmb = (new SetData()).MinStepAmbSet();

                EmkClient.AddStepToCase(Global.GUID, Data.idlpu, caseAmb.IdPatientMis, caseAmb.IdCaseMis, stepAmb);
            }
            Assert.IsTrue(Global.errors1.Contains(" - Случай обслуживания закрыт"), "Случай обслуживания был добавлен");
        }
예제 #7
0
        public void AddStatStep_OtherIdMin()
        {
            using (TestPixServiceClient PixClient = new TestPixServiceClient())
            {
                PatientDto patient = (new SetData()).PatientSet();
                PixClient.AddPatient(Global.GUID, Data.idlpu, patient);
            }
            using (TestEmkServiceClient EmkClient = new TestEmkServiceClient())
            {
                CaseStat caseStat = (new SetData()).MinCaseStatSetForCreate();
                EmkClient.CreateCase(Global.GUID, caseStat);

                StepStat stepStat = (new SetData()).MinOtherStepStatSet();
                EmkClient.AddStepToCase(Global.GUID, Data.idlpu, caseStat.IdPatientMis, caseStat.IdCaseMis, stepStat);
            }
            if (Global.errors == "")
            {
                Assert.Pass();
            }
            else
            {
                Assert.Fail(Global.errors);
            }
        }
예제 #8
0
        public void AddStepToCaseStatCaseWithAppointedMedicationMin()
        {
            using (TestPixServiceClient c = new TestPixServiceClient())
            {
                PatientDto patient = (new SetData()).PatientSet();
                c.AddPatient(Global.GUID, Data.idlpu, patient);
            }
            using (TestEmkServiceClient client = new TestEmkServiceClient())
            {
                CaseStat caseStat = (new SetData()).MinCaseStatSetForCreate();
                client.CreateCase(Global.GUID, caseStat);
                StepStat stepStat = (new SetData()).MinStepStatSet();
                stepStat.MedRecords = new List<MedRecord>
                {
                    (new  SetData()).MinAppointedMedication()
                };

                client.AddStepToCase(Global.GUID, Data.idlpu, caseStat.IdPatientMis, caseStat.IdCaseMis, stepStat);
            }
            if (Global.errors == "")
                Assert.Pass();
            else
                Assert.Fail(Global.errors);
        }
예제 #9
0
 public void AddStepToCaseAmbCaseWithLaboratoryReportMin()
 {
     using (TestPixServiceClient c = new TestPixServiceClient())
     {
         PatientDto patient = (new SetData()).PatientSet();
         c.AddPatient(Global.GUID, Data.idlpu, patient);
     }
     using (TestEmkServiceClient client = new TestEmkServiceClient())
     {
         CaseAmb caseAmb = (new SetData()).MinCaseAmbSetForCreate();
         client.CreateCase(Global.GUID, caseAmb);
         StepAmb stepAmb = (new SetData()).MinStepAmbSet();
         stepAmb.MedRecords = new List<MedRecord>
         {
             (new SetData()).MinLaboratoryReport()
         };
         client.AddStepToCase(Global.GUID, Data.idlpu, caseAmb.IdPatientMis, caseAmb.IdCaseMis, stepAmb);
     }
     if (Global.errors == "")
         Assert.Pass();
     else
         Assert.Fail(Global.errors);
 }
예제 #10
0
파일: UnitTest1.cs 프로젝트: nbIxMaN/EMKT
 public void _CreateStatCase()
 {
     using (TestPixServiceClient PixClient = new TestPixServiceClient())
     {
         PatientDto patient = (new SetData()).PatientSet();
         PixClient.AddPatient(Global.GUID, "1.2.643.5.1.13.3.25.78.118", patient);
     }
     using (TestEmkServiceClient EmkClient = new TestEmkServiceClient())
     {
         CaseStat caseStat = (new SetData()).FullCaseStatSetForCreate();
         caseStat.Guardian = null;
         caseStat.OpenDate = new DateTime(2014, 06, 01);
         SetData set = new SetData();
         StepStat stepStat = (new SetData()).MinStepStatSet();
         caseStat.Steps = new List<StepStat>
         {
             stepStat
         };
         caseStat.Steps[0].DateStart = new DateTime(2014, 06, 01);
         caseStat.Steps[0].DateEnd = new DateTime(2014, 06, 04);
         EmkClient.CreateCase(Global.GUID, caseStat);
         StepStat s = CaseStatData.otherStep;
         s.MedRecords = new List<MedRecord>
         {
             MedRecordData.appointedMedication,
             MedRecordData.service
         };
         s.DateStart = new DateTime(2014, 06, 05);
         s.DateEnd = new DateTime(2014, 06, 10);
         EmkClient.AddStepToCase(Global.GUID, caseStat.IdLpu, caseStat.IdPatientMis, caseStat.IdCaseMis, s);
         caseStat = (new SetData()).FullCaseStatSetForClose();
         caseStat.Guardian = null;
         caseStat.CloseDate = new DateTime(2014, 06, 10);
         caseStat.MedRecords = new List<MedRecord>
         {
             MedRecordData.clinicMainDiagnosis,
             GetEpic()
         };
         EmkClient.CloseCase(Global.GUID, caseStat);
     }
     if (Global.errors == "")
         Assert.Pass();
     else
         Assert.Fail(Global.errors);
 }