# HG changeset patch # User Sebastien Jodogne # Date 1585205821 -3600 # Node ID 7fa5c7a03137cccf8ea77f25fdaeee2dfda9eb3b # Parent 51b08c50c780ef67227bdd9a9926a3b0e560ac49 added test for issue 56 diff -r 51b08c50c780 -r 7fa5c7a03137 Database/Issue56-NoPixelData.dcm Binary file Database/Issue56-NoPixelData.dcm has changed diff -r 51b08c50c780 -r 7fa5c7a03137 Plugins/DicomWeb/Run.py --- a/Plugins/DicomWeb/Run.py Wed Mar 18 14:51:20 2020 +0100 +++ b/Plugins/DicomWeb/Run.py Thu Mar 26 07:57:01 2020 +0100 @@ -1106,8 +1106,36 @@ self.assertEqual(1, len(DoGet(ORTHANC, '/dicom-web/studies/%s/metadata' % study, headers = { 'Accept' : 'application/dicom+xml, application/json' }))) - - + + + + def test_bitbucket_issue_56(self): + # "Case-insensitive matching over accents" => DICOMweb part + # from AlexanderM on 2020-03-20 + # https://bitbucket.org/sjodogne/orthanc/issues/56/ + UploadInstance(ORTHANC, 'Issue56-NoPixelData.dcm') + + self.assertEqual(1, len(DoPost(ORTHANC, '/tools/find', { + 'Level' : 'Patient', + 'Query' : { + 'PatientName' : 'Гусева*', + }, + }))) + + self.assertEqual(1, len(DoPost(ORTHANC, '/tools/find', { + 'Level' : 'Patient', + 'Query' : { + 'PatientName' : 'гусева*', + }, + }))) + + self.assertEqual(1, len(DoGet(ORTHANC, u'/dicom-web/studies?PatientName=Гусева*', + headers = { 'accept' : 'application/json' }))) + + # This line is the isse + self.assertEqual(1, len(DoGet(ORTHANC, u'/dicom-web/studies?PatientName=гусева*', + headers = { 'accept' : 'application/json' }))) + try: print('\nStarting the tests...')