Mercurial > hg > orthanc
comparison UnitTestsSources/FromDcmtkTests.cpp @ 1692:4eaf164dd574
test SimplifyTags
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Thu, 08 Oct 2015 10:57:29 +0200 |
parents | e447f3cb8b30 |
children | 558b25228a23 |
comparison
equal
deleted
inserted
replaced
1691:e447f3cb8b30 | 1692:4eaf164dd574 |
---|---|
34 #include "gtest/gtest.h" | 34 #include "gtest/gtest.h" |
35 | 35 |
36 #include "../OrthancServer/FromDcmtkBridge.h" | 36 #include "../OrthancServer/FromDcmtkBridge.h" |
37 #include "../OrthancServer/OrthancInitialization.h" | 37 #include "../OrthancServer/OrthancInitialization.h" |
38 #include "../OrthancServer/DicomModification.h" | 38 #include "../OrthancServer/DicomModification.h" |
39 #include "../OrthancServer/ServerToolbox.h" | |
39 #include "../Core/OrthancException.h" | 40 #include "../Core/OrthancException.h" |
40 #include "../Core/Images/ImageBuffer.h" | 41 #include "../Core/Images/ImageBuffer.h" |
41 #include "../Core/Images/PngReader.h" | 42 #include "../Core/Images/PngReader.h" |
42 #include "../Core/Images/PngWriter.h" | 43 #include "../Core/Images/PngWriter.h" |
43 #include "../Core/Uuid.h" | 44 #include "../Core/Uuid.h" |
377 ASSERT_EQ(b["0008,1110"][i]["0010,0020"].asString(), "World"); | 378 ASSERT_EQ(b["0008,1110"][i]["0010,0020"].asString(), "World"); |
378 ASSERT_EQ(b["0008,1110"][i]["0008,1030"].asString(), "Toto"); | 379 ASSERT_EQ(b["0008,1110"][i]["0008,1030"].asString(), "Toto"); |
379 ASSERT_EQ(b["0008,1110"][1 - i]["0010,0010"].asString(), "Hello2"); | 380 ASSERT_EQ(b["0008,1110"][1 - i]["0010,0010"].asString(), "Hello2"); |
380 ASSERT_EQ(b["0008,1110"][1 - i]["0010,0020"].asString(), "World2"); | 381 ASSERT_EQ(b["0008,1110"][1 - i]["0010,0020"].asString(), "World2"); |
381 } | 382 } |
382 } | 383 |
383 | 384 { |
384 | 385 Json::Value b; |
385 | 386 FromDcmtkBridge::ToJson(b, *element, DicomToJsonFormat_Full, 0, Encoding_Ascii); |
386 // TODO: Test Simplify | 387 |
387 } | 388 Json::Value c; |
389 SimplifyTags(c, b); | |
390 | |
391 ASSERT_EQ(0, c["ReferencedStudySequence"].compare(a)); | |
392 } | |
393 } | |
394 } |