aboutsummaryrefslogtreecommitdiffstats
path: root/packages/contracts
diff options
context:
space:
mode:
Diffstat (limited to 'packages/contracts')
-rw-r--r--packages/contracts/src/utils/web3_wrapper.ts3
-rw-r--r--packages/contracts/test/utils/coverage.ts6
2 files changed, 5 insertions, 4 deletions
diff --git a/packages/contracts/src/utils/web3_wrapper.ts b/packages/contracts/src/utils/web3_wrapper.ts
index 5d3d9f7c9..02595506b 100644
--- a/packages/contracts/src/utils/web3_wrapper.ts
+++ b/packages/contracts/src/utils/web3_wrapper.ts
@@ -13,6 +13,7 @@ const providerConfigs = { shouldUseInProcessGanache: true };
export const provider = web3Factory.getRpcProvider(providerConfigs);
const isCoverageEnabled = env.parseBoolean(EnvVars.SolidityCoverage);
if (isCoverageEnabled) {
- prependSubprovider(provider, coverage.getCoverageSubproviderSingleton());
+ const coverageSubprovider = coverage.getCoverageSubproviderSingleton();
+ prependSubprovider(provider, coverageSubprovider);
}
export const web3Wrapper = new Web3Wrapper(provider);
diff --git a/packages/contracts/test/utils/coverage.ts b/packages/contracts/test/utils/coverage.ts
index eeb47667f..3b2a8d7b2 100644
--- a/packages/contracts/test/utils/coverage.ts
+++ b/packages/contracts/test/utils/coverage.ts
@@ -16,8 +16,8 @@ export const coverage = {
const defaultFromAddress = devConstants.TESTRPC_FIRST_ADDRESS;
const CONFIG_FILE = 'compiler.json';
const config = JSON.parse(fs.readFileSync(CONFIG_FILE).toString());
- const zeroExArtifactsAdapter = new SolCompilerArtifactAdapter(config.artifactsDir, config.contractsDir);
- const coverageSubrpovider = new CoverageSubprovider(zeroExArtifactsAdapter, defaultFromAddress);
- return coverageSubprovider;
+ const solCompilerArtifactAdapter = new SolCompilerArtifactAdapter(config.artifactsDir, config.contractsDir);
+ const subprovider = new CoverageSubprovider(solCompilerArtifactAdapter, defaultFromAddress);
+ return subprovider;
},
};