Skip to content

Commit bf3e884

Browse files
committed
1 parent a4dc18d commit bf3e884

File tree

1 file changed

+5
-5
lines changed
  • hardhat-tests/test/internal/hardhat-network/stack-traces

1 file changed

+5
-5
lines changed

hardhat-tests/test/internal/hardhat-network/stack-traces/test.ts

+5-5
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import { EdrProviderWrapper } from "hardhat/internal/hardhat-network/provider/pr
66
import { ReturnData } from "hardhat/internal/hardhat-network/provider/return-data";
77
import {
88
ConsoleLogs,
9-
consoleLogToString,
9+
ConsoleLogger,
1010
} from "hardhat/internal/hardhat-network/stack-traces/consoleLogger";
1111
import {
1212
printMessageTrace,
@@ -93,7 +93,7 @@ interface DeploymentTransaction {
9393
};
9494
stackTrace?: StackFrameDescription[]; // No stack trace === the tx MUST be successful
9595
imports?: string[]; // Imports needed for successful compilation
96-
consoleLogs?: ConsoleLogs[];
96+
consoleLogs?: ConsoleLogs;
9797
gas?: number;
9898
}
9999

@@ -108,7 +108,7 @@ interface CallTransaction {
108108
// The second one is with function and parms
109109
function?: string; // Default: no data
110110
params?: Array<string | number>; // Default: no param
111-
consoleLogs?: ConsoleLogs[];
111+
consoleLogs?: ConsoleLogs;
112112
gas?: number;
113113
}
114114

@@ -437,7 +437,7 @@ function compareStackTraces(
437437
assert.lengthOf(trace, description.length);
438438
}
439439

440-
function compareConsoleLogs(logs: string[], expectedLogs?: ConsoleLogs[]) {
440+
function compareConsoleLogs(logs: string[], expectedLogs?: ConsoleLogs) {
441441
if (expectedLogs === undefined) {
442442
return;
443443
}
@@ -446,7 +446,7 @@ function compareConsoleLogs(logs: string[], expectedLogs?: ConsoleLogs[]) {
446446

447447
for (let i = 0; i < logs.length; i++) {
448448
const actual = logs[i];
449-
const expected = consoleLogToString(expectedLogs[i]);
449+
const expected = ConsoleLogger.format(expectedLogs[i]);
450450

451451
assert.equal(actual, expected);
452452
}

0 commit comments

Comments
 (0)