From 45c644c43d1498abdaf86a0fe85e74d933d06cbc Mon Sep 17 00:00:00 2001 From: Daniel Liu Date: Tue, 24 Sep 2024 16:01:34 +0800 Subject: [PATCH] core/vm: update benchmark to use Errorf instead of Sprintf (#24845) --- core/vm/contracts_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/vm/contracts_test.go b/core/vm/contracts_test.go index 1a03f93fc2..22fe467c3f 100644 --- a/core/vm/contracts_test.go +++ b/core/vm/contracts_test.go @@ -618,7 +618,7 @@ func benchmarkPrecompiled(addr string, test precompiledTest, bench *testing.B) { return } if common.Bytes2Hex(res) != test.expected { - bench.Error(fmt.Sprintf("Expected %v, got %v", test.expected, common.Bytes2Hex(res))) + bench.Errorf("Expected %v, got %v", test.expected, common.Bytes2Hex(res)) return } })