diff options
author | Fabio Berger <me@fabioberger.com> | 2018-05-24 03:01:38 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-05-24 03:01:38 +0800 |
commit | 513007a82ce9065d44694516bc94771ee4bc2c6f (patch) | |
tree | fe156fa4bb2dc5fecd2df4dd1fcd82e1e3007821 /packages/metacoin/test/utils/web3_wrapper.ts | |
parent | af0d9439d4f4e05fce8018665e375cf2db07184c (diff) | |
parent | bf18a90da79d43e90901b0cd156f15398e215d91 (diff) | |
download | dexon-sol-tools-513007a82ce9065d44694516bc94771ee4bc2c6f.tar dexon-sol-tools-513007a82ce9065d44694516bc94771ee4bc2c6f.tar.gz dexon-sol-tools-513007a82ce9065d44694516bc94771ee4bc2c6f.tar.bz2 dexon-sol-tools-513007a82ce9065d44694516bc94771ee4bc2c6f.tar.lz dexon-sol-tools-513007a82ce9065d44694516bc94771ee4bc2c6f.tar.xz dexon-sol-tools-513007a82ce9065d44694516bc94771ee4bc2c6f.tar.zst dexon-sol-tools-513007a82ce9065d44694516bc94771ee4bc2c6f.zip |
Merge pull request #589 from 0xProject/feature/truffle-sol-cov
Sol-cov artifact Adapters (truffle)
Diffstat (limited to 'packages/metacoin/test/utils/web3_wrapper.ts')
-rw-r--r-- | packages/metacoin/test/utils/web3_wrapper.ts | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/packages/metacoin/test/utils/web3_wrapper.ts b/packages/metacoin/test/utils/web3_wrapper.ts index b4bb61f09..724ed4e1f 100644 --- a/packages/metacoin/test/utils/web3_wrapper.ts +++ b/packages/metacoin/test/utils/web3_wrapper.ts @@ -1,5 +1,5 @@ import { env, EnvVars } from '@0xproject/dev-utils'; -import { GanacheSubprovider } from '@0xproject/subproviders'; +import { GanacheSubprovider, prependSubprovider } from '@0xproject/subproviders'; import { Web3Wrapper } from '@0xproject/web3-wrapper'; import * as fs from 'fs'; import * as _ from 'lodash'; @@ -9,10 +9,6 @@ import { config } from './config'; import { coverage } from './coverage'; export const provider = new ProviderEngine(); -const isCoverageEnabled = env.parseBoolean(EnvVars.SolidityCoverage); -if (isCoverageEnabled) { - provider.addProvider(coverage.getCoverageSubproviderSingleton()); -} provider.addProvider( new GanacheSubprovider({ logger: { @@ -27,4 +23,10 @@ provider.addProvider( ); provider.start(); +const isCoverageEnabled = env.parseBoolean(EnvVars.SolidityCoverage); +if (isCoverageEnabled) { + const coverageSubprovider = coverage.getCoverageSubproviderSingleton(); + prependSubprovider(provider, coverageSubprovider); +} + export const web3Wrapper = new Web3Wrapper(provider); |