Move to checkTxRoots and warn checkMerkleRoot deprecation

This commit is contained in:
junderw 2019-01-17 17:01:15 +09:00
parent 581ab5f136
commit e52abecee2
No known key found for this signature in database
GPG key ID: B256185D3A971908
4 changed files with 27 additions and 11 deletions

View file

@ -125,7 +125,7 @@ describe('Block', function () {
})
})
describe('checkMerkleRoot', function () {
describe('checkTxRoots', function () {
fixtures.valid.forEach(function (f) {
if (f.hex.length === 160) return
@ -136,14 +136,8 @@ describe('Block', function () {
})
it('returns ' + f.valid + ' for ' + f.id, function () {
assert.strictEqual(block.checkMerkleRoot(), true)
assert.strictEqual(block.checkTxRoots(), true)
})
if (f.witnessCommit) {
it('validates witness commit for ' + f.id, function () {
assert.strictEqual(block.checkWitnessCommit(), true)
})
}
})
})