Split the testsuite a bit and add more tests
This commit is contained in:
parent
b4ef0c9622
commit
74f2d50433
3 changed files with 99 additions and 66 deletions
|
@ -6,6 +6,17 @@ from . import abstract
|
|||
|
||||
|
||||
class MutagenParser(abstract.AbstractParser):
|
||||
def __init__(self, filename):
|
||||
super().__init__(filename)
|
||||
try:
|
||||
mutagen.File(self.filename)
|
||||
except mutagen.flac.MutagenError:
|
||||
raise ValueError
|
||||
except mutagen.mp3.MutagenError:
|
||||
raise ValueError
|
||||
except mutagen.ogg.MutagenError:
|
||||
raise ValueError
|
||||
|
||||
def get_meta(self):
|
||||
f = mutagen.File(self.filename)
|
||||
if f.tags:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue