diff --git a/picard/formats/mutagenext/tak.py b/picard/formats/mutagenext/tak.py index b97ceefc0..bca26ce17 100644 --- a/picard/formats/mutagenext/tak.py +++ b/picard/formats/mutagenext/tak.py @@ -39,7 +39,7 @@ class TAKInfo(object): def __init__(self, fileobj): header = fileobj.read(4) - if len(header) != 4 or not header.startswith("tBaK"): + if len(header) != 4 or not header.startswith(b"tBaK"): raise TAKHeaderError("not a TAK file") def pprint(self): diff --git a/test/data/test.tak b/test/data/test.tak new file mode 100644 index 000000000..c9b646307 Binary files /dev/null and b/test/data/test.tak differ diff --git a/test/test_formats.py b/test/test_formats.py index f2cc997aa..d9ca2201d 100644 --- a/test/test_formats.py +++ b/test/test_formats.py @@ -500,6 +500,11 @@ class MusepackSV8Test(CommonTests.FormatsTest): supports_ratings = False +class TAKTest(CommonTests.FormatsTest): + testfile = 'test.tak' + supports_ratings = False + + cover_settings = { 'embed_only_one_front_image': True, }