Fix bug with loading the genesis block for testnet.
This commit is contained in:
parent
747942cec1
commit
509b424262
|
@ -209,7 +209,7 @@ Node.prototype._loadConsensus = function(config) {
|
||||||
var genesisBlock;
|
var genesisBlock;
|
||||||
if (config.genesis) {
|
if (config.genesis) {
|
||||||
genesisBlock = config.genesis;
|
genesisBlock = config.genesis;
|
||||||
} else if (config.testnet) {
|
} else if (config.network === 'testnet') {
|
||||||
genesisBlock = genesis.testnet;
|
genesisBlock = genesis.testnet;
|
||||||
} else {
|
} else {
|
||||||
genesisBlock = genesis.livenet;
|
genesisBlock = genesis.livenet;
|
||||||
|
|
|
@ -309,7 +309,7 @@ describe('Bitcoind Node', function() {
|
||||||
});
|
});
|
||||||
it('should use the testnet genesis if testnet is specified', function() {
|
it('should use the testnet genesis if testnet is specified', function() {
|
||||||
var config = {
|
var config = {
|
||||||
testnet: true
|
network: 'testnet'
|
||||||
};
|
};
|
||||||
node._loadConsensus(config);
|
node._loadConsensus(config);
|
||||||
should.exist(node.chain);
|
should.exist(node.chain);
|
||||||
|
|
Loading…
Reference in New Issue