Mercurial > hg > orthanc-tests
changeset 225:4d5af1f49cb2
cont
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Tue, 26 Feb 2019 18:30:31 +0100 |
parents | f5414254ccaa |
children | 230aede7f8d5 |
files | Plugins/DicomWeb/Run.py |
diffstat | 1 files changed, 19 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/Plugins/DicomWeb/Run.py Tue Feb 26 18:16:12 2019 +0100 +++ b/Plugins/DicomWeb/Run.py Tue Feb 26 18:30:31 2019 +0100 @@ -477,6 +477,25 @@ self.assertEqual(u'王^小東', pn['Value'][0]['Ideographic']) + def test_bitbucket_issue_96(self): + # WADO-RS RetrieveFrames rejects valid accept headers + # https://bitbucket.org/sjodogne/orthanc/issues/96 + # https://bitbucket.org/sjodogne/orthanc-dicomweb/issues/5/ + + UploadInstance(ORTHANC, 'LenaTwiceWithFragments.dcm') + + a = DoGet(ORTHANC, '/dicom-web/instances') + self.assertEqual(1, len(a)) + url = a[0]['00081190']['Value'][0] + + prefix = 'http://localhost:8042' + self.assertTrue(url.startswith(prefix)) + uri = url[len(prefix):] + + b = DoGetRaw(ORTHANC, '%s/frames/1' % uri, headers = { 'Accept' : 'multipart/related; type=application/octet-stream' }) + print b + + try: print('\nStarting the tests...') unittest.main(argv = [ sys.argv[0] ] + args.options)