|
@ -19,6 +19,17 @@ describe('Scripts', function() { |
|
|
assert.equal(type, f.type) |
|
|
assert.equal(type, f.type) |
|
|
}) |
|
|
}) |
|
|
}) |
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|
fixtures.invalid.classify.forEach(function(f) { |
|
|
|
|
|
if (!f.scriptSig) return |
|
|
|
|
|
|
|
|
|
|
|
it('returns nonstandard for ' + f.description, function() { |
|
|
|
|
|
var script = Script.fromASM(f.scriptSig) |
|
|
|
|
|
var type = scripts.classifyInput(script) |
|
|
|
|
|
|
|
|
|
|
|
assert.equal(type, 'nonstandard') |
|
|
|
|
|
}) |
|
|
|
|
|
}) |
|
|
}) |
|
|
}) |
|
|
|
|
|
|
|
|
describe('classifyOutput', function() { |
|
|
describe('classifyOutput', function() { |
|
@ -34,6 +45,8 @@ describe('Scripts', function() { |
|
|
}) |
|
|
}) |
|
|
|
|
|
|
|
|
fixtures.invalid.classify.forEach(function(f) { |
|
|
fixtures.invalid.classify.forEach(function(f) { |
|
|
|
|
|
if (!f.scriptPubKey) return |
|
|
|
|
|
|
|
|
it('returns nonstandard for ' + f.description, function() { |
|
|
it('returns nonstandard for ' + f.description, function() { |
|
|
var script = Script.fromASM(f.scriptPubKey) |
|
|
var script = Script.fromASM(f.scriptPubKey) |
|
|
var type = scripts.classifyOutput(script) |
|
|
var type = scripts.classifyOutput(script) |
|
|