* morituri/common/encode.py:

Add a task to read tags.
	* morituri/test/test_common_encode.py:
	  Add a test.
This commit is contained in:
Thomas Vander Stichele
2010-04-13 07:37:01 +00:00
parent 7022d9627c
commit a787676239
3 changed files with 96 additions and 0 deletions

View File

@@ -39,3 +39,13 @@ class PathTestCase(common.TestCase):
def testDoubleQuote(self):
self._testSuffix(u'.morituri.test_encode.12" edit')
class TagReadTestCase(common.TestCase):
def testRead(self):
path = os.path.join(os.path.dirname(__file__), u'track.flac')
self.runner = task.SyncRunner(verbose=False)
t = encode.TagReadTask(path)
self.runner.run(t)
self.failUnless(t.taglist)
self.assertEquals(t.taglist['audio-codec'], 'FLAC')
self.assertEquals(t.taglist['description'], 'audiotest wave')