tests: move transactionVersion into toBuffer
This commit is contained in:
parent
dfcb04c9b4
commit
87269fe73e
1 changed files with 7 additions and 9 deletions
|
@ -73,6 +73,13 @@ describe('Transaction', function () {
|
|||
}, new RegExp(f.exception))
|
||||
})
|
||||
})
|
||||
|
||||
it('.version should be interpreted as an int32le', function () {
|
||||
var txHex = 'ffffffff0000ffffffff'
|
||||
var tx = Transaction.fromHex(txHex)
|
||||
assert.equal(-1, tx.version)
|
||||
assert.equal(0xffffffff, tx.locktime)
|
||||
})
|
||||
})
|
||||
|
||||
describe('toBuffer/toHex', function () {
|
||||
|
@ -103,15 +110,6 @@ describe('Transaction', function () {
|
|||
})
|
||||
})
|
||||
|
||||
describe('transactionVersion', function () {
|
||||
it('should be interpreted as an int32le', function () {
|
||||
var txHex = 'ffffffff0000ffffffff'
|
||||
var tx = Transaction.fromHex(txHex)
|
||||
assert.equal(-1, tx.version)
|
||||
assert.equal(0xffffffff, tx.locktime)
|
||||
})
|
||||
})
|
||||
|
||||
describe('addInput', function () {
|
||||
var prevTxHash
|
||||
beforeEach(function () {
|
||||
|
|
Loading…
Add table
Reference in a new issue