Add methods to decode information from output scripts
This commit is contained in:
parent
53f08a7569
commit
27b48e8aa2
5 changed files with 252 additions and 82 deletions
test
|
@ -10,7 +10,16 @@ var fixtures = require('./fixtures/script.json')
|
|||
|
||||
describe('script', function () {
|
||||
// TODO
|
||||
describe.skip('isCanonicalPubKey', function () {})
|
||||
describe('isCanonicalPubKey', function () {
|
||||
it('rejects if not provided a Buffer', function () {
|
||||
assert.strictEqual(false, bscript.isCanonicalPubKey(0))
|
||||
})
|
||||
it('rejects smaller than 33', function () {
|
||||
for (var i = 0; i < 33; i++) {
|
||||
assert.strictEqual(false, bscript.isCanonicalPubKey(new Buffer('', i)))
|
||||
}
|
||||
})
|
||||
})
|
||||
describe.skip('isCanonicalSignature', function () {})
|
||||
|
||||
describe('fromASM/toASM', function () {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue