From 77f3ef3714afa280add3654ebceda2dd1856d65f Mon Sep 17 00:00:00 2001 From: rjl493456442 Date: Sun, 10 Nov 2024 17:57:05 +0800 Subject: [PATCH] tests: fix test panic (#30741) Fix panic in tests --- tests/state_test_util.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/state_test_util.go b/tests/state_test_util.go index 31f4224a8b..af2cb63d94 100644 --- a/tests/state_test_util.go +++ b/tests/state_test_util.go @@ -308,6 +308,7 @@ func (t *StateTest) RunNoVerify(subtest StateSubtest, vmconfig vm.Config, snapsh if tracer := evm.Config.Tracer; tracer != nil && tracer.OnTxEnd != nil { evm.Config.Tracer.OnTxEnd(nil, err) } + return st, common.Hash{}, 0, err } // Add 0-value mining reward. This only makes a difference in the cases // where @@ -322,7 +323,7 @@ func (t *StateTest) RunNoVerify(subtest StateSubtest, vmconfig vm.Config, snapsh receipt := &types.Receipt{GasUsed: vmRet.UsedGas} tracer.OnTxEnd(receipt, nil) } - return st, root, vmRet.UsedGas, err + return st, root, vmRet.UsedGas, nil } func (t *StateTest) gasLimit(subtest StateSubtest) uint64 {