diff Tests/Tests.py @ 464:216231c18c2e

added tests for implicit vr preview
author Alain Mazy <am@osimis.io>
date Wed, 13 Apr 2022 10:59:57 +0200
parents 29aaa3df718f
children 038fb852e2be
line wrap: on
line diff
--- a/Tests/Tests.py	Thu Apr 07 09:46:24 2022 +0200
+++ b/Tests/Tests.py	Wed Apr 13 10:59:57 2022 +0200
@@ -382,7 +382,16 @@
         # This is Little Endian Explicit
         self.assertEqual('1.2.840.10008.1.2.1', DoGet(_REMOTE, '/instances/%s/header?simplify' % i)['TransferSyntaxUID'])
 
-
+    def test_images_implicit_vr(self):
+        if IsOrthancVersionAbove(_REMOTE, 1, 10, 2):
+            i = UploadInstance(_REMOTE, 'Implicit-vr-us-palette.dcm')['ID']
+
+            im = GetImage(_REMOTE, '/instances/%s/preview' % i)
+            self.assertEqual("RGB", im.mode)
+            self.assertEqual(800, im.size[0])
+            self.assertEqual(600, im.size[1])
+
+        
     def test_hierarchy(self):
         UploadFolder(_REMOTE, 'Brainix/Epi')
         UploadFolder(_REMOTE, 'Brainix/Flair')