Skip to content

Commit

Permalink
fix test
Browse files Browse the repository at this point in the history
  • Loading branch information
ARR552 committed Mar 22, 2023
1 parent e930088 commit 08dc695
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion jsonrpc/endpoints_debug.go
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ func (d *DebugEndpoints) buildTraceTransaction(ctx context.Context, hash common.

result, err := d.state.DebugTransaction(ctx, hash, traceConfig, dbTx)
if errors.Is(err, state.ErrNotFound) {
return rpcErrorResponse(types.DefaultErrorCode, "genesis is not traceable", nil)
return rpcErrorResponse(types.DefaultErrorCode, "transaction not found", nil)
} else if err != nil {
const errorMessage = "failed to get trace"
log.Infof("%v: %v", errorMessage, err)
Expand Down
2 changes: 1 addition & 1 deletion test/e2e/debug_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ func TestDebugTraceTransactionNotFoundTx(t *testing.T) {
require.NotNil(t, response.Error)

require.Equal(t, -32000, response.Error.Code)
require.Equal(t, "genesis is not traceable", response.Error.Message)
require.Equal(t, "transaction not found", response.Error.Message)
require.Nil(t, response.Error.Data)
}
}
Expand Down

0 comments on commit 08dc695

Please sign in to comment.