diff --git a/test/test-asf.ts b/test/test-asf.ts index 0f31d01da..fcd682934 100644 --- a/test/test-asf.ts +++ b/test/test-asf.ts @@ -1,9 +1,8 @@ import {} from "mocha"; import {assert} from 'chai'; import * as mm from '../src'; -import {INativeTagDict} from "../lib/index"; import * as path from 'path'; -import GUID from "../lib/asf/GUID"; +import GUID from "../src/asf/GUID"; import * as fs from 'fs-extra'; const t = assert; @@ -42,7 +41,7 @@ describe("ASF", () => { t.deepEqual(common.genre, ['Rock'], 'common.genre'); } - function checkNative(native: INativeTagDict) { + function checkNative(native: mm.INativeTagDict) { t.deepEqual(native['WM/AlbumTitle'], ['Discovery'], 'native: WM/AlbumTitle'); t.deepEqual(native['WM/BeatsPerMinute'], [117], 'native: WM/BeatsPerMinute'); diff --git a/test/test-common.ts b/test/test-common.ts index dc8dfdc75..5701374dc 100644 --- a/test/test-common.ts +++ b/test/test-common.ts @@ -1,6 +1,6 @@ import {} from "mocha"; import {assert} from 'chai'; -import Common from "../lib/common"; +import Common from "../src/common"; const t = assert; @@ -40,7 +40,7 @@ describe("Common", () => { const types = [ { buf: new Buffer([0x66, 0x74, 0x79, 0x70, 0x6D, 0x70, 0x34, 0x32]), - tag: require('../lib/id4'), + tag: require('../src/id4'), offset: 4 } ]; diff --git a/test/test-findzero.ts b/test/test-findzero.ts index ad24389a5..68f5018e0 100644 --- a/test/test-findzero.ts +++ b/test/test-findzero.ts @@ -1,6 +1,6 @@ import {} from "mocha"; import {assert} from 'chai'; -import * as common from '../lib/common'; +import * as common from '../src/common'; const findZero = common.default.findZero; diff --git a/test/test-id3v1.1.ts b/test/test-id3v1.1.ts index 8e345b972..09c6255a8 100644 --- a/test/test-id3v1.1.ts +++ b/test/test-id3v1.1.ts @@ -3,7 +3,6 @@ import {assert} from 'chai'; import * as mm from '../src'; import * as path from 'path'; -import {ICommonTagsResult} from "../lib/index"; const t = assert; @@ -23,7 +22,7 @@ describe("ID3v1.1", () => { t.strictEqual(format.numberOfChannels, 2, 'format.numberOfChannels 2 (stereo)'); } - function checkCommon(common: ICommonTagsResult) { + function checkCommon(common: mm.ICommonTagsResult) { t.strictEqual(common.title, 'Blood Sugar', 'common.title'); t.strictEqual(common.artist, 'Pendulum', 'common.artist'); t.strictEqual(common.album, 'Blood Sugar (Single)', 'common.album'); diff --git a/test/test-id3v2.3.ts b/test/test-id3v2.3.ts index 91ba4d1f7..c98cb8847 100644 --- a/test/test-id3v2.3.ts +++ b/test/test-id3v2.3.ts @@ -1,7 +1,6 @@ import {} from "mocha"; import {assert} from 'chai'; import * as mm from '../src'; -import {INativeTagDict} from "../lib/index"; import * as path from 'path'; const t = assert; @@ -35,7 +34,7 @@ it("should decode id3v2.3", () => { t.strictEqual(common.picture[0].data.length, 80938, 'common.picture length'); } - function checkNative(native: INativeTagDict) { + function checkNative(native: mm.INativeTagDict) { t.deepEqual(native.TALB, ['Friday Night Lights [Original Movie Soundtrack]'], 'native: TALB'); t.deepEqual(native.TPE1, ['Explosions In The Sky', 'Another', 'And Another'], 'native: TPE1'); diff --git a/test/test-picard-mappings.ts b/test/test-picard-mappings.ts index d46c4ac50..b96867d23 100644 --- a/test/test-picard-mappings.ts +++ b/test/test-picard-mappings.ts @@ -1,8 +1,8 @@ import {} from "mocha"; import {assert} from 'chai'; -import {APEv2TagMap} from "../lib/apev2/APEv2TagMap"; -import {AsfTagMap} from "../lib/asf/AsfTagMap"; -import {ID3v24TagMap} from "../lib/id3v2/ID3v24TagMap"; +import {APEv2TagMap} from "../src/apev2/APEv2TagMap"; +import {AsfTagMap} from "../src/asf/AsfTagMap"; +import {ID3v24TagMap} from "../src/id3v2/ID3v24TagMap"; describe("Parsing of metadata saved by 'Picard' in audio files", () => { diff --git a/test/test-picard-parsing.ts b/test/test-picard-parsing.ts index 99490e9b5..11d6fac94 100644 --- a/test/test-picard-parsing.ts +++ b/test/test-picard-parsing.ts @@ -1,9 +1,8 @@ import {} from "mocha"; import {assert} from 'chai'; import * as mm from '../src'; -import {ICommonTagsResult, INativeTagDict} from "../lib/index"; import * as path from 'path'; -import {HeaderType} from "../lib/tagmap"; +import {HeaderType} from "../src/tagmap"; import * as crypto from "crypto"; const t = assert; @@ -45,7 +44,7 @@ describe("Parsing of metadata saved by 'Picard' in audio files", () => { * @param inputTagType Meta-data header format * @param common Common tag mapping */ - function checkCommonMapping(inputTagType: HeaderType, common: ICommonTagsResult) { + function checkCommonMapping(inputTagType: HeaderType, common: mm.ICommonTagsResult) { // Compare expectedCommonTags with result.common t.strictEqual(common.title, "Sinner's Prayer", inputTagType + " => common.title"); t.strictEqual(common.artist, 'Beth Hart & Joe Bonamassa', inputTagType + " => common.artist"); @@ -107,7 +106,7 @@ describe("Parsing of metadata saved by 'Picard' in audio files", () => { * Check native Vorbis header * @param vorbis Vorbis native tags */ - function checkVorbisTags(vorbis: INativeTagDict, dataformat: string) { + function checkVorbisTags(vorbis: mm.INativeTagDict, dataformat: string) { // Compare expectedCommonTags with result.common t.deepEqual(vorbis.TITLE, ['Sinner\'s Prayer'], 'vorbis.TITLE'); t.deepEqual(vorbis.ALBUM, ['Don\'t Explain'], 'vorbis.TITLE'); @@ -214,7 +213,7 @@ describe("Parsing of metadata saved by 'Picard' in audio files", () => { describe("APEv2 header", () => { - function checkApeTags(APEv2: INativeTagDict) { + function checkApeTags(APEv2: mm.INativeTagDict) { // Compare expectedCommonTags with result.common t.deepEqual(APEv2.Title, ['Sinner\'s Prayer'], 'APEv2.Title'); t.deepEqual(APEv2.Album, ['Don\'t Explain'], 'APEv2.Album'); @@ -329,7 +328,7 @@ describe("Parsing of metadata saved by 'Picard' in audio files", () => { describe("ID3v2.3 header", () => { - function checkID3Tags(native: INativeTagDict) { + function checkID3Tags(native: mm.INativeTagDict) { t.deepEqual(native.TIT2, ['Sinner\'s Prayer'], 'id3v23.TIT2: Title/songname/content description'); t.deepEqual(native.TPE1, ['Beth Hart & Joe Bonamassa'], 'id3v23.TPE1: Lead performer(s)/Soloist(s)'); diff --git a/test/test-tagmap.ts b/test/test-tagmap.ts index 6fbc8d149..c588316d9 100644 --- a/test/test-tagmap.ts +++ b/test/test-tagmap.ts @@ -1,6 +1,6 @@ import {} from "mocha"; import {assert} from 'chai'; -import TagMap, {ITagInfoMap} from "../lib/tagmap"; +import TagMap, {ITagInfoMap} from "../src/tagmap"; const t = assert; diff --git a/test/test-unexpected-eos.ts b/test/test-unexpected-eos.ts index 088fd8a20..ff999d993 100644 --- a/test/test-unexpected-eos.ts +++ b/test/test-unexpected-eos.ts @@ -1,7 +1,7 @@ import {} from "mocha"; import {assert} from 'chai'; import * as mm from '../src'; -import Common from "../lib/common"; +import Common from "../src/common"; /* ToDo? import * as path from 'path';