Script: check hex not template result
This commit is contained in:
parent
91bb25c00c
commit
aded938ab6
1 changed files with 3 additions and 1 deletions
|
@ -162,13 +162,15 @@ describe('Script', function() {
|
||||||
describe('fromChunks', function() {
|
describe('fromChunks', function() {
|
||||||
it('should match expected behaviour', function() {
|
it('should match expected behaviour', function() {
|
||||||
var hash = new Buffer(32)
|
var hash = new Buffer(32)
|
||||||
|
hash.fill(0)
|
||||||
|
|
||||||
var script = Script.fromChunks([
|
var script = Script.fromChunks([
|
||||||
opcodes.OP_HASH160,
|
opcodes.OP_HASH160,
|
||||||
hash,
|
hash,
|
||||||
opcodes.OP_EQUAL
|
opcodes.OP_EQUAL
|
||||||
])
|
])
|
||||||
|
|
||||||
assert.deepEqual(script, Script.createP2SHScriptPubKey(hash))
|
assert.equal(script.toHex(), 'a920000000000000000000000000000000000000000000000000000000000000000087')
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue