mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-23 05:06:43 +00:00
rpc: using testing.B.Loop
Signed-off-by: yajianggroup <yajianggroup@outlook.com>
This commit is contained in:
parent
2872242045
commit
4698806eca
1 changed files with 2 additions and 2 deletions
|
|
@ -259,8 +259,8 @@ func BenchmarkNotify(b *testing.B) {
|
||||||
ParentHash: common.HexToHash("0x01"),
|
ParentHash: common.HexToHash("0x01"),
|
||||||
Number: big.NewInt(100),
|
Number: big.NewInt(100),
|
||||||
}
|
}
|
||||||
b.ResetTimer()
|
|
||||||
for i := 0; i < b.N; i++ {
|
for b.Loop() {
|
||||||
notifier.Notify(id, msg)
|
notifier.Notify(id, msg)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue