Mercurial > hg > orthanc
comparison UnitTestsSources/ServerIndexTests.cpp @ 1023:226cfef3822e templating
integration mainline->templating
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Thu, 10 Jul 2014 11:42:32 +0200 |
parents | 649d47854314 |
children | 9e04f9f36096 |
comparison
equal
deleted
inserted
replaced
945:427a1f996b7b | 1023:226cfef3822e |
---|---|
577 DicomMap instance; | 577 DicomMap instance; |
578 instance.SetValue(DICOM_TAG_PATIENT_ID, "patient-" + id); | 578 instance.SetValue(DICOM_TAG_PATIENT_ID, "patient-" + id); |
579 instance.SetValue(DICOM_TAG_STUDY_INSTANCE_UID, "study-" + id); | 579 instance.SetValue(DICOM_TAG_STUDY_INSTANCE_UID, "study-" + id); |
580 instance.SetValue(DICOM_TAG_SERIES_INSTANCE_UID, "series-" + id); | 580 instance.SetValue(DICOM_TAG_SERIES_INSTANCE_UID, "series-" + id); |
581 instance.SetValue(DICOM_TAG_SOP_INSTANCE_UID, "instance-" + id); | 581 instance.SetValue(DICOM_TAG_SOP_INSTANCE_UID, "instance-" + id); |
582 ASSERT_EQ(StoreStatus_Success, index.Store(instance, attachments, "")); | 582 |
583 std::map<MetadataType, std::string> instanceMetadata; | |
584 ServerIndex::MetadataMap metadata; | |
585 ASSERT_EQ(StoreStatus_Success, index.Store(instanceMetadata, instance, attachments, "", metadata)); | |
586 ASSERT_EQ(2, instanceMetadata.size()); | |
587 ASSERT_NE(instanceMetadata.end(), instanceMetadata.find(MetadataType_Instance_RemoteAet)); | |
588 ASSERT_NE(instanceMetadata.end(), instanceMetadata.find(MetadataType_Instance_ReceptionDate)); | |
583 | 589 |
584 DicomInstanceHasher hasher(instance); | 590 DicomInstanceHasher hasher(instance); |
585 ids.push_back(hasher.HashPatient()); | 591 ids.push_back(hasher.HashPatient()); |
586 ids.push_back(hasher.HashStudy()); | 592 ids.push_back(hasher.HashStudy()); |
587 ids.push_back(hasher.HashSeries()); | 593 ids.push_back(hasher.HashSeries()); |