Add replaygain test for command backend

This commit is contained in:
Thomas Scholtes 2014-04-04 21:11:12 +02:00
parent 1c598d4cee
commit 5b277eedf8
2 changed files with 11 additions and 2 deletions

View file

@ -23,6 +23,7 @@ install:
travis_retry sudo apt-get install -qq
bash-completion python-gi gir1.2-gstreamer-1.0
gstreamer1.0-plugins-good gstreamer1.0-plugins-bad
mp3gain
- travis_retry pip install tox sphinx
- "[[ $TOX_ENV == 'py27' ]] && pip install coveralls || true"

View file

@ -28,11 +28,11 @@ from beets.library import Item, Album
from beets.mediafile import MediaFile
class ReplayGainGstCliTest(unittest.TestCase):
class ReplayGainCliTestBase(object):
def setUp(self):
self.setupBeets()
self.config['replaygain']['backend'] = u'gstreamer'
self.config['replaygain']['backend'] = self.backend
self.config['plugins'] = ['replaygain']
self.setupLibrary(2)
@ -142,6 +142,14 @@ class ReplayGainGstCliTest(unittest.TestCase):
self.assertNotEqual(max(peaks), 0.0)
class ReplayGainGstCliTest(ReplayGainCliTestBase, unittest.TestCase):
backend = u'gstreamer'
class ReplayGainCmdCliTest(ReplayGainCliTestBase, unittest.TestCase):
backend = u'command'
def suite():
return unittest.TestLoader().loadTestsFromName(__name__)