mirror of
https://github.com/embarklabs/embark.git
synced 2025-01-11 14:24:24 +00:00
fix(@embark/cockpit): fix gas estimation
This commit is contained in:
parent
1d459e45b1
commit
43fed4f3e5
@ -1,4 +1,3 @@
|
||||
/*global web3*/
|
||||
const async = require('async');
|
||||
const ContractFuzzer = require('./fuzzer.js');
|
||||
|
||||
@ -13,6 +12,7 @@ class GasEstimator {
|
||||
estimateGas(contractName, cb) {
|
||||
const self = this;
|
||||
let gasMap = {};
|
||||
self.events.request('blockchain:object', ({ web3 }) => {
|
||||
self.events.request('contracts:contract', contractName, (contract) => {
|
||||
let fuzzMap = self.fuzzer.generateFuzz(3, contract);
|
||||
let contractObj = new web3.eth.Contract(contract.abiDefinition, contract.deployedAddress);
|
||||
@ -71,6 +71,7 @@ class GasEstimator {
|
||||
}
|
||||
);
|
||||
});
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user