Mercurial > hg > orthanc
comparison UnitTestsSources/ServerIndexTests.cpp @ 1822:9ed9458aa44f
refactoring
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Wed, 25 Nov 2015 10:06:50 +0100 |
parents | 9ead18ef460a |
children | 0ef4e6e66b56 |
comparison
equal
deleted
inserted
replaced
1821:580951a33583 | 1822:9ed9458aa44f |
---|---|
794 instance.SetValue(DICOM_TAG_STUDY_INSTANCE_UID, "study-" + id); | 794 instance.SetValue(DICOM_TAG_STUDY_INSTANCE_UID, "study-" + id); |
795 instance.SetValue(DICOM_TAG_SERIES_INSTANCE_UID, "series-" + id); | 795 instance.SetValue(DICOM_TAG_SERIES_INSTANCE_UID, "series-" + id); |
796 instance.SetValue(DICOM_TAG_SOP_INSTANCE_UID, "instance-" + id); | 796 instance.SetValue(DICOM_TAG_SOP_INSTANCE_UID, "instance-" + id); |
797 | 797 |
798 std::map<MetadataType, std::string> instanceMetadata; | 798 std::map<MetadataType, std::string> instanceMetadata; |
799 ServerIndex::MetadataMap metadata; | 799 DicomInstanceToStore toStore; |
800 ASSERT_EQ(StoreStatus_Success, index.Store(instanceMetadata, instance, attachments, "", metadata)); | 800 toStore.SetSummary(instance); |
801 ASSERT_EQ(StoreStatus_Success, index.Store(instanceMetadata, toStore, attachments)); | |
801 ASSERT_EQ(2u, instanceMetadata.size()); | 802 ASSERT_EQ(2u, instanceMetadata.size()); |
802 ASSERT_TRUE(instanceMetadata.find(MetadataType_Instance_RemoteAet) != instanceMetadata.end()); | 803 ASSERT_TRUE(instanceMetadata.find(MetadataType_Instance_RemoteAet) != instanceMetadata.end()); |
803 ASSERT_TRUE(instanceMetadata.find(MetadataType_Instance_ReceptionDate) != instanceMetadata.end()); | 804 ASSERT_TRUE(instanceMetadata.find(MetadataType_Instance_ReceptionDate) != instanceMetadata.end()); |
804 | 805 |
805 DicomInstanceHasher hasher(instance); | 806 DicomInstanceHasher hasher(instance); |