fix: use proper phrase decompress algorithm

[deploy]
This commit is contained in:
2023-07-28 17:04:43 +02:00
parent 374e27c7d0
commit c709878d6a
6 changed files with 27 additions and 44 deletions

View File

@@ -28,11 +28,11 @@ describe("chords", function () {
describe("phrase", function () {
it("should stringify", function () {
expect(stringifyPhrase([0x01, 0x68, 0x72, 0xd4, 0x65])).toEqual("016872D465")
expect(stringifyPhrase([0x20, 0x68, 0x72, 0xd4, 0x65, 0x1fff])).toEqual("206872D4651FFF")
})
it("should parse", function () {
expect(parsePhrase("016872D465")).toEqual([0x01, 0x68, 0x72, 0xd4, 0x65])
expect(parsePhrase("206872D4651FFF")).toEqual([0x20, 0x68, 0x72, 0xd4, 0x65, 0x1fff])
})
})