mirror of
https://github.com/fluencelabs/js-peer-id
synced 2025-04-25 18:32:20 +00:00
tests # of bits
This commit is contained in:
parent
727355c4f5
commit
352a6cfa17
@ -62,5 +62,12 @@ describe('id', function (done) {
|
|||||||
expect(id2.id).to.deep.equal(id1.id)
|
expect(id2.id).to.deep.equal(id1.id)
|
||||||
done()
|
done()
|
||||||
})
|
})
|
||||||
|
|
||||||
|
it('Non-default # of bits', (done) => {
|
||||||
|
const shortId = PeerId.create({ bits: 128 })
|
||||||
|
const longId = PeerId.create({ bits: 256 })
|
||||||
|
expect(shortId.privKey.length).is.below(longId.privKey.length)
|
||||||
|
done()
|
||||||
|
})
|
||||||
})
|
})
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user