← Back to team overview

openlp-core team mailing list archive

[Merge] lp:~googol/openlp/py3-fixes into lp:openlp

 

Andreas Preikschat has proposed merging lp:~googol/openlp/py3-fixes into lp:openlp.

Requested reviews:
  Tim Bentley (trb143)

For more details, see:
https://code.launchpad.net/~googol/openlp/py3-fixes/+merge/184839

Hello,

- fixed theme form not accepting any image.
-- 
https://code.launchpad.net/~googol/openlp/py3-fixes/+merge/184839
Your team OpenLP Core is subscribed to branch lp:openlp.
=== modified file 'openlp/core/utils/__init__.py'
--- openlp/core/utils/__init__.py	2013-08-31 18:17:38 +0000
+++ openlp/core/utils/__init__.py	2013-09-10 17:45:26 +0000
@@ -256,7 +256,8 @@
     if not file_name:
         return True
     else:
-        formats = [str(fmt).lower() for fmt in QtGui.QImageReader.supportedImageFormats()]
+        formats = map(bytes.decode, map(bytes, QtGui.QImageReader.supportedImageFormats()))
+        formats = map(str.lower, formats)
         file_part, file_extension = os.path.splitext(str(file_name))
         if file_extension[1:].lower() in formats and os.path.exists(file_name):
             return False

=== modified file 'tests/functional/openlp_plugins/songs/test_ewimport.py'
--- tests/functional/openlp_plugins/songs/test_ewimport.py	2013-08-31 18:17:38 +0000
+++ tests/functional/openlp_plugins/songs/test_ewimport.py	2013-09-10 17:45:26 +0000
@@ -354,7 +354,6 @@
             #       called.
             self.assertIsNone(importer.doImport(), 'doImport should return None when it has completed')
             for song_data in SONG_TEST_DATA:
-                print mocked_title.mocked_calls()
                 title = song_data['title']
                 author_calls = song_data['authors']
                 song_copyright = song_data['copyright']


Follow ups