@0x/contracts-test-utils: Just do a naked mocha import in mocha_blockchain.

This commit is contained in:
Lawrence Forman 2019-07-27 11:14:33 -04:00
parent d6271426fd
commit eac4f172fe

View File

@ -1,7 +1,8 @@
import { BlockchainLifecycle } from '@0x/dev-utils'; import { BlockchainLifecycle } from '@0x/dev-utils';
import { Web3Wrapper } from '@0x/web3-wrapper'; import { Web3Wrapper } from '@0x/web3-wrapper';
import * as _ from 'lodash'; import * as _ from 'lodash';
import * as mocha from 'mocha'; // Import ambient declarations (and clobber Jest).
import 'mocha';
import { web3Wrapper } from './web3_wrapper'; import { web3Wrapper } from './web3_wrapper';
@ -42,7 +43,7 @@ function defineBlockchainSuite<T>(
init(); init();
return describeCall( return describeCall(
description, description,
function(this: mocha.ISuiteCallbackContext): void { function(this: Mocha.ISuiteCallbackContext): void {
callback.call( callback.call(
this, this,
{ web3Wrapper, blockchainLifecycle }, { web3Wrapper, blockchainLifecycle },
@ -58,7 +59,7 @@ function defineResetsSuite<T>(
): T { ): T {
return describeCall( return describeCall(
description, description,
function(this: mocha.ISuiteCallbackContext): void { function(this: Mocha.ISuiteCallbackContext): void {
if (blockchainLifecycle !== undefined) { if (blockchainLifecycle !== undefined) {
const _blockchainLifecycle = blockchainLifecycle; const _blockchainLifecycle = blockchainLifecycle;
beforeEach(async () => { beforeEach(async () => {