HDNode: use typeforce.tuple for arguments

This commit is contained in:
Daniel Cousens 2015-08-18 14:21:38 +10:00
parent eb752f8316
commit 5d2abb523e
2 changed files with 6 additions and 16 deletions

View file

@ -52,16 +52,8 @@ describe('HDNode', function () {
it('throws when an invalid length chain code is given', function () {
assert.throws(function () {
new HDNode(keyPair, chainCode.slice(0, 20))
}, /Expected chainCode length of 32, got 20/)
})
it('throws when an unknown network is given', function () {
keyPair.network = {}
assert.throws(function () {
new HDNode(keyPair, chainCode)
}, /Unknown BIP32 constants for network/)
new HDNode(keyPair, new Buffer(20))
}, /Expected 256-bit Buffer, got 160-bit/)
})
})