Skip to content
This repository has been archived by the owner on Feb 26, 2024. It is now read-only.

Commit

Permalink
Merge pull request #101 from kosecki123/fix/blocktime
Browse files Browse the repository at this point in the history
Rename blocktime to blockTime, completes changes from #506
  • Loading branch information
benjamincburns authored Apr 12, 2018
2 parents 3f484a8 + 4de0b71 commit 762e882
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
6 changes: 3 additions & 3 deletions lib/statemanager.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,8 @@ StateManager = function(options, provider) {
this.gasPriceVal = to.hex(options.gasPrice);

this.is_mining = true;
this.blocktime = options.blocktime;
this.is_mining_on_interval = !!options.blocktime;
this.blockTime = options.blockTime;
this.is_mining_on_interval = !!options.blockTime;
this.mining_interval_timeout = null;

this._provider = provider;
Expand Down Expand Up @@ -181,7 +181,7 @@ StateManager.prototype.mineOnInterval = function() {
self.mineOnInterval.bind(self)
);

}, this.blocktime * 1000);
}, this.blockTime * 1000);

// Ensure this won't keep a node process open.
if (this.mining_interval_timeout.unref) {
Expand Down
8 changes: 4 additions & 4 deletions test/interval_mining.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ describe("Interval Mining", function() {
this.timeout(5000);

web3 = new Web3(Ganache.provider({
blocktime: 0.5, // seconds
blockTime: 0.5, // seconds
mnemonic: mnemonic
}));

Expand All @@ -46,7 +46,7 @@ describe("Interval Mining", function() {
this.timeout(5000);

web3 = new Web3(Ganache.provider({
blocktime: 0.25, // seconds
blockTime: 0.25, // seconds
mnemonic: mnemonic
}));

Expand Down Expand Up @@ -89,7 +89,7 @@ describe("Interval Mining", function() {
this.timeout(5000);

web3 = new Web3(Ganache.provider({
blocktime: 0.5, // seconds
blockTime: 0.5, // seconds
mnemonic: mnemonic
}));

Expand Down Expand Up @@ -153,7 +153,7 @@ describe("Interval Mining", function() {
};

web3 = new Web3(Ganache.provider({
blocktime: 0.5, // seconds
blockTime: 0.5, // seconds
mnemonic: mnemonic,
logger: logger
}));
Expand Down
2 changes: 1 addition & 1 deletion test/vm.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ var logger = {

var web3 = new Web3();
web3.setProvider(Ganache.provider({
/*blocktime: 100,*/
/*blockTime: 100,*/
logger: logger,
seed: "1337"
}));
Expand Down

0 comments on commit 762e882

Please sign in to comment.