mirror of
https://github.com/nbd-wtf/go-nostr.git
synced 2025-11-18 10:06:27 +01:00
update go version so we can use the new benchmarking helper.
This commit is contained in:
@@ -104,13 +104,13 @@ func BenchmarkIDCheck(b *testing.B) {
|
||||
evt.Sign(GeneratePrivateKey())
|
||||
|
||||
b.Run("naïve", func(b *testing.B) {
|
||||
for i := 0; i < b.N; i++ {
|
||||
for b.Loop() {
|
||||
_ = evt.GetID() == evt.ID
|
||||
}
|
||||
})
|
||||
|
||||
b.Run("big brain", func(b *testing.B) {
|
||||
for i := 0; i < b.N; i++ {
|
||||
for b.Loop() {
|
||||
_ = evt.CheckID()
|
||||
}
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user