diff --git a/src/resolver.js b/src/resolver.js index b98b87e..de1972a 100644 --- a/src/resolver.js +++ b/src/resolver.js @@ -134,6 +134,7 @@ const resolveField = (dagNode, field) => { } module.exports = { + multicodec: 'bitcoin-block', resolve: resolve, tree: tree } diff --git a/test/resolver.spec.js b/test/resolver.spec.js index 636c374..723e6e9 100644 --- a/test/resolver.spec.js +++ b/test/resolver.spec.js @@ -130,6 +130,13 @@ describe('IPLD format resolver API tree()', () => { }) }) +describe('IPLD format resolver API properties', () => { + it('should have `multicodec` defined correctly', (done) => { + expect(IpldBitcoin.resolver.multicodec).to.equal('bitcoin-block') + done() + }) +}) + const verifyPath = (block, path, expected, done) => { IpldBitcoin.resolver.resolve(block, path, (err, value) => { expect(err).to.not.exist()