File tree Expand file tree Collapse file tree 1 file changed +13
-4
lines changed
v-next/hardhat/src/internal/builtin-plugins/solidity-test Expand file tree Collapse file tree 1 file changed +13
-4
lines changed Original file line number Diff line number Diff line change @@ -116,9 +116,11 @@ function formatTrace(trace: CallTrace): NestedArray<string> {
116
116
let closingLine : string | undefined ;
117
117
if ( kind === CallKind . Create ) {
118
118
openingLine = `[${ gasUsed } ] ${ chalk . yellow ( "→ new" ) } ${ contract } ` ;
119
- if ( formattedInputs !== undefined ) {
120
- openingLine = `${ openingLine } @${ formattedInputs } ` ;
121
- }
119
+ // TODO: Uncomment this when the formattedInputs starts containing
120
+ // the address of where the contract was deployed instead of the code.
121
+ // if (formattedInputs !== undefined) {
122
+ // openingLine = `${openingLine}@${formattedInputs}`;
123
+ // }
122
124
} else {
123
125
const formattedKind = formatKind ( kind ) ;
124
126
openingLine = `[${ gasUsed } ] ${ color ( contract ) } ` ;
@@ -133,7 +135,14 @@ function formatTrace(trace: CallTrace): NestedArray<string> {
133
135
}
134
136
}
135
137
if ( formattedOutputs !== undefined ) {
136
- closingLine = `${ color ( "←" ) } ${ formattedOutputs } ` ;
138
+ if (
139
+ formattedOutputs === "EvmError: Revert" ||
140
+ formattedOutputs . startsWith ( "revert:" )
141
+ ) {
142
+ closingLine = `${ color ( "←" ) } ${ color ( "[Revert]" ) } ${ formattedOutputs } ` ;
143
+ } else {
144
+ closingLine = `${ color ( "←" ) } ${ formattedOutputs } ` ;
145
+ }
137
146
}
138
147
139
148
const lines = [ ] ;
You can’t perform that action at this time.
0 commit comments