mirror of
https://github.com/fluencelabs/tendermint
synced 2025-06-19 08:01:22 +00:00
mv tools files to tools repo
This commit is contained in:
18
tools/tm-bench/bench_test.go
Normal file
18
tools/tm-bench/bench_test.go
Normal file
@ -0,0 +1,18 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"testing"
|
||||
"time"
|
||||
)
|
||||
|
||||
func BenchmarkTimingPerTx(b *testing.B) {
|
||||
startTime := time.Now()
|
||||
endTime := startTime.Add(time.Second)
|
||||
for i := 0; i < b.N; i++ {
|
||||
if i%20 == 0 {
|
||||
if time.Now().After(endTime) {
|
||||
continue
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user