From 2bf65fda1f6b3018edbb4158574465326d4918be Mon Sep 17 00:00:00 2001 From: Fabio Berger Date: Fri, 10 Nov 2017 16:34:21 -0500 Subject: Add tests for the numConfirmations config to ensure that the events are being emitted for the confirmation depth specified --- test/utils/rpc.ts | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'test/utils/rpc.ts') diff --git a/test/utils/rpc.ts b/test/utils/rpc.ts index f28a85340..1fc9f2428 100644 --- a/test/utils/rpc.ts +++ b/test/utils/rpc.ts @@ -26,6 +26,13 @@ export class RPC { const didRevert = await this.sendAsync(payload); return didRevert; } + public async mineBlockAsync(): Promise { + const method = 'evm_mine'; + const params: any[] = []; + const payload = this.toPayload(method, params); + const didRevert = await this.sendAsync(payload); + return didRevert; + } private toPayload(method: string, params: any[] = []): string { const payload = JSON.stringify({ id: this.id, -- cgit v1.2.3