comparison Plugins/DicomWeb/Run.py @ 277:95c47602990c

fix
author Sebastien Jodogne <s.jodogne@gmail.com>
date Wed, 04 Mar 2020 13:10:29 +0100
parents cc10eefaf908
children 514785dacd6d
comparison
equal deleted inserted replaced
276:cc10eefaf908 277:95c47602990c
225 self.assertEqual(1, len(parts)) 225 self.assertEqual(1, len(parts))
226 self.assertEqual(os.path.getsize(GetDatabasePath('Phenix/IM-0001-0001.dcm')), int(parts[0])) 226 self.assertEqual(os.path.getsize(GetDatabasePath('Phenix/IM-0001-0001.dcm')), int(parts[0]))
227 227
228 228
229 def test_server_get(self): 229 def test_server_get(self):
230 try:
231 DoDelete(ORTHANC, '/dicom-web/servers/google') # If "AllWindowsStart.sh" is used
232 except:
233 pass
234
230 UploadInstance(ORTHANC, 'Knee/T1/IM-0001-0001.dcm') 235 UploadInstance(ORTHANC, 'Knee/T1/IM-0001-0001.dcm')
231 236
232 self.assertEqual(1, len(DoGet(ORTHANC, '/dicom-web/servers'))) 237 self.assertEqual(1, len(DoGet(ORTHANC, '/dicom-web/servers')))
233 self.assertTrue('sample' in DoGet(ORTHANC, '/dicom-web/servers')) 238 self.assertTrue('sample' in DoGet(ORTHANC, '/dicom-web/servers'))
234 239
681 686
682 687
683 def test_add_server(self): 688 def test_add_server(self):
684 try: 689 try:
685 DoDelete(ORTHANC, '/dicom-web/servers/hello') 690 DoDelete(ORTHANC, '/dicom-web/servers/hello')
691 except:
692 pass
693
694 try:
695 DoDelete(ORTHANC, '/dicom-web/servers/google') # If "AllWindowsStart.sh" is used
686 except: 696 except:
687 pass 697 pass
688 698
689 l = DoGet(ORTHANC, '/dicom-web/servers') 699 l = DoGet(ORTHANC, '/dicom-web/servers')
690 self.assertEqual(1, len(l)) 700 self.assertEqual(1, len(l))