tests: add test for setWitness
This commit is contained in:
parent
b1daff1108
commit
03dc569236
1 changed files with 8 additions and 0 deletions
|
@ -225,4 +225,12 @@ describe('Transaction', function () {
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
|
||||||
|
describe('setWitness', function () {
|
||||||
|
it('only accepts a a witness stack (Array of Buffers)', function () {
|
||||||
|
assert.throws(function () {
|
||||||
|
(new Transaction()).setWitness(0, 'foobar')
|
||||||
|
}, /Expected property "1" of type \[Buffer\], got String "foobar"/)
|
||||||
|
})
|
||||||
|
})
|
||||||
})
|
})
|
||||||
|
|
Loading…
Add table
Reference in a new issue