1
0
mirror of synced 2026-05-22 14:43:19 +00:00

test: add test for multiple album artists in FLAC files

This commit is contained in:
ma225tq
2026-02-03 18:59:15 +01:00
committed by Borewit
parent 46568de6b2
commit d1916dea39
3 changed files with 9 additions and 1 deletions
+1 -1
View File
@@ -68,7 +68,7 @@ export interface ICommonTagsResult {
*/
artists?: string[];
/**
* Track album artist. Contains the first album artist if multiple tags exist, or maybe several album artists written in a single string.
* Track album artist/s. Contains the first album artist if multiple tags exist, or maybe several album artists written in a single string.
*/
albumartist?: string;
/**
Binary file not shown.
+8
View File
@@ -69,6 +69,14 @@ describe('Parse FLAC Vorbis comment', () => {
});
it('should support multiple album artists (separate Vorbis tags)', async () => {
const filePath = path.join(samplePath, 'flac-multiple-album-artists-tags.flac');
const {common} = await mm.parseFile(filePath);
assert.strictEqual(common.albumartist, 'Album Artist One', 'common.albumartist');
assert.deepEqual(common.albumartists, ['Album Artist One', 'Album Artist Two'], 'common.albumartists');
});
describe('should be able to recognize a ID3v2 tag header prefixing a FLAC file', () => {
const filePath = path.join(samplePath, 'a kind of magic.flac');