script: add fromASM failing test case and fix
This commit is contained in:
parent
d0b4f0adf7
commit
a86e905611
3 changed files with 15 additions and 0 deletions
test
|
@ -28,6 +28,14 @@ describe('script', function () {
|
|||
assert.strictEqual(bscript.toASM(scriptSig), f.asm)
|
||||
})
|
||||
})
|
||||
|
||||
fixtures.invalid.fromASM.forEach(function (f) {
|
||||
it('throws ' + f.description, function () {
|
||||
assert.throws(function () {
|
||||
bscript.fromASM(f.script)
|
||||
}, new RegExp(f.description))
|
||||
})
|
||||
})
|
||||
})
|
||||
|
||||
describe('isPushOnly', function () {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue