Unit test error with mocha and chai Timeout of 2000ms exceeded. For async tests and hooks
问题 My code: const assert = require('assert'); const ganache = require('ganache-cli'); const Web3 = require('web3'); const web3 = new Web3(ganache.provider()); const { interface,bytecode} = require('../compile'); let accounts; let inbox; beforeEach( async() => { accounts = await web3.eth.getAccounts(); inbox = await new web3.eth.Contract(JSON.parse(interface)) .deploy({data: bytecode,arguments:['Hi There !'] }) .send({from: accounts[0], gas:'1000000'}); }); describe("inbox", () => { it('deploys a