From 672a4b93ba2d3e218b7ec7e0eba53e82349ac432 Mon Sep 17 00:00:00 2001 From: Leonid Logvinov Date: Tue, 4 Dec 2018 12:10:03 +0100 Subject: Don't start the provider by default --- contracts/multisig/test/global_hooks.ts | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 contracts/multisig/test/global_hooks.ts (limited to 'contracts/multisig/test') diff --git a/contracts/multisig/test/global_hooks.ts b/contracts/multisig/test/global_hooks.ts new file mode 100644 index 000000000..68eb4f8d5 --- /dev/null +++ b/contracts/multisig/test/global_hooks.ts @@ -0,0 +1,19 @@ +import { env, EnvVars } from '@0x/dev-utils'; + +import { coverage, profiler, provider } from '@0x/contracts-test-utils'; + +before('start web3 provider engine', () => { + provider.start(); +}); + +after('generate coverage report', async () => { + if (env.parseBoolean(EnvVars.SolidityCoverage)) { + const coverageSubprovider = coverage.getCoverageSubproviderSingleton(); + await coverageSubprovider.writeCoverageAsync(); + } + if (env.parseBoolean(EnvVars.SolidityProfiler)) { + const profilerSubprovider = profiler.getProfilerSubproviderSingleton(); + await profilerSubprovider.writeProfilerOutputAsync(); + } + provider.stop(); +}); -- cgit v1.2.3