changeset 275:264bb7744679

cont
author Sebastien Jodogne <s.jodogne@gmail.com>
date Tue, 03 Mar 2020 17:36:47 +0100
parents 6b522ef4c3ec
children cc10eefaf908
files Plugins/DicomWeb/Run.py
diffstat 1 files changed, 10 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/Plugins/DicomWeb/Run.py	Tue Mar 03 17:20:13 2020 +0100
+++ b/Plugins/DicomWeb/Run.py	Tue Mar 03 17:36:47 2020 +0100
@@ -1085,6 +1085,16 @@
         
         self.assertRaises(Exception, lambda: DoGet(ORTHANC, '/dicom-web/studies/%s/metadata' % study,
                                                    headers = { 'Accept' : 'toto, tata' }))
+
+        # https://groups.google.com/d/msg/orthanc-users/9o5kItsMQI0/Og6B27YyBgAJ
+        self.assertEqual(1, len(DoGetMultipart(ORTHANC, '/dicom-web/studies/%s/metadata' % study,
+                                               headers = { 'Accept' : 'multipart/related;type=application/dicom+xml' })))
+
+        self.assertEqual(1, len(DoGet(ORTHANC, '/dicom-web/studies/%s/metadata' % study,
+                                      headers = { 'Accept' : 'application/json, application/dicom+xml' })))
+
+        self.assertEqual(1, len(DoGet(ORTHANC, '/dicom-web/studies/%s/metadata' % study,
+                                      headers = { 'Accept' : 'application/dicom+xml, application/json' })))