rename network to testnet
This commit is contained in:
parent
2dfe7a2c96
commit
200217c2c2
1 changed files with 4 additions and 4 deletions
|
@ -62,9 +62,9 @@ describe('bitcoinjs-lib (basic)', function () {
|
||||||
it('can create a [complex] Transaction', function (done) {
|
it('can create a [complex] Transaction', function (done) {
|
||||||
this.timeout(30000)
|
this.timeout(30000)
|
||||||
|
|
||||||
var network = bitcoin.networks.testnet
|
var testnet = bitcoin.networks.testnet
|
||||||
var alice = bitcoin.ECPair.makeRandom({ network: network })
|
var alice = bitcoin.ECPair.makeRandom({ network: testnet })
|
||||||
var bob = bitcoin.ECPair.makeRandom({ network: network })
|
var bob = bitcoin.ECPair.makeRandom({ network: testnet })
|
||||||
var alicesAddress = alice.getAddress()
|
var alicesAddress = alice.getAddress()
|
||||||
var bobsAddress = bob.getAddress()
|
var bobsAddress = bob.getAddress()
|
||||||
|
|
||||||
|
@ -80,7 +80,7 @@ describe('bitcoinjs-lib (basic)', function () {
|
||||||
], function (err, unspents) {
|
], function (err, unspents) {
|
||||||
if (err) return done(err)
|
if (err) return done(err)
|
||||||
|
|
||||||
var tx = new bitcoin.TransactionBuilder(network)
|
var tx = new bitcoin.TransactionBuilder(testnet)
|
||||||
tx.addInput(unspents[0].txId, unspents[0].vout)
|
tx.addInput(unspents[0].txId, unspents[0].vout)
|
||||||
tx.addInput(unspents[1].txId, unspents[1].vout)
|
tx.addInput(unspents[1].txId, unspents[1].vout)
|
||||||
tx.addOutput(blockchain.t.RETURN, 3e4)
|
tx.addOutput(blockchain.t.RETURN, 3e4)
|
||||||
|
|
Loading…
Reference in a new issue