From ddc66fcd2f37b38a158831e7adc672ece0c35d4c Mon Sep 17 00:00:00 2001 From: Bastian Germann Date: Tue, 16 Oct 2018 20:32:30 +0200 Subject: [PATCH] Try to fix macOS tests --- openlp/core/ui/media/vendor/mediainfoWrapper.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/openlp/core/ui/media/vendor/mediainfoWrapper.py b/openlp/core/ui/media/vendor/mediainfoWrapper.py index feb6ec7df..995317c88 100644 --- a/openlp/core/ui/media/vendor/mediainfoWrapper.py +++ b/openlp/core/ui/media/vendor/mediainfoWrapper.py @@ -25,13 +25,15 @@ on a media file and obtain information related to the requested media. """ from pymediainfo import MediaInfo from subprocess import check_output +import sys class MediaInfoWrapper(object): @staticmethod def parse(filename): - if MediaInfo.can_parse(): + # FIXME: library loading on macOS + if sys.platform != 'darwin' and MediaInfo.can_parse(): return MediaInfo.parse(filename) else: xml = check_output(['mediainfo', '-f', '--Output=XML', '--Inform=OLDXML', filename])